Exemple #1
0
 function __construct($pImageId = NULL, $pContentId = NULL)
 {
     parent::__construct();
     $this->mImageId = (int) $pImageId;
     $this->mContentId = (int) $pContentId;
     $this->registerContentType(FISHEYEIMAGE_CONTENT_TYPE_GUID, array('content_type_guid' => FISHEYEIMAGE_CONTENT_TYPE_GUID, 'content_name' => 'Image', 'handler_class' => 'FisheyeImage', 'handler_package' => 'fisheye', 'handler_file' => 'FisheyeImage.php', 'maintainer_url' => 'http://www.bitweaver.org'));
     // Permission setup
     $this->mViewContentPerm = 'p_fisheye_view';
     $this->mUpdateContentPerm = 'p_fisheye_update';
     $this->mAdminContentPerm = 'p_fisheye_admin';
 }
Exemple #2
0
 function __construct($pGalleryId = NULL, $pContentId = NULL)
 {
     parent::__construct();
     if ($this->verifyId($pGalleryId)) {
         $this->mGalleryId = (int) $pGalleryId;
         // Set member variables according to the parameters we were passed
     }
     if ($this->verifyId($pContentId)) {
         $this->mContentId = (int) $pContentId;
         // liberty_content.content_id which this gallery references
     }
     $this->mItems = array();
     // Assume no images (if $pAutoLoad is TRUE we will populate this array later)
     $this->mAdminContentPerm = 'p_fisheye_admin';
     // This registers the content type for FishEye galleries
     // FYI: Any class which uses a table which inherits from liberty_content should create their own content type(s)
     $this->registerContentType(FISHEYEGALLERY_CONTENT_TYPE_GUID, array('content_type_guid' => FISHEYEGALLERY_CONTENT_TYPE_GUID, 'content_name' => 'Image Gallery', 'content_name_plural' => 'Image Galleries', 'handler_class' => 'FisheyeGallery', 'handler_package' => 'fisheye', 'handler_file' => 'FisheyeGallery.php', 'maintainer_url' => 'http://www.bitweaver.org'));
     // Permission setup
     $this->mViewContentPerm = 'p_fisheye_view';
     $this->mCreateContentPerm = 'p_fisheye_create';
     $this->mUpdateContentPerm = 'p_fisheye_update';
     $this->mAdminContentPerm = 'p_fisheye_admin';
 }