<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -41,7 +41,50 @@ class WikiSlurpClient {
 	 *		   If an error occurs then an array containing the key 'error'
 	 *         will be returned.
 	 **/
-	public function getData() {
+	public function getData($url=null, $secret=null, $query=null, $options=null) {
+		if (!$url) {
+			return array('error'=&gt;'No URL given');
+		}
+		
+		if (!$secret) {
+			return array('error'=&gt;'No secret given');
+		}
+		
+		if (!$query) {
+			return array('error'=&gt;'No query given');
+		}
+		
+		$options['secret'] = $secret;
+		$options['query']  = $query;
+		$options['output'] = 'php';
+		
+		$queryOptions = array();
+		foreach ( $options as $key=&gt;$value) {
+			array_push($queryOptions, $key.'='.urlencode($value));
+		}
+		
+		$queryString = implode('&amp;', $queryOptions);
+		
+		$url .= '?' . $queryString;
+
+		$s = curl_init();
+		curl_setopt($s,CURLOPT_URL, $url);
+		curl_setopt($s,CURLOPT_HEADER,false);
+		curl_setopt($s,CURLOPT_RETURNTRANSFER,1);
+		
+		if ( isset($options['timeout']) &amp;&amp; is_numeric($options['timeout']) &amp;&amp; $options['timeout'] &gt; 0 ) {
+			curl_setopt($s,CURLOPT_TIMEOUT,intval($options['timeout']));
+		}
+
+		$result = curl_exec($s);
+		curl_close( $s );
+		
+		if ( !$result ) {
+			return array('error'=&gt;'Query timed out');
+		}
+
+		$result = unserialize($result);
+		return $result;
 		
 	}
 	</diff>
      <filename>client/WikiSlurpClient.php</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>544d8a01859676e5d6fae33476d526b9d3ccd4e5</id>
    </parent>
  </parents>
  <author>
    <name>Neil Crosby</name>
    <email>neil@thetenwordreview.com</email>
  </author>
  <url>http://github.com/NeilCrosby/wikislurp/commit/cfb2eb63a51a212709a4f755ae1b536fabb53cd6</url>
  <id>cfb2eb63a51a212709a4f755ae1b536fabb53cd6</id>
  <committed-date>2008-11-18T10:54:27-08:00</committed-date>
  <authored-date>2008-11-18T10:54:27-08:00</authored-date>
  <message>Added code to actually do things</message>
  <tree>31fdca8ee7442ca06e3df0c7361bb5c3477ae122</tree>
  <committer>
    <name>Neil Crosby</name>
    <email>neil@thetenwordreview.com</email>
  </committer>
</commit>
