[Chameleon] having skins in a custom directory
Eijnden, B. van den (Bart)
b.vdeijnden at agi.rws.minvenw.nl
Mon Mar 20 02:53:58 EST 2006
Hi Paul,
I have proposed a fix for this in bug report 1369:
http://bugzilla.maptools.org/show_bug.cgi?id=1369
I would appreciate it if you have a moment to check the solution. Thanks in
advance.
Best regards,
Bart
-----Oorspronkelijk bericht-----
Van: chameleon-bounces at lists.maptools.org
[mailto:chameleon-bounces at lists.maptools.org]Namens Eijnden, B. van den
(Bart)
Verzonden: vrijdag 17 maart 2006 14:21
Aan: 'Paul Spencer'
CC: 'chameleon at lists.maptools.org'
Onderwerp: RE: [Chameleon] having skins in a custom directory
Hi Paul,
I do register the skin with an absolute path already:
$this->registerskin(dirname(__FILE__).'/skins/geoservices');
I'll try to come up with a better solution after a more thorough analysis.
Best regards,
Bart
-----Oorspronkelijk bericht-----
Van: Paul Spencer [mailto:pspencer at dmsolutions.ca]
Verzonden: vrijdag 17 maart 2006 14:09
Aan: Eijnden, B. van den (Bart)
CC: 'chameleon at lists.maptools.org'
Onderwerp: Re: [Chameleon] having skins in a custom directory
Bart,
you could register an absolute path to the skins directory, this
should be the first (and fastest) case resolved. Or you could
register a relative path that gets caught earlier, like relative to
your application directory.
I'm not sure moving that 4th case up would be the right solution, its
been a long time since I looked at that code and it seems to me that
it would cause problems but I am not sure how :)
Cheers
Paul
On 17-Mar-06, at 7:42 AM, Eijnden, B. van den (Bart) wrote:
> Hi list,
>
> I have my skin directory positioned under a custom directory
> (apps/geoservices/htdocs/skins), and most of the Chameleon
> functionality
> works fine.
>
> There is however a problem with the Ruler widget, since
> fileSystemToURL does
> not seem to be able to deal with such a situation.
>
> $szRulerPix = $oApp->findFile( "images/ruler_pix.gif" );
> $szRulerPix = $oApp->fileSystemToURL( $szRulerPix );
>
> The outcome of this is:
>
> http://145.50.148.45:82/data/geoservices-50/apps/geoservices/htdocs/
> skins/ge
> oservices/images/ruler_pix.gif
>
> which is the file path (/data/geoservices-50) appended to the ip:port
> combination.
>
> What is the correct way to deal with this kind of situation?
>
> One way to solve it is to move up case 4 in the findFile routine so
> this
> will be the first option checked by Chameleon (since the ruler
> images are
> also under /chameleon/htdocs/images):
>
> /* case 4 - relative to chameleon */
> $szTempPath = $this->resolvePath2( $szFilePath,
> $_SESSION['gszCorePath'] );
> clearstatcache();
> if ($szTempPath != "" && file_exists($szTempPath))
> {
> //echo "found: $szTempPath<BR>\n";
> return $szTempPath;
> }
>
> However, I cannot foresee if this will have unwanted side effects
> (what is
> the use of chameleon/htdocs/images anyway compared to the skins/
> images ?).
>
> Thanks in advance.
>
> Best regards,
> Bart
>
>
> Disclaimer
> **********************************************************************
> **
> Aan dit bericht kunnen geen rechten worden ontleend. Dit bericht is
> uitsluitend bestemd voor de geadresseerde. Als u dit bericht per abuis
> hebt ontvangen, wordt u verzocht het te vernietigen en de afzender te
> informeren. Wij adviseren u om bij twijfel over de juistheid of de
> volledigheid van de mail contact met afzender op te nemen.
>
> This message shall not constitute any rights or obligations.
> This message is intended solely for the addressee.
> If you have received this message in error, please delete it and
> notify the sender immediately. When in doubt whether this message
> is correct or complete, please contact the sender.
> **********************************************************************
> **
>
> _______________________________________________
> Chameleon mailing list
> Chameleon at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/chameleon
+-----------------------------------------------------------------+
|Paul Spencer pspencer at dmsolutions.ca |
+-----------------------------------------------------------------+
|Applications & Software Development |
|DM Solutions Group Inc http://www.dmsolutions.ca/|
+-----------------------------------------------------------------+
Disclaimer
************************************************************************
Aan dit bericht kunnen geen rechten worden ontleend. Dit bericht is
uitsluitend bestemd voor de geadresseerde. Als u dit bericht per abuis
hebt ontvangen, wordt u verzocht het te vernietigen en de afzender te
informeren. Wij adviseren u om bij twijfel over de juistheid of de
volledigheid van de mail contact met afzender op te nemen.
This message shall not constitute any rights or obligations.
This message is intended solely for the addressee.
If you have received this message in error, please delete it and
notify the sender immediately. When in doubt whether this message
is correct or complete, please contact the sender.
************************************************************************
_______________________________________________
Chameleon mailing list
Chameleon at lists.maptools.org
http://lists.maptools.org/mailman/listinfo/chameleon
Disclaimer
************************************************************************
Aan dit bericht kunnen geen rechten worden ontleend. Dit bericht is
uitsluitend bestemd voor de geadresseerde. Als u dit bericht per abuis
hebt ontvangen, wordt u verzocht het te vernietigen en de afzender te
informeren. Wij adviseren u om bij twijfel over de juistheid of de
volledigheid van de mail contact met afzender op te nemen.
This message shall not constitute any rights or obligations.
This message is intended solely for the addressee.
If you have received this message in error, please delete it and
notify the sender immediately. When in doubt whether this message
is correct or complete, please contact the sender.
************************************************************************
More information about the Chameleon
mailing list