hi i've managed to link to my database login which is above my root folder using php. however when i try to do the same for my external css, it doesnt work. is there a way to go about doing this?
thanks.
hi i've managed to link to my database login which is above my root folder using php. however when i try to do the same for my external css, it doesnt work. is there a way to go about doing this?
thanks.
You can't link to any files client-side that aren't publicly available. If you have a file above public_html (or www), you simply cannot link to it. So you'll have to move your css inside public_html.
Real programmers don't document their code - if it was hard to write, it should be hard to understand.
the databse login file and css are all within the public_html folder.
public_html/mywebsite.com is my root domain
public_html/css is where i put the css files.
the link worked when i used php to get the database login file but didnt work for the css.
im sorry if i didnt explain it clearly in the first place.
when entering the domain mywebsite.com the folder mywebsite.com is root for that domain. Php files can be placed outside of that root as they are accessed server side. css however is accessed by the end users browser, which can not read anything outside of the root folder for that domain.
Do you have trouble reaching your site?
Check here first: News and Announcements
Don't forget that x10hosting has an irc server as well. Come and join the fun
server: irc.x10hosting.com, main channel: #x10hosting
There's a lot helpful users there if need help building your site
ok thank you very much for your reply.
Try using
src="http://wheretogoatnight.x10hosting.com/css/mycssfile.css"
as your link to your css file.
Last edited by descalzo; 02-11-2010 at 10:54 AM.
Nothing is always absolutely so.