Skip to content

Instantly share code, notes, and snippets.

@raytiley
Created September 13, 2010 15:44
Show Gist options
  • Save raytiley/577485 to your computer and use it in GitHub Desktop.
Save raytiley/577485 to your computer and use it in GitHub Desktop.
<?php
function updateProjectIDforShow($show_id, $project_id) {
if($cablecast_client = $this->get_cablecast_client()) {
$showInfo = $cablecast_client->GetShowInformation($show_id);
$showInfo = $showInfo->GetShowInformationResult;
$params = array("ShowID" => $showInfo->ShowID,
"LocalID" => $showInfo->LocalID,
"Title" => $showInfo->InternalTitle,
"CGTitle" => $showInfo->Title,
"ProjectID" => $project_id,
"CGExempt" => $showInfo->CGExempt,
"ProducerID" => $showInfo->ProducerID,
"CategoryID" => $showInfo->CategoryID,
"EventDate" => $showInfo->EventDate,
"Comments" => $showInfo->Comments,
"OnDemand" => $showInfo->OnDemand,
"OnDemandStatus" => $showInfo->OnDemandStatus,
"BugText" => $showInfo->BugText,
"CrawlText" => $showInfo->CrawlText,
"CrawlLengthInSeconds" => $showInfo->CrawlLengthInSeconds,
"username" => "username",
"password" => "xxx",
);
dpm($showInfo);
try {
return $cablecast_client->UpdateShowRecord($params);
}
catch(SoapFault $fault) {
watchdog("Cablecast", "Communicating to server caused the following error: ".$fault->faultstring);
dpm($fault->faultstring);
}
}
else {
return FALSE;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment