[TYPO3] relative path mistaken
Xavier Perseguers
typo3 at perseguers.ch
Wed Jul 16 12:12:28 CEST 2008
Hi Arpard,
>>> page.CSS_inlineStyle (
>>> div #header { background-image:
>>> url('/fileadmin/template/main/img/header_eng.png'); }
>>> )
>>
>> This is not a problem in TYPO3 but with the way you reference the
>> file. Asking a file whose path starts with a slash will try to include
>> it from root of the domain, not root of your current install. TYPO3
>> has nothing
>
> And would it reference to www.myurl.com even if i made a subdomain like
> dev.myurl.com?
No of course. When you type "/something" in a href or in a CSS with
url(), it "replaces" all what is after the *first* / (not counting the
protocol itself). Thus if your URL starts with
http://dev.myurl.com/anything/you-have/here, it will search for
http://dev.myurl.com/fileadmin/...
The same with a domain http://whatyouwant.dev.something.other.myurl.com
as long as it is placed before the /, that is as long as it is
DNS-related stuff, not web server-related.
--
Xavier Perseguers
http://xavier.perseguers.ch/en/tutorials/typo3.html
More information about the TYPO3-english
mailing list