Giter VIP home page Giter VIP logo

ripcord's Introduction

Readme                      Ripcord: Easy XML-RPC Client and Server for PHP 5
=============================================================================

Ripcord is a very easy to use XML-RPC library for PHP. It provides client, 
server and auto documentation features for XML-RPC but also SimpleRPC and
simplified SOAP (1.1). It uses PHP's xmlrpc library and it needs at least PHP 5.

To create a simple xmlrpc client do something like this:

<?php
    require_once('ripcord.php');
    $client = ripcord::xmlrpcClient( 'http://www.moviemeter.nl/ws' );
    $score  = $client->film->getScore( 'e3dee9d19a8c3af7c92f9067d2945b59', 500 );
?>

See the RipcordClientManual 
<http://code.google.com/p/ripcord/wiki/RipcordClientManual> for more information.

To create a simple xmlrpc server do something like this:

<?php
    require_once('ripcord.php');
    class myTest {
        public function Foo() {
            return 'Bar';
        }
    }
    $test = new MyTest();
    $server = ripcord::server( $test );
    $server->run();
?>

See the RipcordServerManual 
<http://code.google.com/p/ripcord/wiki/RipcordServerManual> for more information.


Extending Ripcord
=================

Ripcord is also very simple to extend. All functionality can be changed
through dependency injection. The client by default uses the PHP Streams API
to connect to a server, but can simply be reconfigured to use CURL. You
can provide your own configuration or even a completely new transport method
by simply injecting a new transport object into the client.

Any server created with Ripcord is auto documenting by default. Simply browse
to the URL of your RPC server and you will see a list of all methods including
any inline documentation for that method, if you use docblock style comments, e.g.:

/**
 * This will show up with your method description.
 */
function yourMethod() {
}

The auto documentor is again easily extended to use your own styles or extensions
and you can simply inject a completely different documentor object into the server
if you want. Or skip it altogether.


Documentation
=============

The full API documentation is included in the docs/ directory.

ripcord's People

Contributors

poef avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ripcord's Issues

UTF-8 decoding isn't set

In the file ricord_client.php line 229 - xmlrpc_decode doesn't have the encoding parameter set correctly. Due to that strings are decoded into ISO-8859-1 and not UTF-8 (as that seems to be the default behavior for that function as documented in PHP Doc).

Suggested fix:

$result = xmlrpc_decode( $response , (array_key_exists('encoding', $this->_outputOptions)) ? $this->_outputOptions['encoding'] : null);

Server bug causes methods to be called twice

I was having a problem with all of my server side methods being called twice. I 
tracked it down to the "run" method in ripcord_server.php. The problematic bit 
is 

[code]          
header('Content-type: text/xml');
header('Access-Control-Allow-Origin: *');
header("Content-Length: ".strlen($this->handle( $request_xml )));
echo $this->handle( $request_xml );
[/code]

I changed it to
[code]
$handledXml = $this->handle($requestXml);
header('Content-type: text/xml');
header('Access-Control-Allow-Origin: *');
header("Content-Length: ".strlen(handledXml));
echo handledXml;
[/code]

Perhaps I was doing something wrong but it fixed my problem.

Original issue reported on code.google.com by [email protected] on 9 Dec 2012 at 7:25

Is this project alive?

Hello, it appears this project is no longer active but I would like to confirm. 

I own the ripcord.io domain name and github.com/RipcordIO org and was planning 
on using it for an RPC/IPC library but then was made aware of this project. 

I would like to ensure I'm not doing hard if I proceed with using the Ripcord 
IO name. 

Original issue reported on code.google.com by [email protected] on 16 Dec 2014 at 11:21

function xmlrpcClient don't use param $transport

In documentation I see:
$client = ripcord::xmlrpcClient( $url, null, $transport );

but in ripcord.php at line 192
public static function xmlrpcClient($url, $options = null) 
{
    $options['version'] = 'xmlrpc';
    return self::client($url, $options);
}

I don't see param $transport in function xmlrpcClient. Maybe it should be
public static function xmlrpcClient($url, $options = null, $transport = null) 
{
    $options['version'] = 'xmlrpc';
    return self::client($url, $options, $transport);
}
?

Original issue reported on code.google.com by [email protected] on 7 Mar 2011 at 11:23

Move to Github?

Hello, 
Google is planning to close google project hub 
(http://www.fiercedevops.com/story/google-plans-closure-google-code-project-host
ing-site/2015-03-17).

Are you going to move to Github?

Original issue reported on code.google.com by [email protected] on 24 Jun 2015 at 7:31

Php 7.0 is supported ?

"It uses PHP's xmlrpc library and it needs at least PHP 5.".

Should I understand 5 and more .. or 5.X only ?

Ripcord is not working in live server

I'm using ripcord to connect php to odoo server via webservice api. The library 
is working perfectly in local, but in server is not working and is getting a 
lot of time to work.

Any idea if it's modules php or other thing?

Original issue reported on code.google.com by [email protected] on 15 Jun 2015 at 10:24

ripcord::xmlrpcClient, with https url

hai..
thank you so much for build ripcord,
very very nice..


owh ya, i have a problem with https url..
in my project, i've change the method post on Ripcord_Transport_Stream 
implements Ripcord_Transport..


to: (see attachment)

this is just my suggestion :-)
once again.. thank you very much for ripcord.

Original issue reported on code.google.com by mr.ryansilalahi on 13 Aug 2012 at 5:18

Attachments:

ripcord_client response encoding

Hi,

I'm using ripcord to get data from Odoo. When sending some request to Odoo, I get the response in ASCII charset, but the request was defined as UTF-8.

In file ripcord_client.php on line 229, there is missing a second parameter for xmlrpc_decode().

Instead of

$result = xmlrpc_decode( $response );

there should be something like this

$result = xmlrpc_decode( $response, $this->_outputOptions['encoding'] );

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.