Changeset 13617
- Timestamp:
- 11/23/07 15:48:35 (1 year ago)
- Files:
-
- trunk/midcom/midcom.helper.imagepopup/config/config.inc (modified) (1 diff)
- trunk/midcom/midcom.helper.imagepopup/handler/list.php (modified) (3 diffs)
- trunk/midcom/midcom.helper.imagepopup/viewer.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/midcom/midcom.helper.imagepopup/config/config.inc
r3120 r13617 1 2 /* @TODO 3 * Have a table of allowed file types. 4 * Max number of mb uploadable 5 */ 6 7 8 1 'enable_page' => true, trunk/midcom/midcom.helper.imagepopup/handler/list.php
r12615 r13617 34 34 parent::midcom_baseclasses_components_handler(); 35 35 } 36 37 /** 38 * Load the schemadb and other midcom.admin.folder specific stuff 39 * 40 * @access public 41 */ 42 function _on_initialize() 43 { 44 $this->_config =& $GLOBALS['midcom_component_data']['midcom.helper.imagepopup']['config']; 45 } 36 46 37 47 function _prepare_request_data() … … 45 55 $_MIDCOM->auth->require_valid_user(); 46 56 $_MIDCOM->skip_page_style = true; 57 58 if (!$this->_config->get('enable_page')) 59 { 60 if ($handler_id == '____ais-imagepopup-list_object') 61 { 62 $_MIDCOM->relocate('__ais/imagepopup/folder/default/'); 63 } 64 elseif ($handler_id =='____ais-imagepopup-list_folder') 65 { 66 $_MIDCOM->relocate('__ais/imagepopup/folder/default/'); 67 } 68 elseif ($handler_id =='____ais-imagepopup-list_unified') 69 { 70 $_MIDCOM->relocate('__ais/imagepopup/unified/default/'); 71 } 72 } 47 73 48 74 $_MIDCOM->add_link_head … … 213 239 $session =& $_MIDCOM->get_service('session'); 214 240 215 if (!$session->exists('midcom.helper.datamanager2', $key)) 216 { 217 $_MIDCOM->generate_error(MIDCOM_ERRCRIT, "Could not find datamanager2 schema session with key: {$key}."); 218 // this exits. 219 } 220 221 $schema = $session->get('midcom.helper.datamanager2', $key); 241 if ($session->exists('midcom.helper.datamanager2', $key)) 242 { 243 $schema = $session->get('midcom.helper.datamanager2', $key); 244 } 245 else 246 { 247 $schema = array 248 ( 249 'description' => 'generated schema', 250 'fields' => array(), 251 ); 252 } 222 253 223 254 $imagetypes = array trunk/midcom/midcom.helper.imagepopup/viewer.php
r6157 r13617 23 23 function get_plugin_handlers() 24 24 { 25 26 // Dumb $this on PHP5 workaround 27 28 $object =& $this;25 $_MIDCOM->load_library('midcom.helper.imagepopup'); 26 27 // Dumb $this on PHP5 workaround 28 $object =& $this; 29 29 30 30 // Match /folder/<schema>/<object guid>
