[OpenLayers-Users] openlayers single file librarry problem

Christopher Schmidt crschmidt at metacarta.com
Wed May 13 07:28:28 EDT 2009


On Wed, May 13, 2009 at 11:11:32AM +0000, Joanne Cook wrote:
> Hi All,
> 
> I'm not totally sure if this is an openlayers issue or related to mapfish, but I am having problems building a single file version of the openlayers libraries.
> 
> I start in /var/www/mapfish/client/mfbase/openlayers/build. The (mapfish) documentation suggests that I should be able to state the location of the file I am trying to create, so I run:
> sudo ./build.py full.cfg /var/www/scripts/openlayers_sfl.js
> 
> This works to the extent that it creates the file, and most elements work OK in the web page. However, it can't find the image folder or the theme folder, so I don't have the navigation elements, and firebug shows me that it's looking for them in the root folder /var/www, so /var/www/theme and /var/www/img. The same happens if I change the build path to /var/www/mapfish/client/mfbase/openlayers/lib/openlayers_sfl.js.
> 
> Clearly I can copy the img and theme folders into my root folder, but is there something I'm missing about building the library?

OpenLayers can only automatically find images and theme if the
OpenLayers file is *named* OpenLayers.js. The theme can be included
manually (via a <link rel="stylesheet"> to theme/default/style.css), and
the image path can be specified by setting OpenLayers.ImgPath.

-- Chris

> 
> 
> ------
> Files attached to this email may be in ISO 26300 format (OASIS Open Document Format). If you have difficulty opening them, please visit http://iso26300.info for more information.
> 
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users

-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list