Page 1 of 1

Snoopy Class method submit outputs nothing

Posted: Thu Aug 18, 2011 2:26 pm
by puma10
Hey guys,

I am trying to use the Snoopy class to send the values of a form to multiple locations and I get nothing when using the submit method. I run the process.php file and no code is output. Other methods seem to be working but I can not get the snoopy->submit function to work.

The FAQ says you must be running PHP version higher then 3.2 and have the correct curl path.
I have called my host server to find the correct curl path and I'm running php version 5.2.17. Does anyone have any ideas? I am very new to writing in php so could it be anything subtle that I have overlooked? The code not being at the top of the page or something along those lines?

I am using Snoopy version 1.2.4.
http://sourceforge.net/projects/snoopy/

Code:

Code: Select all

include "Snoopy.class.php";
		$snoopy = new Snoopy;
		$snoopy->curl_path="/usr/bin/curl";  //change the curl path to my servers path
		
		$snoopy->fetchtext("http://www.php.net/");
 
 $submit_url = "url1.php";
 
 $submit_vars["foo"] = "bar";
 $submit_vars["key"] = "value";
 $submit_vars["input-name"] = "input-value";
 //making sense on what these are?
  
 $snoopy->submit($submit_url,$submit_vars);
 //additionaly you can print the results with:
 print $snoopy->results;

Thanks everyone.

Re: Snoopy Class method submit outputs nothing

Posted: Thu Aug 18, 2011 4:13 pm
by social_experiment
What does this method do $snoopy->submit($submit_url,$submit_vars); ? Does it have any relevance to $snoopy->results?