Page 1 of 1

API Help - Add Complex URL

Posted: June 21st, 2009, 3:16 pm
by roger1024
Hi,

I writing an alternate front end in PHP (mostly my own RSS parser) and I'm having some problem with the "addurl" parameter. My problem is that the URL I wan't sabnzbd to download also have a bunch of variables in the url. The software don't know which parameter is the URL and which are its own parameters and it jst freaks out. Is there anyway to specify the start and the end of the URL inside another URL. Using "" don't seem work...

$link = "http://www.nzbs.org/index.php?action=ge ... xxxxxxxxxx"

"http://$nzb_host:$nzb_port/sabnzbd/api?mode=addurl&name=$link&apikey=$nzb_apikey"

Thanks,

Roger

Re: API Help - Add Complex URL

Posted: June 21st, 2009, 4:26 pm
by shypike
Have you tried encoding the special characters, so & becomes %26 and ? becomes %3F ?
Just replace the character with its hexadecimal code prefixed with %.

Re: API Help - Add Complex URL

Posted: June 21st, 2009, 5:05 pm
by roger1024
Problem solved!

Thanks!