Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Help with Paths and Absolute Paths
Old 07-20-2010, 11:08 PM Help with Paths and Absolute Paths
Novice Talker

Posts: 11
Trades: 0
I have a problem coding paths.

My home page is index.html and is in my root directory. Also in my root directory are folders (ie. /contact; /links; /blog; /forums etc.). I have /components for scripts, stylesheets etc and /images in the root directory too. For my homepage my coding is as follows

....type="text/css" href="components/style.css">

For my subfolders I use the same template (index.html) but the previous code don't work to show my stylesheet in my subfolders. I have also tried the following codes both still don't seem to work:

....type="text/css" href="/components/style.css">

and

....type="text/css" href=".../components/style.css">

My site is being hosted on a linux platform

Thanks
GnosticThinker is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 07-20-2010, 11:40 PM Re: Help with Paths and Absolute Paths
vivekar's Avatar
Webmaster Talker

Posts: 612
Trades: 0
Quote:
href=".../components/style.css">
Remove an extra dot.
href="../components/style.css">
__________________

Please login or register to view this content. Registration is FREE
(Active since 2003) |
Please login or register to view this content. Registration is FREE
vivekar is offline
Reply With Quote
View Public Profile Visit vivekar's homepage!
 
Old 07-21-2010, 10:28 AM Re: Help with Paths and Absolute Paths
Registered User

Posts: 86
Name: John Dacu
Trades: 0
If you can't access stylesheet throw browser address like: http:// domain.com/components/style.css then maybe you have an .htaccess setting who prevent accesing the folder or filetype. Check it. Or maybe is just a typing error. i know, is a stupid scenario but sometimes a have some problems like that
johnny.dacu is offline
Reply With Quote
View Public Profile
 
Old 07-24-2010, 11:46 AM Re: Help with Paths and Absolute Paths
OleTom's Avatar
Extreme Talker

Posts: 176
Location: Out there some where
Trades: 0
Here is something that I have noticed . If the file is not in the root folder this will not work
Code:
href=".../components/style.css">
If the folder is in the same directory as the web page being called it should look like this
Code:
href="components/style.css">
By putting the .../

in front components you are taking it to the root
__________________
Life is Good,OleTom

Please login or register to view this content. Registration is FREE
OleTom is offline
Reply With Quote
View Public Profile Visit OleTom's homepage!
 
Reply     « Reply to Help with Paths and Absolute Paths
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.61964 seconds with 12 queries