updateSkins()

Pixelsilk API function to save changes to any skins object--requires the edit-skin permission
Parameters:
input: a skins object with the properties set for updating

Output:
The function updateSkins returns void.

C# Example:
For this example assume an object has been instantiated and its properties set. Assume it is called inputObj.

object input = inputObj;
UpdateSkins(input);
Note the capital first letter of the C# method.

HTTP Example:
Request Headers:
POST /api2/updateSkins HTTP/1.1
HOST: www.example.com
Content-Length: 611
Content-Type: application/x-www-form-urlencoded
Cookie: auth=44D5AD5F2139...DD651CC62A20

Request Data:
Unencoded Data:
json={
   "id":"34a3ea85-7646-467a-8482-5b51d610239e",
   "content":"This is the content",
   "viewItem":null,
   "alternatingItem":null,
   "addEditItem":null,
   "itemDetail":null,
   "firstItem":null,
   "separator":null,
   "lastItem":null,
   "activeItem":"There is something",
   "isSectionSkin":false,
   "sectionId":null,
   "typeId":"c4a3a3a2-802f-4fb2-9680-af65c6607dda"
}&token=7AdbNHZQBtwc...RPTEK8UvSUQ=

Url-encoded Data:
json=%7b%0d%0a+++...%22%0d%0a%7d&token=7AdbNHZQBtwc...TEK8UvSUQ%3d

Response Headers:
HTTP/1.1 200 OK
Set-Cookie: auth=5D4343A636E8...DB090F3A262; path=/
Content-Type: text/javascript; charset=UTF-8
Content-Length: 2

Response Data:
{}

JavaScript Example:
Method Call:
pixelsilk2.updateSkins(input, callback);

Input Object:
{
    "id":"9a60b666-dabe-4bf6-8ab2-70cc7f99fc78",
    "content":"This is the content skin.",
    "viewItem":"",
    "alternatingItem":"",
    "addEditItem":"",
    "itemDetail":"This is the item detail skin.",
    "firstItem":"",
    "separator":"",
    "lastItem":"",
    "activeItem":"",
    "isSectionSkin":false,
    "sectionId":null,
    "typeId":null
}

Returned Data:
{}

Back to Themes »