creating wordpress category via XML-RPC it is possible

Discussion in 'PHP' started by ironmankho, Dec 29, 2011.

  1. #1
    creating wordpress category via XML-RPC it is possible ... i am already post using php XML-RPC .... now i want to create category ....
     
    ironmankho, Dec 29, 2011 IP
  2. ironmankho

    ironmankho Active Member

    Messages:
    393
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    55
    #2
    <?php
    include 'IXR_Library.php';

    $log = '';
    $pwd = '';
    $xmlrpc = 'http://www..com/xmlrpc.php';

    $client = new IXR_Client($xmlrpc);

    $res = $client->query('wp.newCategory', '', $log, $pwd,
    array(
    'name' => '@MyCat000egory',
    'slug' => 'my-category-slug',
    'parent_id' => 0,
    'description' => 'Test category by xml-rpc'
    )
    );
    ?>
     
    ironmankho, Jan 26, 2012 IP