dcsimg
www.webdeveloper.com
Results 1 to 6 of 6

Thread: myStyle styles

Hybrid View

  1. #1
    Join Date
    Jul 2011
    Location
    Irish Republic
    Posts
    64

    Arrow myStyle styles

    I have a folder called styles set up for the .css files.

    <link rel="stylesheet" href="styles/myStyle.css" type="text/css" media="screen" />
    <link rel="stylesheet" href="myNav.css" type="text/css" media="screen" />

    The styles for the Navigation Menu are written in the myNav.css file. This file is acting strangly as it will not link to the website pages when it is deposited in the styles folder. When I place it in the styles folder I call it "styles/myNav.css" just as I would with other style sheets.
    Why can this be ?

  2. #2
    Join Date
    Mar 2011
    Posts
    1,156
    You forgot the folder name in the link tag's href attribute. You probably need to use this code instead:

    <link rel="stylesheet" href="styles/myNav.css" type="text/css" media="screen" />

  3. #3
    Join Date
    Jul 2011
    Location
    Irish Republic
    Posts
    64
    Hi rtrethewey,

    That is the problem, when I place the folder name in the link tag's href attribute I get a blank navigation bar and I can not figure out why!

  4. #4
    Join Date
    Feb 2008
    Location
    Amsterdam, The Netherlands
    Posts
    273
    Hey Webiter,

    We need matters online for that question. Can't tell with the info you're providing.

  5. #5
    Join Date
    Jul 2011
    Location
    Irish Republic
    Posts
    64
    Sorry, gone away for a while. Link at www.webitry.net

  6. #6
    Join Date
    Feb 2008
    Location
    Amsterdam, The Netherlands
    Posts
    273
    It has to do with the background url of the navMenu. If you put the style sheet in that folder, the url should be: ../album/sprites_navbar.jpg. Urls in style sheets are always relative to the style sheet, not to the file it is called into.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles