It is not posting data untill we stringify JSON data

Example is not working until we stringify json data. I have phantomjs@1.9.7-8 installed.

I tested it with a node server and posted data through phantomjs but after so many try, it just worked with JSON.stringify.
gh-pages
Prabhat Khera 2014-11-03 11:52:37 +05:30
parent 25b627de18
commit 1d5c171890
1 changed files with 2 additions and 2 deletions

View File

@ -54,10 +54,10 @@ var settings = {
headers: {
"Content-Type": "application/json"
},
data: {
data: JSON.stringify({
some: "data",
another: ["custom", "data"]
}
})
};
page.open('http://your.custom.api', settings, function(status) {