Example #1
0
 public function __construct($obj = null)
 {
     parent::__construct($obj);
     if (!$this->title) {
         $this->title = t("My Video");
     }
 }
Example #2
0
 public function __construct($obj = null)
 {
     $this->cID = null;
     $this->bID = null;
     parent::__construct($obj);
     $c = Page::getCurrentPage();
     if (is_object($c)) {
         $this->cID = $c->getCollectionID();
     }
     if ($this->bID) {
         $db = Database::connection();
         $v = array($this->bID);
         $q = "SELECT optionID, optionName, displayOrder FROM btSurveyOptions WHERE bID = ? ORDER BY displayOrder ASC";
         $r = $db->query($q, $v);
         $this->options = array();
         if ($r) {
             while ($row = $r->fetchRow()) {
                 $opt = new Option();
                 $opt->optionID = $row['optionID'];
                 $opt->cID = $this->cID;
                 $opt->optionName = $row['optionName'];
                 $opt->displayOrder = $row['displayOrder'];
                 $this->options[] = $opt;
             }
         }
     }
 }
Example #3
0
    function __construct($obj = null)
    {
        if (is_object($obj)) {
            switch (strtolower(get_class($obj))) {
                case "blocktype":
                    // instantiating autonav on a particular collection page, instead of adding
                    // it through the block interface
                    $this->bID = null;
                    break;
                case "block": // block
                    // standard block object
                    $this->bID = $obj->bID;
                    break;
            }
        }

        $c = Page::getCurrentPage();
        if (is_object($c)) {
            if ($c->getCollectionPointerOriginalID() > 0) {
                $this->cID = $c->getCollectionPointerOriginalID();
            } else {
                $this->cID = $c->getCollectionID();
            }
            $this->cParentID = $c->getCollectionParentID();
        }

        parent::__construct($obj);
    }
 public function __construct($b = null)
 {
     parent::__construct($b);
     //$this->bID = intval($this->_bID);
     if (is_string($this->thankyouMsg) && !strlen($this->thankyouMsg)) {
         $this->thankyouMsg = $this->getDefaultThankYouMsg();
     }
 }
Example #5
0
 /**
  * Instantiates the block controller.
  *
  * @param BlockType|null $obj
  * @param \Concrete\Core\Statistics\UsageTracker\AggregateTracker $tracker
  */
 public function __construct($obj = null, AggregateTracker $tracker = null)
 {
     parent::__construct($obj);
     $this->tracker = $tracker;
 }
Example #6
0
 public function __construct($blockType = null, AggregateTracker $tracker = null)
 {
     parent::__construct($blockType);
     $this->tracker = $tracker;
 }
 function __construct($obj = null)
 {
     parent::__construct($obj);
 }