Hi,
I am using the Javascript API and need some clarification on a function call.
Using the createAsset() function, how do I add a link attribute?
I am doing this, but it is not creating the attribute:
[font="Courier New"]createAsset(144213, 'link', 'Some title', 1, 'somelinkdescription','', '', '','"link_asset_id":"144000"', '', checkRepsonse);[/font]
Regards,
Martin
Javascript API - createAssest edit_attributes syntax
martinbutt
(Martin)
#1
nnhubbard
(Nic Hubbard)
#2
Are you getting any errors in your error logs? Also, do you mean you are creating a link asset?
Anthony_Barnes
(Anthony Barnes)
#3
I think your arguments might not be correctly given for that function. Try something like:
createAsset(144213, 'link', 'Some title', 1, 'somelinkdescription',-1, 0, 0,1,'link_asset_id=144000', checkResponse);
martinbutt
(Martin)
#4
[quote]
I think your arguments might not be correctly given for that function. Try something like:
createAsset(144213, 'link', 'Some title', 1, 'somelinkdescription',-1, 0, 0,1,'link_asset_id=144000', checkResponse);
[/quote]
This worked, thanks! The documentation is a bit vague at this point. It would benefit from an example or two.
Josh_Sherwood
(Josh Sherwood)
#5
[quote]
This worked, thanks! The documentation is a bit vague at this point. It would benefit from an example or two.
[/quote]
The documentation for the JS API has been updated to include examples for each function. Check them out here.