Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Insufficient arguments passed to this XML-RPC method. #26

Closed
eduardodgarciac opened this issue Feb 2, 2016 · 5 comments
Closed

Insufficient arguments passed to this XML-RPC method. #26

eduardodgarciac opened this issue Feb 2, 2016 · 5 comments

Comments

@eduardodgarciac
Copy link

I am trying to make a new Post and it throws me this error "Insufficient arguments passed to this XML-RPC method."

$wpClient = new WordpressClient($domain->url, $domain->user, $domain->password);
$wpClient->newPost('Tittle', 'Content');

The getProfile method works fine, so there is no problem with the credentials

Can anyone help me with this?
Thanks in advance

@letrunghieu
Copy link
Owner

Which version of PHP do you use? There are some problems with PHP 7 that I am investigating.

@eduardodgarciac
Copy link
Author

Oh I see... I'm using php 7. Well, I'm breaking my head with that error

letrunghieu added a commit that referenced this issue Feb 3, 2016
@letrunghieu
Copy link
Owner

The problem is fixed, you can composer update to get the latest version of this package. Please read the release note of the version 2.5.0 here

@eduardodgarciac
Copy link
Author

Thank you very much. I already tested and seems to works perfectly

@clmadrazo
Copy link

clmadrazo commented Dec 2, 2016

I have this same problem. Before upgrading to PHP7 I was working fine. I already upgraded to version 2.5 and I still have the same problem.

$wpClient = new \HieuLe\WordpressXmlrpcClient\WordpressClient($endpoint, $user, $pass, $wpLog);
$options = array(
'post_status' => 'draft',
'terms_names' => array(
'post_tag' => $schedule->getPost()->getWPTagsArray(),
'category' => $schedule->getPost()->getWPCategoriesArray()
),
);
$response = $wpClient->newPost($schedule->getPost()->getTitle(), $schedule->getPost()->getPostText(), $options);

array(2) {
["faultCode"]=>
int(400)
["faultString"]=>
string(53) "Insufficient arguments passed to this XML-RPC method."
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants