2 /****************************************************************/
\r
4 /****************************************************************/
\r
5 /* Copyright (c) 2010
\r
6 /* Written by Antonio Gamba
\r
7 /* Adaptive Technology Resource Centre / University of Toronto
\r
9 /* This program is free software. You can redistribute it and/or
\r
10 /* modify it under the terms of the GNU General Public License
\r
11 /* as published by the Free Software Foundation.
\r
12 /****************************************************************/
\r
16 public static function putCaps($uri, $action, $id, $ccData)
\r
18 if ($ccData!='The format of source Caption was not recognized.')
\r
20 //$uri = '../../service.php?';
\r
22 $ch = curl_init($uri);
\r
23 $encoded = 'id='.$id.'&action='.$action.'&cc='.''.urlencode($ccData).'';
\r
24 curl_setopt($ch, CURLOPT_POSTFIELDS, $encoded);
\r
25 curl_setopt($ch, CURLOPT_HEADER, 0);
\r
26 curl_setopt($ch, CURLOPT_POST, 1);
\r
29 if(OC_DEBUG_MODE_ON)
\r
31 echo '<br/> Encoded Data sent to Server:<br/> '.$encoded.'<br/>';
\r