Changeset 1797741
- Timestamp:
- 01/05/2018 03:28:36 PM (8 years ago)
- Location:
- dms/trunk
- Files:
-
- 8 edited
-
dms.php (modified) (2 diffs)
-
includes/general/i_db_upgrade.php (modified) (2 diffs)
-
includes/general/i_pal_wordpress.php (modified) (2 diffs)
-
pages/config.php (modified) (1 diff)
-
pages/diags.php (modified) (3 diffs)
-
pages/file_retrieve.php (modified) (1 diff)
-
pages/folder_new.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
dms/trunk/dms.php
r1775329 r1797741 4 4 Plugin URI: http://blitzenware.com 5 5 Description: The complete document management solution. 6 Version: 1.2 16 Version: 1.24 7 7 Author: Brian E. Reifsnyder 8 8 Author URI: http://blitzenware.com … … 40 40 } 41 41 42 define( 'DMS_VERSION', '1.2 1' );43 define( 'DMS_RELEASE_DATE', date_i18n( 'F j, Y', strtotime( ' 11/25/2017' ) ) );42 define( 'DMS_VERSION', '1.24' ); 43 define( 'DMS_RELEASE_DATE', date_i18n( 'F j, Y', strtotime( '01/05/2018' ) ) ); 44 44 define( 'DMS_DIR', plugin_dir_path( __FILE__ ) ); 45 45 define( 'DMS_URL', plugin_dir_url( __FILE__ ) ); -
dms/trunk/includes/general/i_db_upgrade.php
r1775329 r1797741 43 43 if ($old_version==1.17) dms_update_0117(); 44 44 if ($old_version==1.20) dms_update_0120(); 45 if ($old_version==1.21) dms_update_0121(); 46 if ($old_version==1.22) dms_update_0122(); 47 if ($old_version==1.23) dms_update_0123(); 45 48 46 49 … … 326 329 } 327 330 328 331 function dms_update_0121() 332 { 333 global $dmsdb; 334 335 $query = "UPDATE ".$dmsdb->prefix("dms_config")." "; 336 $query .= "SET data='1.22' WHERE name='version'"; 337 $dmsdb->query($query); 338 } 339 340 function dms_update_0122() 341 { 342 global $dmsdb; 343 344 $query = "UPDATE ".$dmsdb->prefix("dms_config")." "; 345 $query .= "SET data='1.23' WHERE name='version'"; 346 $dmsdb->query($query); 347 } 348 349 function dms_update_0123() 350 { 351 global $dmsdb; 352 353 $query = "UPDATE ".$dmsdb->prefix("dms_config")." "; 354 $query .= "SET data='1.24' WHERE name='version'"; 355 $dmsdb->query($query); 356 } 329 357 330 358 -
dms/trunk/includes/general/i_pal_wordpress.php
r1768471 r1797741 140 140 function query($query, $instruct = "") 141 141 { 142 if ($dms_mysqli_db == 0) $this->connect(); 142 //print "A"; 143 global $dms_mysqli_db; 144 145 //print gettype($dms_mysqli_db); 146 147 if(gettype($dms_mysqli_db) == "integer") 148 { 149 //print "INTEGER"; 150 if($dms_mysqli_db == 0) 151 { 152 //print "CONNECT"; 153 $this->connect(); 154 } 155 } 143 156 144 157 // Sanitize query. 145 158 //print "B"; 146 159 // Remove ; 147 160 $query = str_replace(";","",$query); 148 //$position = stripos($query,";");149 //if($position !== false) $query = substr($query,0,$position);161 // $position = stripos($query,";"); 162 // if($position !== false) $query = substr($query,0,$position); 150 163 151 164 // Remove -- … … 163 176 164 177 // Remove \ 165 $query = str_replace("\\","",$query); 166 //var_dump ($query); 167 168 //print "A"; 169 global $dms_mysqli_db; 170 $result = $dms_mysqli_db->query($query); 171 //print "B"; 172 /* 173 NOTE: mysql_query no longer support as of PHP 5.5.0 174 175 if($this->use_mysqli == true) 176 { 177 global $dms_mysqli_db; 178 179 $result = $dms_mysqli_db->query($query); 180 } 181 else 182 { 183 $result = mysql_query($query) or trigger_error(mysql_error().$sql); 184 } 185 */ 186 //var_dump($result); 187 188 189 /* 190 if($result == FALSE) 191 { 192 print "Query Error:\r"; 193 print " Query: ".$query."\r"; 194 print " Instruction: ".$instruct."\r"; 195 exit(0); 196 } 197 */ 198 199 if( 178 //$query = str_replace("\\","",$query); Causes problems with Windows servers. 179 //var_dump ($query); 180 181 //print "C"; 182 //global $dms_mysqli_db; 183 $result = $dms_mysqli_db->query($query); 184 //print "D"; 185 186 if( 200 187 ($result != FALSE) && 201 188 (stripos($query, "SELECT") == 0) && 202 189 (stristr($query, "SELECT") != false )) 203 { 204 $this->num_rows = $result->num_rows; 205 /* 206 if($this->use_mysqli == true) 207 { 208 $this->num_rows = $result->num_rows; 209 } 210 else 211 { 212 $this->num_rows = mysql_num_rows($result); 213 } 214 */ 215 } 216 else 190 { 191 $this->num_rows = $result->num_rows; 192 } 193 else 217 194 { 218 195 $this->num_rows = 0; 219 196 } 220 221 if ( ($this->num_rows == 1) && (strlen($instruct) > 0 ) ) 222 { 223 $result = mysqli_fetch_object($result); 224 225 /* 226 if($this->use_mysqli == true) 227 { 228 $result = mysqli_fetch_object($result); 229 } 230 else 231 { 232 $result = mysql_fetch_object($result); 233 } 234 */ 235 if($instruct == "ROW") return $result; 236 $result = $result->$instruct; 237 } 238 239 return $result; 240 } 241 242 197 //print "E"; 198 if ( ($this->num_rows == 1) && (strlen($instruct) > 0 ) ) 199 { 200 $result = mysqli_fetch_object($result); 201 202 if($instruct == "ROW") return $result; 203 $result = $result->$instruct; 204 } 205 206 return $result; 207 } 243 208 } 209 210 244 211 $dmsdb = new dms_pal_db(); 245 212 -
dms/trunk/pages/config.php
r1768471 r1797741 11 11 12 12 global $dmsdb, $dms_config, $dms_global; 13 $dms_admin_flag = $dms_global['dms_admin_flag']; 14 15 if(!$dms_admin_flag) 16 { 17 dms_redirect($dms_config['dms_url']); 18 exit(0); 19 } 13 20 14 21 $os_types = array(0=>"Unknown",1=>"Linux",2=>"Unix",3=>"Windows"); -
dms/trunk/pages/diags.php
r1768471 r1797741 66 66 print " Cached Database Version = ". $dms_config['version'] . "<BR>\r"; 67 67 68 $query = "SELECT count(*) as num_docs FROM ".$dmsdb->prefix("dms_objects")." WHERE obj_type='".FILE."'"; 69 $num_docs = $dmsdb->query($query,'num_docs'); 70 71 print " Number of Documents = ". $num_docs . "<BR>\r"; 72 68 73 69 74 /////////////// … … 97 102 98 103 print " WordPress Version = ". get_bloginfo('version') . "<BR>\r"; 104 105 $theme = wp_get_theme(); 106 $theme_name = $theme->get('Name'); 107 $theme_version = $theme->get('Version'); 108 109 print " Theme Name = " . $theme_name . "<BR>\r"; 110 print " Theme Version = " . $theme_version . "<BR>\r"; 111 112 99 113 print " Multisite = "; 100 114 $ms_output = "N/A"; … … 118 132 print " upload_max_filesize = ". ini_get("upload_max_filesize") . "<BR>\r"; 119 133 134 $error_reporting_settings_int = error_reporting(); 135 136 $error_reporting_string = ""; 137 $er_spaces = " "; 138 139 $er_beginning_spaces = ""; 140 141 for($space_loop = 0; $space_loop < 25; $space_loop++) 142 { 143 $er_beginning_spaces .= " "; 144 } 145 146 if($error_reporting_settings_int & E_ERROR) $error_reporting_string .= "E_ERROR" . $er_spaces; 147 if($error_reporting_settings_int & E_WARNING) $error_reporting_string .= "E_WARNING" . $er_spaces; 148 if($error_reporting_settings_int & E_PARSE) $error_reporting_string .= "E_PARSE" . $er_spaces; 149 if($error_reporting_settings_int & E_NOTICE) $error_reporting_string .= "E_NOTICE" . $er_spaces; 150 if($error_reporting_settings_int & E_CORE_ERROR) $error_reporting_string .= "E_CORE_ERROR" . $er_spaces; 151 if($error_reporting_settings_int & E_CORE_WARNING) $error_reporting_string .= "E_CORE_WARNING" . "<BR>" . $er_beginning_spaces; 152 if($error_reporting_settings_int & E_COMPILE_ERROR) $error_reporting_string .= "E_COMPILE_ERROR" . $er_spaces; 153 if($error_reporting_settings_int & E_COMPILE_WARNING) $error_reporting_string .= "E_COMPILE_WARNING" . $er_spaces; 154 if($error_reporting_settings_int & E_USER_ERROR) $error_reporting_string .= "E_USER_ERROR" . $er_spaces; 155 if($error_reporting_settings_int & E_USER_WARNING) $error_reporting_string .= "E_USER_WARNING" . $er_spaces; 156 if($error_reporting_settings_int & E_USER_NOTICE) $error_reporting_string .= "E_USER_NOTICE" . $er_spaces; 157 if($error_reporting_settings_int & E_STRICT) $error_reporting_string .= "E_STRICT" . "<BR>" . $er_beginning_spaces; 158 if($error_reporting_settings_int & E_RECOVERABLE_ERROR) $error_reporting_string .= "E_RECOVERABLE_ERROR" . $er_spaces; 159 if($error_reporting_settings_int & E_DEPRECATED) $error_reporting_string .= "E_DEPRECATED" . $er_spaces; 160 if($error_reporting_settings_int & E_USER_DEPRECATED) $error_reporting_string .= "E_USER_DEPRECATED" . $er_spaces; 161 if($error_reporting_settings_int & E_ALL) $error_reporting_string .= "E_ALL"; 162 163 print " error_reporting = " . $error_reporting_string . "<BR>\r"; 164 165 /* 166 print " <table><tr><td width = 125>error_reporting = </td><td>"; 167 print $error_reporting_string; 168 print "</td></tr></table><BR>\r"; 169 */ 120 170 /////////////////////// 121 171 // Database Connection -
dms/trunk/pages/file_retrieve.php
r1775329 r1797741 59 59 if( $dms_global['dms_pro_dir'] != "FALSE" ) 60 60 { 61 print "dms_global dms_pro_dir != false<br>";61 //print "dms_global dms_pro_dir != false<br>"; 62 62 63 63 -
dms/trunk/pages/folder_new.php
r1768471 r1797741 27 27 28 28 if($dms_users->admin() == FALSE) 29 // if(!$xoopsUser->IsAdmin())30 29 { 31 30 $active_folder_perms = dms_perms_level($active_folder); -
dms/trunk/readme.txt
r1775329 r1797741 98 98 == Changelog == 99 99 100 = 1.24 = 101 * Fixed security issue with configuration page. Only administrators can access this page. 102 * Fixed security issue with diagnostic page. Only administrators can access this page. 103 104 = 1.23 = 105 * Commented out a piece of debugging code that was accidentally left in in file_retrieve.php. 106 107 = 1.22 = 108 * Fixed a mysqli problem in i_pal_wordpress.php. 109 100 110 = 1.21 = 101 111 * Fixed a file retrieval error that resulted in an Internal Server Error 500 when retrieving a file. … … 193 203 == Upgrade Notice == 194 204 205 = 1.24 = 206 * Fixed security issue with configuration page. Only administrators can access this page. 207 * Fixed security issue with diagnostic page. Only administrators can access this page. 208 209 = 1.23 = 210 * Commented out a piece of debugging code that was accidentally left in in file_retrieve.php. 211 212 = 1.22 = 213 * Fixed a mysqli problem in i_pal_wordpress.php. 214 195 215 = 1.21 = 196 216 * Fixed a file retrieval error that resulted in an Internal Server Error 500 when retrieving a file.
Note: See TracChangeset
for help on using the changeset viewer.