Post: http://www.namedoseusite.com.br/api_products_others.php?af?
Header Parameter | format |
Usuario1 | base64_encode () |
password1 | base64_encode () |
Parameter | format | description |
Products_id | json |
Number of Products_id |
Products_options & GT; & GT; Products_options_id | json |
Number of Products_Options_id |
Products_Options_Values & GT; & GT; Products_options_Values_id | json |
Number of Products_Options_Values_id |
Note: When editing you need to send all attribute and values options again, due to all attributes and values in the editing process.
php sample
// sample add list product options and values$ URL = $ tabain_url. ' /API_Products_Ors.php? Action = Add_Products_options_Values ' ;;
$ data_Options_values [0] = array ("Products_options_Values_id" = & gt; "35"
);
$ Data_Options_values [1] = array ("Products_options_Values_id" = & gt; "30"
);
$ Data_Osses [0] = array ("Products_options_id" = & gt; "4"
"Products_options_Values" = & gt; $ data_Options_Values
);$ data = array ("Products_id" = & gt; "430", // Product ID (Only Number Is Required) * Field Required
"Products_options" = & gt; $ Data_Osses
);$ data_string = json_encode ($ date);
$ CH = curl_init ($ URL);
Curl_Setopt ($ CH, curlopt_customrequest, "post");
Curl_Setopt ($ CH, Curlopt_postFields, $ Data_String);
Curl_Setopt ($ CH, Curlopt_Returntransfer, True);
curl_setopt ($ CH, curlopt_ssl_verifypeer, false);
Curl_Setopt ($ CH, Curlopt_httpheader, Array (
' CONTENT-TYPE: Application/JSON ',
"Cache-Control: No-Cache",
' Usuario1: ' . base64_encode ($ Usuario1),
' password1: ' . base64_encode ($ password1),
' CONTENT-LENGTH: ' . Strlen ($ data_string)))
);$ result = curl_exec ($ CH);
Curl_Close ($ CH);print_r ($ result);
// Sample Add List Product Options and VALUES EOF
Return Error:
Code
MessageReturn Success:
code
ID
Message