access the testlink database by running a PHP from CLI

Discussion and information for XML-RPC interface.

Moderators: Amaradana, TurboPT, TL Developers

access the testlink database by running a PHP from CLI

Postby abadve » Wed Feb 18, 2009 2:03 am

Hello all
I am trying this simple example from the command line interface to access the testlink database. This example below works if I specify the absolute path to the location of class-IXR.php file. If I specify it using IP address it does not work.
Do I need some HTTP packages installed or am I having some permission problems.
// above works if used absolute path
define("SERVER_URL", "http://IP_address/testlink/lib/api/xmlrpc.php");
define("DEV_KEY", "97b98d32b515fc4f2c9a09abf6999849");
$client = new IXR_Client(SERVER_URL);
if(!$client->query('tl.sayHello')) {
echo "callfailed". $client->getErrorCode()."-".$client->getErrorMessage();
else {
print "class called\n";

I look forward to your replies.

Thanks a lot.
TestLink user
Posts: 13
Joined: Wed Feb 18, 2009 1:56 am

Postby tfeathers » Wed May 13, 2009 4:56 am

The answer is use the python client... I will attach my code once I am done with it... I have one last piece to finish in the morning.
Advanced user
Posts: 19
Joined: Thu Mar 19, 2009 1:19 pm

Postby fman » Fri May 15, 2009 2:57 pm

the answer is undertand why php client do not work and solve
Member of TestLink Community
Posts: 3073
Joined: Tue Nov 15, 2005 7:19 am

Postby aksinghv » Wed Jun 17, 2009 6:15 pm

Hi tfeathers,

I guess your coding is complete. Could you share your code so that wider comunity gets benefitted.

Advanced user
Posts: 57
Joined: Sun Aug 17, 2008 4:06 am

Return to XML-RPC API

Who is online

Users browsing this forum: No registered users and 1 guest