[Easymod-cvs] easymod2/mods/easymod/includes admin_easymod.php.txt,1.2,1.3 mod_settings.tpl,1.1,1.2
Status: Beta
Brought to you by:
wgeric
From: Jim W. <ter...@us...> - 2005-05-01 07:23:03
|
Update of /cvsroot/easymod/easymod2/mods/easymod/includes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23804/mods/easymod/includes Modified Files: admin_easymod.php.txt mod_settings.tpl Log Message: Can now use arbitrary ports. Index: admin_easymod.php.txt =================================================================== RCS file: /cvsroot/easymod/easymod2/mods/easymod/includes/admin_easymod.php.txt,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** admin_easymod.php.txt 29 Apr 2005 00:50:26 -0000 1.2 --- admin_easymod.php.txt 1 May 2005 07:22:50 -0000 1.3 *************** *** 176,180 **** $sql = "SELECT * FROM " . EASYMOD_TABLE . " ! WHERE mod_title = '" . substr( $mod_title, 0, 255) . "' AND mod_version = '" . substr( $mod_version, 0, 15) . "' ORDER BY mod_id DESC" ; --- 176,180 ---- $sql = "SELECT * FROM " . EASYMOD_TABLE . " ! WHERE mod_title = '" . substr( $mod_title, 0, 100) . "' AND mod_version = '" . substr( $mod_version, 0, 15) . "' ORDER BY mod_id DESC" ; *************** *** 534,537 **** --- 534,541 ---- $ftp_host = $row['config_value'] ; } + else if ( $row['config_name'] == 'EM_ftp_port') + { + $ftp_port = $row['config_value'] ; + } else if ( $row['config_name'] == 'EM_ftp_type') { *************** *** 559,563 **** // easiest thing to do is return a mod_io object ! return new mod_io( $filename, $path, $read, $write, $move, $ftp_user, $ftp_pass, $ftp_dir, $ftp_host, $ftp_type, $ftp_cache) ; } --- 563,567 ---- // easiest thing to do is return a mod_io object ! return new mod_io( $filename, $path, $read, $write, $move, $ftp_user, $ftp_pass, $ftp_dir, $ftp_host, $ftp_port, $ftp_type, $ftp_cache) ; } *************** *** 886,889 **** --- 890,894 ---- 'L_FTP_PASS' => $lang['EM_ftp_pass'], 'L_FTP_HOST' => $lang['EM_ftp_host'], + 'L_FTP_PORT' => $lang['EM_ftp_port'], 'L_FTP_EXT' => $lang['EM_ftp_use_ext'], 'L_FTP_EXT_WARN' => $lang['EM_ftp_ext_not'], *************** *** 904,907 **** --- 909,913 ---- 'FTP_PATH' => $command_file->ftp_path, 'FTP_HOST' => $command_file->ftp_host, + 'FTP_PORT' => $command_file->ftp_port, 'FTP_EXT' => ($command_file->ftp_type == 'ext') ? 'checked="checked"' : '', 'FTP_FSOCK' => ($command_file->ftp_type == 'fsock') ? 'checked="checked"' : '', *************** *** 933,936 **** --- 939,943 ---- $ftp_pass = (isset($HTTP_POST_VARS['ftp_pass'])) ? htmlspecialchars( $HTTP_POST_VARS['ftp_pass']) : '' ; $ftp_host = (isset($HTTP_POST_VARS['ftp_host'])) ? htmlspecialchars( $HTTP_POST_VARS['ftp_host']) : '' ; + $ftp_port = (isset($HTTP_POST_VARS['ftp_port'])) ? intval( $HTTP_POST_VARS['ftp_port']) : 0 ; $ftp_type = (isset($HTTP_POST_VARS['ftp_type'])) ? htmlspecialchars( $HTTP_POST_VARS['ftp_type']) : 'fsock' ; $ftp_cache = (isset($HTTP_POST_VARS['ftp_cache'])) ? intval( $HTTP_POST_VARS['ftp_cache']) : 0 ; *************** *** 971,974 **** --- 978,982 ---- em_db_update( 'EM_ftp_pass', $ftp_pass) ; em_db_update( 'EM_ftp_host', $ftp_host) ; + em_db_update( 'EM_ftp_port', $ftp_port) ; em_db_update( 'EM_ftp_type', $ftp_type) ; em_db_update( 'EM_ftp_cache', $ftp_cache) ; *************** *** 2706,2710 **** // write the command files $command_file = get_em_settings( 'post_process.sh', '', $password, $preview) ; ! $command_bat = new mod_io( 'post_process.bat', '', $command_file->read_method, $command_file->write_method, $command_file->move_method, $command_file->ftp_user, $command_file->ftp_pass, $command_file->ftp_dir, $command_file->ftp_host, $command_file->ftp_type, $command_file->ftp_cache) ; // open the command file: config=true,command=true --- 2714,2718 ---- // write the command files $command_file = get_em_settings( 'post_process.sh', '', $password, $preview) ; ! $command_bat = new mod_io( 'post_process.bat', '', $command_file->read_method, $command_file->write_method, $command_file->move_method, $command_file->ftp_user, $command_file->ftp_pass, $command_file->ftp_dir, $command_file->ftp_host, $command_file->ftp_port, $command_file->ftp_type, $command_file->ftp_cache) ; // open the command file: config=true,command=true *************** *** 2868,2872 **** $phpbb_version = get_phpbb_version() ; ! $mod_title = str_replace("'", "''", substr( $mod_title, 0, 255)) ; $mod_author_handle = str_replace("'", "''", substr( $mod_author_handle, 0, 25)) ; $mod_author_email = str_replace("'", "''", substr( $mod_author_email, 0, 100)) ; --- 2876,2880 ---- $phpbb_version = get_phpbb_version() ; ! $mod_title = str_replace("'", "''", substr( $mod_title, 0, 50)) ; $mod_author_handle = str_replace("'", "''", substr( $mod_author_handle, 0, 25)) ; $mod_author_email = str_replace("'", "''", substr( $mod_author_email, 0, 100)) ; Index: mod_settings.tpl =================================================================== RCS file: /cvsroot/easymod/easymod2/mods/easymod/includes/mod_settings.tpl,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** mod_settings.tpl 24 Apr 2005 14:59:53 -0000 1.1 --- mod_settings.tpl 1 May 2005 07:22:50 -0000 1.2 *************** *** 61,64 **** --- 61,68 ---- </tr> <tr> + <td class="row1" align="right"><span class="gen">{L_FTP_PORT}</span></td> + <td class="row2"><input type="text" size="5" maxlength="5" name="ftp_port" value="{FTP_PORT}"></td> + </tr> + <tr> <td class="row1" align="right"><span class="gen">{L_FTP_EXT}</span></td> <td class="row2"> |