|
From: Jon O. <jon...@us...> - 2006-06-27 21:38:47
|
Update of /cvsroot/mxbb/mx_pafiledb In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv13505/modules/mx_pafiledb Modified Files: db_install.php db_uninstall.php dload.php dload_lists.php dload_quickdl.php Log Message: a couple of bugs... Index: db_install.php =================================================================== RCS file: /cvsroot/mxbb/mx_pafiledb/db_install.php,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** db_install.php 27 Jun 2006 18:14:28 -0000 1.22 --- db_install.php 27 Jun 2006 21:38:43 -0000 1.23 *************** *** 296,300 **** // Comments ! "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('use_comments', '1')", // comments_show "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('internal_comments', '1')", // NEW "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('formatting_comment_wordwrap', '1')", // formatting_comment_fixup --- 296,300 ---- // Comments ! "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('use_comments', '0')", // comments_show "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('internal_comments', '1')", // NEW "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('formatting_comment_wordwrap', '1')", // formatting_comment_fixup *************** *** 318,322 **** // Ratings ! "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('use_ratings', '1')", "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('votes_check_userid', '1')", "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('votes_check_ip', '1')", --- 318,322 ---- // Ratings ! "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('use_ratings', '0')", "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('votes_check_userid', '1')", "INSERT INTO " . $mx_table_prefix . "pa_config VALUES ('votes_check_ip', '1')", Index: dload_lists.php =================================================================== RCS file: /cvsroot/mxbb/mx_pafiledb/dload_lists.php,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** dload_lists.php 17 Jun 2006 20:49:26 -0000 1.19 --- dload_lists.php 27 Jun 2006 21:38:43 -0000 1.20 *************** *** 85,89 **** // $pafiledb_block_id = $mx_block->get_parameters( 'target_block' ); ! $pafiledb_page_id = $pafiledb_block_id > 0 ? get_page_id( $pafiledb_block_id ) : get_page_id( 'dload.php', true ); // --- 85,89 ---- // $pafiledb_block_id = $mx_block->get_parameters( 'target_block' ); ! $pafiledb_page_id = intval($pafiledb_block_id) > 0 ? get_page_id( $pafiledb_block_id ) : get_page_id( 'dload.php', true ); // *************** *** 196,201 **** 'UPDATED' => create_date( $board_config['default_dateformat'], $recentrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'VIEW' => $recentrow[$j]['file_dls'], ! 'RATING' => ( $album_config['rate'] == 1 ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'COMMENTS' => ( $album_config['comment'] == 1 ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $recentrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $recentrow[$j]['comments'] . '<br />' ) : '' // 'IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($recentrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($recentrow[$j]['pic_user_ip']) .'</a><br />' : '' )); --- 196,201 ---- 'UPDATED' => create_date( $board_config['default_dateformat'], $recentrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'VIEW' => $recentrow[$j]['file_dls'], ! 'RATING' => ( $pafiledb->ratings[$recentrow[$j]['file_catid']]['activated'] ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'COMMENTS' => ( $pafiledb->comments[$recentrow[$j]['file_catid']]['activated'] ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $recentrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $recentrow[$j]['comments'] . '<br />' ) : '' // 'IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($recentrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($recentrow[$j]['pic_user_ip']) .'</a><br />' : '' )); *************** *** 291,296 **** 'UPDATED' => create_date( $board_config['default_dateformat'], $mostrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'VIEW' => $mostrow[$j]['file_dls'], ! 'RATING' => ( $album_config['rate'] == 1 ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'COMMENTS' => ( $album_config['comment'] == 1 ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $mostrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $mostrow[$j]['comments'] . '<br />' ) : '' // 'IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($recentrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($recentrow[$j]['pic_user_ip']) .'</a><br />' : '' )); --- 291,296 ---- 'UPDATED' => create_date( $board_config['default_dateformat'], $mostrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'VIEW' => $mostrow[$j]['file_dls'], ! 'RATING' => ( $pafiledb->ratings[$mostrow[$j]['file_catid']]['activated'] ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'COMMENTS' => ( $pafiledb->comments[$mostrow[$j]['file_catid']]['activated'] ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $mostrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $mostrow[$j]['comments'] . '<br />' ) : '' // 'IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($recentrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($recentrow[$j]['pic_user_ip']) .'</a><br />' : '' )); *************** *** 387,392 **** 'UPDATED' => create_date( $board_config['default_dateformat'], $highestrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'H_VIEW' => $highestrow[$j]['file_dls'], ! 'H_RATING' => ( $album_config['rate'] == 1 ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'H_COMMENTS' => ( $album_config['comment'] == 1 ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $highestrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $highestrow[$j]['comments'] . '<br />' ) : '' // 'H_IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($highestrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($highestrow[$j]['pic_user_ip']) .'</a><br />' : '' )); --- 387,392 ---- 'UPDATED' => create_date( $board_config['default_dateformat'], $highestrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'H_VIEW' => $highestrow[$j]['file_dls'], ! 'H_RATING' => ( $pafiledb->ratings[$highestrow[$j]['file_catid']]['activated'] ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'H_COMMENTS' => ( $pafiledb->comments[$highestrow[$j]['file_catid']]['activated'] ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $highestrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $highestrow[$j]['comments'] . '<br />' ) : '' // 'H_IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($highestrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($highestrow[$j]['pic_user_ip']) .'</a><br />' : '' )); *************** *** 484,489 **** 'UPDATED' => create_date( $board_config['default_dateformat'], $randrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'VIEW' => $randrow[$j]['file_dls'], ! 'RATING' => ( $album_config['rate'] == 1 ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'COMMENTS' => ( $album_config['comment'] == 1 ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $randrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $randrow[$j]['comments'] . '<br />' ) : '' // 'IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($randrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($randrow[$j]['pic_user_ip']) .'</a><br />' : '' )); --- 484,489 ---- 'UPDATED' => create_date( $board_config['default_dateformat'], $randrow[$j]['file_update_time'], $board_config['board_timezone'] ), 'VIEW' => $randrow[$j]['file_dls'], ! 'RATING' => ( $pafiledb->ratings[$randrow[$j]['file_catid']]['activated'] ) ? ( $lang['Rating'] . ': ' . $rating_image . ', ' ) : '', ! 'COMMENTS' => ( $pafiledb->comments[$randrow[$j]['file_catid']]['activated'] ) ? ( '<a href="' . append_sid( pa_this_mxurl_list( "action=file&file_id=" . $randrow[$j]['file_id'], false, $pafiledb_page_id ) ) . '">' . $lang['Comments'] . '</a>: ' . $randrow[$j]['comments'] . '<br />' ) : '' // 'IP' => ($userdata['user_level'] == ADMIN) ? $lang['IP_Address'] . ': <a href="http://www.nic.com/cgi-bin/whois.cgi?query=' . decode_ip($randrow[$j]['pic_user_ip']) . '" target="_blank">' . decode_ip($randrow[$j]['pic_user_ip']) .'</a><br />' : '' )); Index: db_uninstall.php =================================================================== RCS file: /cvsroot/mxbb/mx_pafiledb/db_uninstall.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** db_uninstall.php 2 May 2006 23:28:15 -0000 1.13 --- db_uninstall.php 27 Jun 2006 21:38:43 -0000 1.14 *************** *** 38,42 **** } ! $sql = array( "DROP TABLE " . $mx_table_prefix . "pa_cat ", "DROP TABLE " . $mx_table_prefix . "pa_auth ", "DROP TABLE " . $mx_table_prefix . "pa_comments ", --- 38,43 ---- } ! $sql = array( ! "DROP TABLE " . $mx_table_prefix . "pa_cat ", "DROP TABLE " . $mx_table_prefix . "pa_auth ", "DROP TABLE " . $mx_table_prefix . "pa_comments ", Index: dload.php =================================================================== RCS file: /cvsroot/mxbb/mx_pafiledb/dload.php,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** dload.php 17 Jun 2006 20:49:26 -0000 1.21 --- dload.php 27 Jun 2006 21:38:43 -0000 1.22 *************** *** 99,102 **** --- 99,103 ---- // =================================================== include_once( $module_root_path . 'pafiledb/pafiledb_common.' . $phpEx ); + $pafiledb_template->destroy(); // =================================================== Index: dload_quickdl.php =================================================================== RCS file: /cvsroot/mxbb/mx_pafiledb/dload_quickdl.php,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** dload_quickdl.php 17 Jun 2006 20:49:26 -0000 1.11 --- dload_quickdl.php 27 Jun 2006 21:38:43 -0000 1.12 *************** *** 71,79 **** // =================================================== include_once( $module_root_path . 'pafiledb/pafiledb_common.' . $phpEx ); // =================================================== // Get action variable other wise set it to the main // =================================================== ! $action = ( isset( $_REQUEST['action'] ) ) ? htmlspecialchars( $_REQUEST['action'] ) : 'quickdl'; // =================================================== --- 71,80 ---- // =================================================== include_once( $module_root_path . 'pafiledb/pafiledb_common.' . $phpEx ); + $pafiledb_template->destroy(); // =================================================== // Get action variable other wise set it to the main // =================================================== ! $action = ( isset( $_REQUEST['actionqdl'] ) ) ? htmlspecialchars( $_REQUEST['actionqdl'] ) : 'quickdl'; // =================================================== |