Dynamic ASPX Style Sheet not Render in FireFox?

Dynamic ASPX Style Sheet not Render in FireFox?

am 29.12.2007 07:34:26 von coconet

Server is Win2K3/IIS6.

I have an ASPX page with this in the tag:

Request.ServerVariables["SERVER_NAME"].ToString() +
this.ResolveUrl("~") + "styles/styledefault.aspx"); %>" />



The style.aspx page looks like this:

body
{
background: #655A46 url('<% Response.Write(
this.ResolveUrl("~") + "media/"); %>bg.gif');
color: #543;
font: normal 62.5% "Lucida Sans Unicode",sans-serif;
}

....


The purpose is to have dynamically-changing styles. The page renders
fine with my external and dynamic style sheet in IE7, but in FireFox
the style appears to be ignored. What can I do to make this work?

Thanks.

RE: Dynamic ASPX Style Sheet not Render in FireFox?

am 30.12.2007 02:21:02 von mily242

Howdy,

I reckon it should be:

" />

Regards
--
Milosz


"coconet" wrote:

> Server is Win2K3/IIS6.
>
> I have an ASPX page with this in the tag:
>
> > Request.ServerVariables["SERVER_NAME"].ToString() +
> this.ResolveUrl("~") + "styles/styledefault.aspx"); %>" />
>
>
>
> The style.aspx page looks like this:
>
> body
> {
> background: #655A46 url('<% Response.Write(
> this.ResolveUrl("~") + "media/"); %>bg.gif');
> color: #543;
> font: normal 62.5% "Lucida Sans Unicode",sans-serif;
> }
>
> ....
>
>
> The purpose is to have dynamically-changing styles. The page renders
> fine with my external and dynamic style sheet in IE7, but in FireFox
> the style appears to be ignored. What can I do to make this work?
>
> Thanks.
>
>

RE: Dynamic ASPX Style Sheet not Render in FireFox?

am 31.12.2007 04:19:24 von jialge

Hello coconet

I have reproduced the issue with your code. I also tried Milosz's
suggestion, but the problem still exists.

Based on my test, the style sheet works as expected both in Firefox and IE
only when the href attribute of the link tag points to a css file. A
possible reason is that Firefox does not support a server page as a style
sheet. It depends on how Firefox is coded for it. Therefore, my suggestion
is to contact Firefox for further support. (e.g.
http://forums.mozillazine.org/viewforum.php?f=38)

Another workaround is to extract the styles in the apsx file into a
separate css file, and link to the css in your page. Hope it helps.

If you have any other concern or need anything else, please feel free to
let me know.

Happy New Year!

Regards,
Jialiang Ge (jialge@online.microsoft.com, remove 'online.')
Microsoft Online Community Support

==================================================
For MSDN subscribers whose posts are left unanswered, please check this
document: http://blogs.msdn.com/msdnts/pages/postingAlias.aspx

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/de fault.aspx#notif
ications. If you are using Outlook Express/Windows Mail, please make sure
you clear the check box "Tools/Options/Read: Get 300 headers at a time" to
see your reply promptly.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx .
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

RE: Dynamic ASPX Style Sheet not Render in FireFox?

am 04.01.2008 03:58:57 von jialge

Hi coconet,

Would you mind letting me know the result of the suggestions? If you need
further assistance, feel free to let me know. I will be more than happy to
be of assistance.

Have a great day!

Sincerely,
Jialiang Ge (jialge@online.microsoft.com, remove 'online.')
Microsoft Online Community Support

=================================================
When responding to posts, please "Reply to Group" via your newsreader
so that others may learn and benefit from your issue.
=================================================
This posting is provided "AS IS" with no warranties, and confers no rights.