[Catalyst] Image serving

Harold Frayman harold.frayman at ntlworld.com
Tue Jan 31 14:23:52 CET 2006


Andreas Marienborg" <omega at palle.net> wrote:
> use the <base> html head tag?
> 
> trough that you should be able to get it to reference relative urls
> from where you want

I must be missing something obvious but critical; I can change the base (via the template) or intercept the call (via Regex('img')) and alter the path there. 

But I cannot work out what the path _should_ be, or alternatively (additionally?), how to persuade Catalyst to process the image path and return the image to the browser.

Harold

> 
> andreas
> On 30. jan. 2006, at 23.30, <harold.frayman at ntlworld.com>
> <harold.frayman at ntlworld.com> wrote:
> 
>> I am using Catalyst to serve web pages from a document tree which
>> already exists and cannot be changed significantly. The documents
>> to be served are of the form
>>
>> /Path/To/Documents/Path/Through/Tree/Title/body.html
>>
>> A call to MyApp/help/Path/Through/Tree/Title serves the body.html
>> text and wraps it in a page which includes links to, for example,
>> Path, Through and Tree and to subfolders (/Path/To/Documents/Path/
>> Through/Tree/Title/NextLevelTitle) which are handled by equivalent
>> calls.
>>
>> At the moment, a file called body.html may link to "img/
>> myimage.jpeg", in which case myimage.jpeg will be stored in /Path/
>> To/Documents/Path/Through/Tree/Title/img.
>>
>> The result is that Catalyst looks for /help/Path/Through/Tree/img/
>> myimage.jpeg. (The base is one level above the Title folder).
>>
>> I have tried various configurations of
>> Catalyst::Plugin::Static::Simple and I have tried tried putting the
>> image in several different places, but I cannot get the image to
>> appear.
>>
>> Any suggestions? Even if I have to move the images, which I want to
>> avoid?
>>
>> Harold


-----------------------------------------
Email sent from www.ntlworld.com
Virus-checked using McAfee(R) Software 
Visit www.ntlworld.com/security for more information




More information about the Catalyst mailing list