Changeset 881
- Timestamp:
- 09/03/08 01:02:42 (3 months ago)
- Location:
- plugins/hpm/trunk
- Files:
-
- 6 modified
-
dunzip2.php (modified) (1 diff)
-
habaripackage.php (modified) (1 diff)
-
habaripackages.php (modified) (2 diffs)
-
hpm.plugin.php (modified) (7 diffs)
-
tarreader.php (modified) (1 diff)
-
templates/hpm_notice.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
plugins/hpm/trunk/dunzip2.php
r216 r881 1 <? 1 <?php 2 2 // 15/07/2006 (2.6) 3 3 // - Changed the algorithm to parse the ZIP file.. Now, the script will try to mount the compressed -
plugins/hpm/trunk/habaripackage.php
r581 r881 193 193 private function build_install_profile() 194 194 { 195 if ( ! $this->archive->get_file_list() ) { 196 throw new Exception( "Archive does not contain any files" ); 197 } 198 195 199 $install_profile= array(); 196 200 foreach ( $this->archive->get_file_list() as $file ) { -
plugins/hpm/trunk/habaripackages.php
r581 r881 221 221 public static function tempnam() 222 222 { 223 return tempnam( HABARI_PATH . '/ system/cache', 'HPM-' );223 return tempnam( HABARI_PATH . '/3rdparty/hpm', 'HPM-' ); 224 224 } 225 225 … … 227 227 { 228 228 $tmp_dir = 'HPM-' . md5( UUID::get() ); 229 if ( is_writable( HABARI_PATH . "/ system/cache" ) ) {230 $tmp_dir = HABARI_PATH . "/ system/cache/$tmp_dir";229 if ( is_writable( HABARI_PATH . "/3rdparty/hpm" ) ) { 230 $tmp_dir = HABARI_PATH . "/3rdparty/hpm/$tmp_dir"; 231 231 } 232 232 else { -
plugins/hpm/trunk/hpm.plugin.php
r560 r881 3 3 class HPM extends Plugin 4 4 { 5 const VERSION= '0.1'; 5 const VERSION= '0.2'; 6 const DB_VERSION = 001; 6 7 7 8 function info() … … 9 10 return array ( 10 11 'name' => 'HPM', 11 'version' => '0. 1',12 'version' => '0.2.alpha', 12 13 'author' => 'Habari Community', 13 14 'license' => 'Apache License 2.0', … … 17 18 public function action_init() 18 19 { 19 Plugins::act( 'hpm_init' );20 20 } 21 21 … … 24 24 Update::add( 'hpm', '693E59D6-2B5F-11DD-A23A-9E6C56D89593', $this->info->version ); 25 25 } 26 26 27 /** 28 * @todo fix this schema!!!! 29 */ 27 30 public function action_plugin_activation( $file ) 28 31 { … … 130 133 public function action_admin_theme_get_hpm( $handler, $theme ) 131 134 { 135 Plugins::act( 'hpm_init' ); 136 132 137 if ( isset( $handler->handler_vars['action'] ) ) { 133 138 $action= $handler->handler_vars['action']; … … 136 141 } 137 142 else { 138 Plugins::act( "hpm_ $action", $handler, $theme );143 Plugins::act( "hpm_act_$action", $handler, $theme ); 139 144 } 140 145 } … … 144 149 } 145 150 146 if ( !is_writable( HabariPackages::temp nam() ) || !is_writable( HABARI_PATH . '/3rdparty' ) ) {151 if ( !is_writable( HabariPackages::tempdir() ) || !is_writable( HABARI_PATH . '/3rdparty' ) ) { 147 152 $theme->notice = 'permissions'; 148 153 $theme->display('hpm_notice'); -
plugins/hpm/trunk/tarreader.php
r216 r881 70 70 private $filename; 71 71 private $tar_file; 72 private $filelist = array();73 private $files ;72 private $filelist = array(); 73 private $files = array(); 74 74 private $directories; 75 75 -
plugins/hpm/trunk/templates/hpm_notice.php
r560 r881 7 7 <p>HPM requires the temporary folder and install location to be writable by the server. Please make the following changes.</p> 8 8 9 <?php if ( !is_writable( HabariPackages::temp nam() ) ) : ?>9 <?php if ( !is_writable( HabariPackages::tempdir() ) ) : ?> 10 10 <h3>Temporary Folder</h3> 11 <p>Please make <?php echo HabariPackages::temp nam(); ?> writable by the server</p>11 <p>Please make <?php echo HabariPackages::tempdir(); ?> writable by the server</p> 12 12 <p>...explain the process here...</p> 13 13 <?php endif; ?>
