[Mapserver-users] Re: php code inside a CGI mapserver application

pkishor_98 pkishor at geoanalytics.com
Thu Jul 31 17:28:40 EDT 2003


--- In mapserver-users at yahoogroups.com, "Steve Lime" <steve.lime at d...>
wrote:
> I thought that with Apache 2.0 you could chain 
> together applications, so

perhaps. I did say "as far as I know..." ;-)

I did a little research, and I can't find anything to this effect. I
know that you can do something like insert a perl script inside a php
script using "include" or even the other way around. I think the
problem is sending the output from the "chained" cgi processor back to
Apache... for example, using backticks to run a php script from a perl
script produces nothing at all.

But, then again, perhaps there is away to configure Apache to do this.

> I see value in this type of processing. Why deal with
> MapScript if you don't need to. 

perhaps. But, then, why use two different CGI processors when you are
not eager to use Mapscript... anyway, that is not for us to argue... I
guess, the thing to figure out is whether this is possible or not.

> I imagine you could use javascript as
> well, but then, well you need javascript and PHP would give you the
> server-side equivalent.

yeah. that is easy because js is client-side (unless you are talking
about server-side js) so there is no conflict.

I'll research more into this "chaining cgis" as you call it and report
back when I find something.

Thanks Steve,

Puneet.



> 
> Steve
> 
> >>> "pkishor_98" <pkishor at g...> 07/31/03 02:13PM >>>
> --- In mapserver-users at yahoogroups.com, "colombo.l" <colombo.l at e...>
> wrote:
> > hello,
> > 
> >  i did a CGI-Mapserver application following some tutorials on the
> site, all work great, I have some problems when I put php code inside
> my template file.
> > I use apache , php 4.3 (working as a cgi) and mapserver 3.6.
> > 
> > If I define my template.php as my template (inside mapfile) I get
> some errors (Malformed URL). So I added this line to http.conf:
> > 
> > AddType application/x-httpd-php .html
> > 
> > Now I can put php code inside html pages, but it didn't works with
> mapserver !!
> > 
> > I can't get php-code to be compiled, mapserver process the page but
> apache+php didn't.
> > 
> 
> 
> did someone answer this? As far as I can think... you can't really do
> anything...
> 
> Apache can work with one server-side processor only... you either have
> it work with Mapserver, or you have it work with PHP. Maybe there is a
> way to make it work with both, but I can't think of any.
> 
> If you want to use PHP, why not ditch the Mapserver-as-a-CGI, and use
> Mapserver-as-a-PHP module? Compile and install PHP/Mapscript, and then
> use PHP to its fullest capability to do what you want to...
> 
> 
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at l... 
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at l...
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users




More information about the mapserver-users mailing list