Click here to Skip to main content
15,897,891 members
Home / Discussions / Web Development
   

Web Development

 
GeneralRe: encrypt and decrypt Pin
Guffa19-Aug-05 22:36
Guffa19-Aug-05 22:36 
GeneralRe: encrypt and decrypt Pin
alex.barylski21-Aug-05 10:00
alex.barylski21-Aug-05 10:00 
GeneralRe: encrypt and decrypt Pin
Vasudevan Deepak Kumar23-Aug-05 0:40
Vasudevan Deepak Kumar23-Aug-05 0:40 
GeneralOn-click events for dynamically created buttons Pin
wpcolleen19-Aug-05 4:20
wpcolleen19-Aug-05 4:20 
GeneralRe: On-click events for dynamically created buttons Pin
Diep-Virezer20-Aug-05 9:35
Diep-Virezer20-Aug-05 9:35 
Generalwebservice Pin
WDI18-Aug-05 20:46
WDI18-Aug-05 20:46 
GeneralRe: webservice Pin
Guffa18-Aug-05 22:01
Guffa18-Aug-05 22:01 
GeneralXML-RPC from PHP Pin
progman18-Aug-05 12:22
progman18-Aug-05 12:22 
Examples taken here :
http://pear.php.net/manual/en/package.webservices.xml-rpc.examples.php

Client : Client.php

<?<br />
<br />
ini_set("include_path", 'D:\Program Files\XML_RPC\;'. ini_get("include_path"));<br />
<br />
require_once 'RPC.php';<br />
<br />
$input = 8;<br />
$params = array(new XML_RPC_Value($input, 'int'));<br />
$msg = new XML_RPC_Message('times2', $params);<br />
<br />
$cli = new XML_RPC_Client('xmlrpc.php', '');<br />
$resp = $cli->send($msg);<br />
<br />
if (!$resp) {<br />
    echo '>Communication error: ' . $cli->errstr ;<br />
    exit;<br />
    // HERE THE BRAKES BUT WHY ???<br />
}<br />
<br />
if (!$resp->faultCode()) {<br />
    $val = $resp->value();<br />
    echo $input . ' times 2 is ' . $val->scalarval();<br />
} else {<br />
    /*<br />
     * Display problems that have been gracefully cought and<br />
     * reported by the xmlrpc.php script.<br />
     */<br />
    echo 'Fault Code: ' . $resp->faultCode() . "\n";<br />
    echo 'Fault Reason: ' . $resp->faultString() . "\n";<br />
}<br />
<br />
<br />
?><br />


Server : xmlrpc.php
<?<br />
<br />
ini_set("include_path", 'D:\Program Files\XML_RPC\;'. ini_get("include_path"));<br />
<br />
require_once 'Server.php';<br />
<br />
function returnTimes2($params) {<br />
    $param = $params->getParam(0);<br />
<br />
    // This error checking syntax was added in Release 1.3.0<br />
    if (!XML_RPC_Value::isValue($param)) {<br />
        return $param;<br />
    }<br />
<br />
    $val = new XML_RPC_Value($param->scalarval() * 2, 'int'); <br />
    return new XML_RPC_Response($val);<br />
}<br />
<br />
$server = new XML_RPC_Server(<br />
    array(<br />
        'times2' =><br />
            array(<br />
                'function' => 'returnTimes2'<br />
            )<br />
    )<br />
);<br />
<br />
?><br />


But when i run client.php it generates :
Communication error : Operation successfull
Whithout any retrieved code from server ...
But Why ?
GeneralJavascript: Cursor position in Textare Pin
bin_bin118-Aug-05 9:33
bin_bin118-Aug-05 9:33 
GeneralRe: javascript Cursor position in Textare Pin
alex.barylski21-Aug-05 10:17
alex.barylski21-Aug-05 10:17 
GeneralSMTP Question Pin
sweep12318-Aug-05 5:55
sweep12318-Aug-05 5:55 
GeneralRe: SMTP Question Pin
Guffa18-Aug-05 9:16
Guffa18-Aug-05 9:16 
GeneralRe: SMTP Question Pin
Grahamfff18-Aug-05 10:47
Grahamfff18-Aug-05 10:47 
QuestionIs there way to save complete web page? Pin
AlKoltsov17-Aug-05 22:50
AlKoltsov17-Aug-05 22:50 
AnswerRe: Is there way to save complete web page? Pin
Andy Brummer18-Aug-05 13:14
sitebuilderAndy Brummer18-Aug-05 13:14 
Generalsplash screen Pin
raj_marthy17-Aug-05 17:57
raj_marthy17-Aug-05 17:57 
GeneralRe: splash screen Pin
Christian Graus17-Aug-05 17:58
protectorChristian Graus17-Aug-05 17:58 
GeneralRe: splash screen Pin
MoustafaS18-Aug-05 9:32
MoustafaS18-Aug-05 9:32 
Generaljavascript textarea problem. Pin
bin_bin117-Aug-05 13:13
bin_bin117-Aug-05 13:13 
GeneralRe: javascript textarea problem. Pin
minhpc_bk17-Aug-05 16:50
minhpc_bk17-Aug-05 16:50 
GeneralThanks for your reply. Pin
bin_bin117-Aug-05 19:54
bin_bin117-Aug-05 19:54 
GeneralRe: Thanks for your reply. Pin
minhpc_bk17-Aug-05 21:32
minhpc_bk17-Aug-05 21:32 
GeneralRe: Thanks for your reply. Pin
bin_bin118-Aug-05 9:31
bin_bin118-Aug-05 9:31 
GeneralRe: Thanks for your reply. Pin
MrRedBull190125-Aug-05 1:05
MrRedBull190125-Aug-05 1:05 
GeneralJavascript and ado Pin
delnaz17-Aug-05 3:06
delnaz17-Aug-05 3:06 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.