Yes we have sites where we mix php and webware, but not pages with mixed
webware and php content, except for some pages where we use iframes, but
that doesn't really count does it.  We had tried that approch at first
but found it to cumbersome.  Rather then using f=popne... you might want
to try something with urllib2, this way you could technically pass the
entire environment variables to php, but I don't think you are going to
be able to pass session variables.  We found it easier in the end to
just keep pages either in one format or the other and not try to mix the
content. 
Jose

sophana wrote:
> So your website is composed of php pages mixed with webware pages, but
> you don't have php+webware mixed pages. Did I understand right?
> That is not exactly what I was looking for. Duplicating the SitePage
> which contains header and sidebar that contains session dependant
> account info is impossible for me.
> I was wondering if it was possible to 'include' a php page from python
> by doing something like
>
> f=popen('php script.php php args')
> s=f.readlines()
> self.write(s)
>
> The problem is how can I transmit the http request url and things like
> that to the php script?
> What do you think about the performance of this kind of script?
> Maybe I could use urllib and open a tcp connection to the local apache
> server?
> Is there a way to pipe the file handle directly into the response
> request to achieve better performance?
> Or should I simply use frames?
>
> Sophana
>
> Jose Galvez wrote:
>
>> Dear Sophana,
>>
>> When I've mixed webware with php (which we do quite alot where I work),
>> I have always gone through the apache web server.  Essentially we have a
>> single root context which can server either webware pages or php pages
>> depending on the extension of the script, py is run through webware and
>> php is run through php.  As to the look and feel, that really depends on
>> how you have your pages set up, most of our actual html design is done
>> with cheetah, so alot of our look and feel is done with stylsheets and
>> the usual stuff, which will carry over to php without any trouble.
>> However some of our pages are set up with header and footers and stuff
>> like that, a practice which is very common in php, which we had to build
>> duplicates for, so essentially for some websites we have duplicate php
>> and webwaer page headers and footers.  Its a pain if you are actively
>> editing a site because you have to remember to edit more then one set of
>> code, but our users don't seem to see the difference.  No sure if this
>> is what you wanted, but I hope it helps.  BTW within the same folder we
>> often have both php and webware scripts, like I said we have apachie
>> configured to deal with both.
>>
>> Jose
>>
>> sophana wrote:
>>  
>>
>>> Hi all
>>>
>>> I'm coding a website with webware, but I'd like to reuse php scripts
>>> in it.
>>> These php scripts are hosted on the same machine (web server)
>>>
>>> How do I include these scripts inside my SitePage look and feel?
>>> Can I call the php interpreter directly from python or should I go
>>> through the apache web server?
>>>
>>> In both case, how can I do it?
>>>
>>> Thanks for your help
>>> Sophana
>>>
>>>
>>>
>>>
>>> -------------------------------------------------------
>>> This SF.Net email is sponsored by xPML, a groundbreaking scripting
>>> language
>>> that extends applications into web and mobile media. Attend the live
>>> webcast
>>> and join the prime developer group breaking into this new coding
>>> territory!
>>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
>>>
>>> _______________________________________________
>>> Webware-discuss mailing list
>>> Webware-discuss@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/webware-discuss
>>>
>>>
>>>   
>>
>>
>>
>> -------------------------------------------------------
>> This SF.Net email is sponsored by xPML, a groundbreaking scripting
>> language
>> that extends applications into web and mobile media. Attend the live
>> webcast
>> and join the prime developer group breaking into this new coding
>> territory!
>> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
>> _______________________________________________
>> Webware-discuss mailing list
>> Webware-discuss@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/webware-discuss
>>
>>  
>>
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by xPML, a groundbreaking scripting
> language
> that extends applications into web and mobile media. Attend the live
> webcast
> and join the prime developer group breaking into this new coding
> territory!
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
> _______________________________________________
> Webware-discuss mailing list
> Webware-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/webware-discuss
>
>



-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Webware-discuss mailing list
Webware-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/webware-discuss

Reply via email to