link to stylesheet inserts / at beginning.

Hi,

Just  been playing around with dreamweaver and everytime i LINK to a style sheet it put a trailing forward slash i.e.

<link href="/stylesheets/main.css" rel="stylesheet" type="text/css" />

the problem is i am using a test server here and the / (root) is not the same site i.e.  Many different virual directories.

It should read <link href="stylesheets/main.css" rel="stylesheet" type="text/css" />

Now although very easy to edit in the code, just wondered if i am doing something wrong???

Ian
ianinspainAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

FahdmurtazaCommented:
I would ask why are you doing this all and kindly make your question abit clear and about the server and the scripting language and the reason for trailing slash.
Regards,
Fahd Murtaza
0
paintedCommented:
Hi Ian,
Is your stylesheet folder located inside the directory in which you are working?  If not try moving it there.  I think that will clear up your problem.

painted
0
paintedCommented:
You may also want to check that you are selecting document relative rather than site root relative when attaching your stylesheet.

Choose Text > CSS Styles > Attach Style Sheet
Select Link then Browse
Select document from the Relative to: drop down list.

Hope this helps.  Good Luck!
painted
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

FahdmurtazaCommented:
there is a very simple thing about that problem. If you have the stylesheet folder within the root directory, then all you can do is to make your code like

<link href="stylesheets/main.css" rel="stylesheet" type="text/css">

Once delete the linked style sheet from right click menu options in the dreamweaver and then relink it. It would work fine.Hope it will help.
Regards,
Fahd Murtaza
0
FahdmurtazaCommented:
You should reply to our comments sothat we can easily help!
0
ianinspainAuthor Commented:
thanks painted... that was it..

cheers

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Adobe Dreamweaver

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.