Using PHP to extend NowSMS

Using PHP to extend NowSMS SearchSearch

SMS & MMS Technical Forum » NowSMS Support - SMS Issues (Product Support Only) » Archive through February 09, 2012 » Using PHP to extend NowSMS « Previous || Next »
Author Message
New member
Username: Anouchka

Post Number: 1
Registered: 12-2011
Posted on Thursday, December 29, 2011 - 07:53 am:   

I am currently using the NowSMS Gateway Lite Edition v2011.07.07.
I am able to send and receive SMS using the GW. However for my project, I need to be able to post the sms received+the mobile phone number to a PHP page which will then perform a few validations against a table using the mobile phone number and SMS received.
I understand that in order to be able to do so I need to check "Enable Local PHP Processing"in the 2-way tab. But in doing so, I'm getting an error message "PHP support not available, unable to locate php-cgi.exe via PHPRC or path environment variable". Please note that I have downloaded WAMP server and it includes an installation of PHP 5.3.5.
Any help with the above error would be much appreciated. I am interested in buying the product if ever I am able to bring the project to completion using the current NowSMS trial version.

Des - NowSMS Support
Board Administrator
Username: Desosms

Post Number: 3694
Registered: 08-2008
Posted on Thursday, December 29, 2011 - 03:46 pm:   


If PHP is working on the other server, then I'd suggest using it. Run your PHP script on the other server. For the 2-way command, NowSMS just wants an HTTP URL, so just give it a URL for the PHP script on that other server.

We added the direct PHP support as a convenience for situations where there was not another web server installed.

If you don't want to rely on processing through that other server, and want to have NowSMS run the PHP scripts directly, then NowSMS is trying to locate the php-cgi.exe file.

It expects that the PHP installer has either setup a PHPRC environmental variable pointing to the directory that contains this file. Or the PATH environmental variable includes this directory.

If you run the PHP install and select generic CGI for the web server, the installer will do all this.

A PHP installer embedded in another product won't do this.

Assuming php-cgi.exe is installed on your system and you can locate this file, you can manually add the directory to your path and/or manually create a PHPRC environmental variable that points to that directory.

(We should probably provide another way to do this without relying on environmental variable settings. But the PHP installer does normally add these settings. In fact, a better option to manually adding these settings may be to just run the PHP installer independent of that other web server.)

NowSMS Support
New member
Username: Anouchka

Post Number: 2
Registered: 12-2011
Posted on Thursday, December 29, 2011 - 08:47 pm:   

Thank you for the reply. I got 'Enable Local PHP processing' working by installing PHP in the NOWSMS folder.In the WAMP server, I just started Apache.

I did try to just give it a URL to the PHP script located on the other server, but it wasn't working. I'll give it one more try though and see how it goes.

Else, I'll stick to my above working setup!

Login Login / Register Logout Logout Search Last 30 Days Topics Topics