I still can't get this to work for me.
This works fine:
<script src="http://10.128.3.63:8080/geoserver/www/sorttable.js";
type="text/javascript"></script>

But this does not:
<script src="/geoserver/www/sorttable.js" type="text/javascript"></script>


Could it be because it's port 8080 instead of 80?



On Wed, Jun 26, 2013 at 9:31 PM, Justin Deoliveira <[email protected]>wrote:

> Hi Jen,
>
> Unfortunately no information about the request is passed into the
> template. But you should be able to use an absolute path like
> "/geoserver/www/sorttable.js" as the script src attribute. This makes an
> assumption that the server context is named "geoserver" so wouldn't work if
> you deployed it under a different name.
>
> -Justin
>
>
>
> On Wed, Jun 26, 2013 at 11:50 AM, Jen Weiss <[email protected]> wrote:
>
>> I have some javascript files placed in the .../data/www folder that I'm
>> trying to be able to reference as a relative path in the header.ftl file
>> (that styles the getFeatureInfo response).
>>
>> I can access the javascript files fine using the full url, eg:  <script
>> src="http://10.128.3.63:8080/geoserver/www/sorttable.js";
>> type="text/javascript"></script>
>>
>> but I can't for the life of me figure out how to get it to accept a
>> relative path... I've tried pretty much every combination of
>> ../www/sorttable.js, /geoserver/www/sorttable.js, etc, etc trying to find a
>> combination that works, but no luck so far.
>> Does anyone have any insight into this?
>>
>> Also, is there anyway to get the baseUrl as a variable to use in the
>> freemarker templates?
>>
>> Thanks!
>> -Jen
>>
>>
>> ------------------------------------------------------------------------------
>> This SF.net email is sponsored by Windows:
>>
>> Build for Windows Store.
>>
>> http://p.sf.net/sfu/windows-dev2dev
>> _______________________________________________
>> Geoserver-users mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>>
>>
>
>
> --
> Justin Deoliveira
> OpenGeo - http://opengeo.org
> Enterprise support for open source geospatial.
>
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to