Пример #1
0
<?php

/* _____ PHP Big Blue Button API Usage ______
* by Peter Mentzer peter@petermentzerdesign.com
* Use, modify and distribute however you like.
*/
// Require the bbb-api file:
require_once '../includes/bbb-api.php';
// Instatiate the BBB class:
$bbb = new BigBlueButton();
/* ___________ PUBLISH RECORDINGS ______ */
/* Pass a recordId and true/false to publish or unpublish a recording.
*/
$recordingParams = array('recordId' => '8cb2237d0679ca88db6464eac60da96345513964-1333379469215', 'publish' => 'true');
// Now do it:
$itsAllGood = true;
try {
    $result = $bbb->publishRecordingsWithXmlResponseArray($recordingParams);
} catch (Exception $e) {
    echo 'Caught exception: ', $e->getMessage(), "\n";
    $itsAllGood = false;
}
if ($itsAllGood == true) {
    //Output results to see what we're getting:
    print_r($result);
}
 public function publishRecordings($recordId = null)
 {
     $bbb = new BigBlueButton($this->salt, $this->url);
     $recordingParams = array('recordId' => $recordId, 'publish' => 'true');
     $itsAllGood = true;
     try {
         $result = $bbb->publishRecordingsWithXmlResponseArray($recordingParams);
     } catch (Exception $e) {
         echo 'Caught exception: ', $e->getMessage(), "\n";
         $itsAllGood = false;
     }
     if ($itsAllGood == true) {
         echo $result['published'];
     }
 }