Members Login
Username 
 
Password 
    Remember Me  
Post Info TOPIC: convenience class for PHP NetGet reply


Newbie

Status: Offline
Posts: 1
Date: Jan 17, 2010
convenience class for PHP NetGet reply
Permalink   
 


While implementing a NetGet handler in PHP, I ended up with this basic IfbyphoneNetGetReply class as a way to keep my code clean.  Code:

http://gist.github.com/279469

Sample use (live): http://gist.github.com/279481

The URLs have more, but here's a sample:

$ibp = new IfbyphoneNetGetAction('survo', array('id' => 1234, 'p_t' => '42'));
$ibp->set_user_parameters(array('name' => 'sergey'));
print($ibp->asXML());

Save ifbyphone_netget_reply.php in the same directory as your script, then require() it like the sample does.  Make sure PHP XML support is enabled (often the 'php-xml' OS package; check phpinfo() or "php -m").

Troy


__________________
Page 1 of 1  sorted by
 
Quick Reply

Please log in to post quick replies.

Post to Digg Post to Del.icio.us


Create your own FREE Forum
Report Abuse
Powered by ActiveBoard