Hi Jamie, Stephen, Cerebrus

Yes, the ascx page is in the same directory as the aspx page.  I
became so frustrated with it that I started testing classes that were
used in aspx pages too.  And discovered that it was actually a problem
with Firefox!!  I normally test for cross-browser compatibility but
was just focused on the user control at the time and hadn't tried
anything else.  Apparently, Firefox has a problem where certain CSS
properties get stuck in a cache like 'history'.  I could remove
regular controls from the page and it would render, but then when I'd
change decoration type properties (like color: in CSS), it would do
nothing.  Switched to IE and all of the test properties I changed
rendered.

Once I "cleared recent history" in Firefox, all of the CSS classes
began functioning again. Firefox's web page says it is a 'known
issue'.  It would of been and was the last place I would have looked
though.

Thanks for y'all's help.

On Aug 25, 9:34 am, Jamie Fraser <[email protected]> wrote:
> Is the link to you CSS class correct? Is it in the same directory as
> your ASPX page?
>
> Post your CSS also - might help in case the error is in there (don't
> assume the problem lies with ASP.NET).
>
> On Wed, Aug 25, 2010 at 3:21 AM, ptvvee <[email protected]> wrote:
> > Hi
>
> > I've researched and researched this thing but am totally stumped.  I'm
> > trying to create a footer links UserControl to my .Net web pages using
> > an ascx file.  Everything I read says that the code in the ascx file
> > should pick up the css files from the main aspx page it is embedded
> > in.  But it doesn't work!  All I have is a simple table with
> > <table><tr>and <td> tags.
>
> > I also tried adding a directive:
>
> > <link href="style.css" rel="stylesheet" type="text/css" />
>
> > to the top of my ascx page.  Still doesn't work.
>
> > What I'm trying to do is use some of the 'a' type CSS classes to
> > control the appearance of the links.
>
> > Here's the ascx code :
>
> > <%@ Control Language="C#" AutoEventWireup="true"
> > CodeFile="footer.ascx.cs" Inherits="footer" %>
>
> > <table>
> >    <tr>
> >        <td>
> >            <span class='foo'><a href="trees.aspx">Trees</a></span>
> >        </td>
> >        <td>
> >            <span class='foo'><a href="bushes.aspx">Bushes</a></span>
> >        </td>
> >        <td>
> >            <span class='foo'><a href="shrubs.aspx">Shrubs</a></span>
> >        </td>
> >    </tr>
> > </table>
>
> > I know you might want to see the code for my 'foo' css class, but it
> > doesn't matter.  It doesn't matter what I do, no CSS classes work on
> > anything.
>
> > Can anybody help!!??  Thanks, Paul

Reply via email to