Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using PHP with ColdFusion 1

Status
Not open for further replies.

xor

Programmer
Jan 7, 2001
71
NZ
I heard ColdFusion works well with PHP. Does anyone know more about this? I don't know so much about PHP but am interested in learning more. Does ColdFusion actually parse the PHP code itself or does it have to hand it off to a PHP server/parser (ie. do you also have to have a PHP server or parser installed)? If ColdFusion does process PHP itself is there some option you have to set in CFAdministrator or is it the default that CF will parse PHP code when it encounters it? I am interested in learning PHP, but also at work we are thinking of moving ColdFusion into an area where previously PHP was used, it would be a shame to have to re-write things that are working well.
Any relevant comments welcome.
 
About the only way I'm aware of that you can mix scripting languages is to use something like &quot;<cfhttp ..>&quot;. You could have a CF script that does a <cfhttp> and requests a php3 file that does something special and just returns the result instead of a formatted html page. This way, the PHP3 scripts act like functions that CF can call. I would guess that PHP3 has some similar http request method which would allow you to send information back and forth easily.

I would suspect that you'll be better off keeping them separate but if you find CF has better string handling functions or PHP3 does networking better, you could cross-breed them for specific tasks.

GJ
 
As far as exchanging data between the two is concerned: I dont't know about PHP, but CF has excellent wddx support, it's quite easy for example to create a recordset in ASP for example, make a wddx packet of it and send it to CF and let CF handle it. I presume PHP has a built-in wddx serializer too, since wddx is a webstandard.

<webguru>iqof188</webguru>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top