question

mobileincanada avatar image
1 Like"
mobileincanada asked

Need help with ItemSpecifics PHP

 

$item->ItemSpecifics = new NameValueListArrayType();

$item->ItemSpecifics->NameValueList = new NameValueListType();

$item->ItemSpecifics->NameValueList->Name = "Compatible Brand";

$item->ItemSpecifics->NameValueList->Value = "For Audiovox";

 

$item->ItemSpecifics->NameValueList->Name = "Material";

$item->ItemSpecifics->NameValueList->Value = "Rigid Plastic";

 

i try this but the "material" "rigid Plastic" do not appears in the listing, anyone can help please ?

PHPitemspecificsebatns
10 |600

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
davidtsadler avatar image
0 Likes"
davidtsadler answered

Hello,

 

You may get the results your desire by using the following code.

 

$itemSpecifics = new NameValueListArrayType();

$specific = new NameValueListType();
$specific->setName('Compatible Brand');
$specific->setValue('For Audiovo');
$itemSpecifics->setNameValueList($specific, 0);

$specific = new NameValueListType();
$specific->setName('Material');
$specific->setValue('Rigid Plastic');
$itemSpecifics->setNameValueList($specific, 1);

 

$item->setItemSpecifics($itemSpecifics);

 

I have some example code at https://gist.github.com/4581805 which was used to list an item to the eBay Sandbox. This item can be found at http://cgi.sandbox.ebay.com/110111001092

 

Hope this helps,

David

10 |600

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.