----------  Weitergeleitete Nachricht  ----------

Betreff: Re: dynamic image loading: image paths in Javascript conflictwith 
Turbine's path notation, so how to?
Datum: Mittwoch, 5. Dezember 2007
Von: "Thomas Pfäfflin (ritso)" <[EMAIL PROTECTED]>
An: Jürgen Hoffmann <[EMAIL PROTECTED]>

Hi Alex,

I resolved this by using /images/aImg.jpg or /images/aFolder/aImg.jpg  
whereever needed in css and javascripts, an configure an additional  
context in my tomcats server.xml for the /image path.

So I can set differnet paths for my development and live system  
without changing my app.

HTH
Thomas

Zitat von Jürgen Hoffmann <[EMAIL PROTECTED]>:

> Hi ALex,
>
> why not tell the Browser to get a special template page? Just define  
>  no Layout
> whatsoever for the page, and just hack velocity macro in there...
>
> <script src="$link.setPage("javascript.vm")" 
type="text/javascript"></script>
>
> Shouldn't that work?
>
> Kind regards
>
> Juergen Hoffmann
>
> Am Mittwoch, 5. Dezember 2007 10:46:23 schrieb Alexander Zimmer:
>> This would surely work, technically spoken.
>>
>> Anyway, I dislike the fact that I have to configure Apache in a special
>> way for a little aspect of my webapp. I personally like strict
>> modularity like "I register my webapp to Apache and that's it".
>>
>> What if - for instance - I host a second webapp served by the same
>> Apache instance. I would have to configure distinct RegExps for each of
>> the existing webapps.
>>
>> That said, it surely works, but to me it sort of falls a little bit
>> short of elegance ...
>>
>> But I could surely use this idea and use it on the web.xml webapp
>> configuration. I'm going to try this one.
>>
>> Cheers,
>> Alex
>>
>>
>> -----Original Message -----
>>
>> Alexander Zimmer cited <[EMAIL PROTECTED]>:
>> > Yes, this works with my example, but the example with the URL
>> > containing template information is really just an example, while
>> > navigating through the Turbine app, the URL using the JavaScript
>> > library could be:
>> >    - http://HOST/myapp/template/main.vm
>> >    - http://HOST/myapp/template/main.vm/action/MyAction
>> >    - http://HOST/myapp/template/main.vm/action/MyAction/id/2
>> >    - and so on
>> > So I'm afraid this is no viable solution - although I acknowledge
>> > its ingeniousity!
>>
>> Ok. One other thing that may work. Do you use Apache to serve static
>> content? Then the <Location> tag may help you. It can handle regular
>> expressions (if needed).
>>
>> <Location ~ ".*/images/active.gif">
>> </Location>
>>
>> See: http://httpd.apache.org/docs/2.2/mod/core.html#location
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>> !EXCUBATOR:1,4756754047098805015920!
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to