PunBB 1.1 to 1.1.5 Changes Legend
Lines removed 
Lines changed
 Lines added

punbb-1.1/upload/admin_bans.php punbb-1.1.5/upload/admin_bans.php
 54:         } 54:         }
 55:         else    // Otherwise the username is in POST 55:         else    // Otherwise the username is in POST
 56:         { 56:         {
 57:             $ban_user = trim(strtolower($_POST['new_ban_user'])); 57:             $ban_user = trim($_POST['new_ban_user']);
 58:      58:     
 59:             if ($ban_user != '') 59:             if ($ban_user != '')
 60:             { 60:             {
121:             <td class="puncon2">121:             <td class="puncon2">
122:                 <table class="punplain" cellpadding="6">122:                 <table class="punplain" cellpadding="6">
123:                     <tr>123:                     <tr>
124:                         <td class="punright" style="width: 35%"><b>Username</b><br>The username to ban (case insensitive).</td>124:                         <td class="punright" style="width: 35%"><b>Username</b><br>The username to ban.</td>
125:                         <td style="width: 35%"><input type="text" name="ban_user" size="25" maxlength="25" value="<?php echo $ban_user ?>" tabindex="1"></td>125:                         <td style="width: 35%"><input type="text" name="ban_user" size="25" maxlength="25" value="<?php echo pun_htmlspecialchars($ban_user) ?>" tabindex="1"></td>
126:                     </tr>126:                     </tr>
127:                     <tr>127:                     <tr>
128:                         <td class="punright" style="width: 35%"><b>IP-adresses</b><br>The IP or IP-ranges you wish to ban (e.g. 150.11.110.1 or 150.11.110). Separate addresses with spaces. If an IP is entered already it is the last known IP of this user in the database.<?php if ($ban_user != '') echo ' Click <a href="admin_users.php?ip_stats='.$user_id.'">here</a> to see IP statistics for this user.' ?></td>128:                         <td class="punright" style="width: 35%"><b>IP-adresses</b><br>The IP or IP-ranges you wish to ban (e.g. 150.11.110.1 or 150.11.110). Separate addresses with spaces. If an IP is entered already it is the last known IP of this user in the database.<?php if ($ban_user != '') echo ' Click <a href="admin_users.php?ip_stats='.$user_id.'">here</a> to see IP statistics for this user.' ?></td>


punbb-1.1/upload/admin_index.php punbb-1.1.5/upload/admin_index.php
 67:  67: 
 68:  68: 
 69: // Get the server load averages (if possible) 69: // Get the server load averages (if possible)
 70: if (file_exists('/proc/loadavg')) 70: if (@file_exists('/proc/loadavg'))
 71: { 71: {
 72:     // We use @ just in case 72:     // We use @ just in case
 73:     $fh = @fopen('/proc/loadavg', 'r'); 73:     $fh = @fopen('/proc/loadavg', 'r');
 81:     $server_load = $load_averages[1].' '.$load_averages[2].' '.$load_averages[3]; 81:     $server_load = $load_averages[1].' '.$load_averages[2].' '.$load_averages[3];
 82: else 82: else
 83:     $server_load = 'Not available'; 83:     $server_load = 'Not available';
 84:      84: 
 85:  85: 
 86: // Get number of current visitors 86: // Get number of current visitors
 87: $result = $db->query('SELECT COUNT(user_id) FROM '.$db->prefix.'online') or error('Unable to fetch online count', __FILE__, __LINE__, $db->error()); 87: $result = $db->query('SELECT COUNT(user_id) FROM '.$db->prefix.'online') or error('Unable to fetch online count', __FILE__, __LINE__, $db->error());


punbb-1.1/upload/admin_maintenance.php punbb-1.1.5/upload/admin_maintenance.php
 42:     if (empty($per_page) || empty($start_at)) 42:     if (empty($per_page) || empty($start_at))
 43:         message($lang_common['Bad request']); 43:         message($lang_common['Bad request']);
 44:  44: 
  45:     @set_time_limit(0);
  46: 
 45:     // If this is the first cycle of posts we empty the search index before we proceed 47:     // If this is the first cycle of posts we empty the search index before we proceed
 46:     if (isset($_GET['empty_index'])) 48:     if (isset($_GET['empty_index']))
 47:     { 49:     {
115: else117: else
116: {118: {
117:     // Get the first post ID from the db119:     // Get the first post ID from the db
118:     $result = $db->query('SELECT id FROM '.$db->prefix.'topics ORDER BY id LIMIT 1') or error('Unable to create category', __FILE__, __LINE__, $db->error());120:     $result = $db->query('SELECT id FROM '.$db->prefix.'topics ORDER BY id LIMIT 1') or error('Unable to fetch topic info', __FILE__, __LINE__, $db->error());
119:     if ($db->num_rows($result))121:     if ($db->num_rows($result))
120:         $first_id = $db->result($result, 0);122:         $first_id = $db->result($result, 0);
121: 123: 


punbb-1.1/upload/admin_options.php punbb-1.1.5/upload/admin_options.php
 94:             $form['maintenance'] = '0'; 94:             $form['maintenance'] = '0';
 95:     } 95:     }
 96:  96: 
  97:     $form['timeout_visit'] = intval($form['timeout_visit']);
  98:     $form['timeout_online'] = intval($form['timeout_online']);
  99:     $form['redirect_delay'] = intval($form['redirect_delay']);
 100:     $form['flood_interval'] = intval($form['flood_interval']);
 101:     $form['topic_review'] = intval($form['topic_review']);
 102:     $form['disp_topics_default'] = intval($form['disp_topics_default']);
 103:     $form['disp_posts_default'] = intval($form['disp_posts_default']);
 104:     $form['indent_num_spaces'] = intval($form['indent_num_spaces']);
 105:     $form['avatars_width'] = intval($form['avatars_width']);
 106:     $form['avatars_height'] = intval($form['avatars_height']);
 107:     $form['avatars_size'] = intval($form['avatars_size']);
 97: 108: 
 98:     while (list($key, $input) = @each($form))109:     while (list($key, $input) = @each($form))
 99:     {110:     {
100:         // Only update values that have changed111:         // Only update values that have changed
101:         if ($pun_config['o_'.$key] != $input)112:         if ($pun_config['o_'.$key] != $input)
102:         {113:         {
103:             if ($input != '')114:             if ($input != '' || is_int($input))
104:                 $value = '\''.escape($input).'\'';115:                 $value = '\''.escape($input).'\'';
105:             else116:             else
106:                 $value = 'NULL';117:                 $value = 'NULL';
392:                     </tr>403:                     </tr>
393:                     <tr>404:                     <tr>
394:                         <td class="punright" style="width: 35%"><b>SMTP username</b><br>Username for SMTP server. Only enter a username if it is required by the SMTP server (most servers <b>don't</b> require authentication).</td>405:                         <td class="punright" style="width: 35%"><b>SMTP username</b><br>Username for SMTP server. Only enter a username if it is required by the SMTP server (most servers <b>don't</b> require authentication).</td>
395:                         <td style="width: 65%"><input type="text" name="form[smtp_user]" size="25" maxlength="25" value="<?php echo $pun_config['o_smtp_user'] ?>"></td>406:                         <td style="width: 65%"><input type="text" name="form[smtp_user]" size="25" maxlength="50" value="<?php echo $pun_config['o_smtp_user'] ?>"></td>
396:                     </tr>407:                     </tr>
397:                     <tr>408:                     <tr>
398:                         <td class="punright" style="width: 35%"><b>SMTP password</b><br>Password for SMTP server. Only enter a password if it is required by the SMTP server (most servers <b>don't</b> require authentication).</td>409:                         <td class="punright" style="width: 35%"><b>SMTP password</b><br>Password for SMTP server. Only enter a password if it is required by the SMTP server (most servers <b>don't</b> require authentication).</td>
399:                         <td style="width: 65%"><input type="text" name="form[smtp_pass]" size="25" maxlength="25" value="<?php echo $pun_config['o_smtp_pass'] ?>"></td>410:                         <td style="width: 65%"><input type="text" name="form[smtp_pass]" size="25" maxlength="50" value="<?php echo $pun_config['o_smtp_pass'] ?>"></td>
400:                     </tr>411:                     </tr>
401:                 </table>412:                 </table>
402:             </td>413:             </td>


punbb-1.1/upload/admin_permissions.php punbb-1.1.5/upload/admin_permissions.php
 38:  38: 
 39:     $form = array_map('trim', $_POST['form']); 39:     $form = array_map('trim', $_POST['form']);
 40:  40: 
  41:     $form['sig_length'] = intval($form['sig_length']);
  42:     $form['sig_lines'] = intval($form['sig_lines']);
  43: 
 41:     while (list($key, $input) = @each($form)) 44:     while (list($key, $input) = @each($form))
 42:     { 45:     {
 43:         // Only update values that have changed 46:         // Only update values that have changed
 44:         if ($pun_config['p_'.$key] != $input) 47:         if ($pun_config['p_'.$key] != $input)
 45:         { 48:         {
 46:             if ($input != '') 49:             if ($input != '' || is_int($input))
 47:                 $value = '\''.escape($input).'\''; 50:                 $value = '\''.escape($input).'\'';
 48:             else 51:             else
 49:                 $value = 'NULL'; 52:                 $value = 'NULL';


punbb-1.1/upload/admin_prune.php punbb-1.1.5/upload/admin_prune.php
 87:         $prune_from = $_POST['prune_from']; 87:         $prune_from = $_POST['prune_from'];
 88:  88: 
 89:         // Concatenate together the query for counting number or topics to prune 89:         // Concatenate together the query for counting number or topics to prune
 90:         $sql = 'SELECT COUNT(id) FROM '.$db->prefix.'topics WHERE last_post<'.$prune_date; 90:         $sql = 'SELECT COUNT(id) FROM '.$db->prefix.'topics WHERE last_post<'.$prune_date.' AND moved_to IS NULL';
 91:  91: 
 92:         if ($_POST['prune_sticky'] == '0') 92:         if ($_POST['prune_sticky'] == '0')
 93:             $sql .= ' AND sticky=\'0\''; 93:             $sql .= ' AND sticky=\'0\'';
 98:  98: 
 99:             // Fetch the forum name (just for cosmetic reasons) 99:             // Fetch the forum name (just for cosmetic reasons)
100:             $result = $db->query('SELECT forum_name FROM '.$db->prefix.'forums WHERE id='.$prune_from) or error('Unable to fetch forum name', __FILE__, __LINE__, $db->error());100:             $result = $db->query('SELECT forum_name FROM '.$db->prefix.'forums WHERE id='.$prune_from) or error('Unable to fetch forum name', __FILE__, __LINE__, $db->error());
101:             $forum = '"'.$db->result($result, 0).'"';101:             $forum = '"'.pun_htmlspecialchars($db->result($result, 0)).'"';
102:         }102:         }
103:         else103:         else
104:             $forum = 'all forums';104:             $forum = 'all forums';


punbb-1.1/upload/admin_users.php punbb-1.1.5/upload/admin_users.php
362:                     <tr>362:                     <tr>
363:                         <td class="punright" style="width: 35%">Username</td>363:                         <td class="punright" style="width: 35%">Username</td>
364:                         <td style="width: 35%"><input type="text" name="username" size="25" maxlength="25" tabindex="1"></td>364:                         <td style="width: 35%"><input type="text" name="username" size="25" maxlength="25" tabindex="1"></td>
365:                         <td style="width: 30%" rowspan="16"><input type="submit" name="find_user" value=" Find " tabindex="21"></td>365:                         <td style="width: 30%" rowspan="16"><input type="submit" name="find_user" value=" Find " tabindex="22"></td>
366:                     </tr>366:                     </tr>
367:                     <tr>367:                     <tr>
368:                         <td class="punright" style="width: 35%">E-mail address</td>368:                         <td class="punright" style="width: 35%">E-mail address</td>
385:                         <td style="width: 35%"><input type="text" name="form[icq]" size="12" maxlength="12" tabindex="6"></td>385:                         <td style="width: 35%"><input type="text" name="form[icq]" size="12" maxlength="12" tabindex="6"></td>
386:                     </tr>386:                     </tr>
387:                     <tr>387:                     <tr>
 388:                         <td class="punright" style="width: 35%">MSN Messenger</td>
 389:                         <td style="width: 35%"><input type="text" name="form[msn]" size="30" maxlength="50" tabindex="7"></td>
 390:                     </tr>
 391:                     <tr>
388:                         <td class="punright" style="width: 35%">AOL IM</td>392:                         <td class="punright" style="width: 35%">AOL IM</td>
389:                         <td style="width: 35%"><input type="text" name="form[aim]" size="20" maxlength="20" tabindex="7"></td>393:                         <td style="width: 35%"><input type="text" name="form[aim]" size="20" maxlength="20" tabindex="8"></td>
390:                     </tr>394:                     </tr>
391:                     <tr>395:                     <tr>
392:                         <td class="punright" style="width: 35%">Yahoo! Messenger</td>396:                         <td class="punright" style="width: 35%">Yahoo! Messenger</td>
393:                         <td style="width: 35%"><input type="text" name="form[yahoo]" size="20" maxlength="20" tabindex="8"></td>397:                         <td style="width: 35%"><input type="text" name="form[yahoo]" size="20" maxlength="20" tabindex="9"></td>
394:                     </tr>398:                     </tr>
395:                     <tr>399:                     <tr>
396:                         <td class="punright" style="width: 35%">Location</td>400:                         <td class="punright" style="width: 35%">Location</td>
397:                         <td style="width: 35%"><input type="text" name="form[location]" size="30" maxlength="30" tabindex="9"></td>401:                         <td style="width: 35%"><input type="text" name="form[location]" size="30" maxlength="30" tabindex="10"></td>
398:                     </tr>402:                     </tr>
399:                     <tr>403:                     <tr>
400:                         <td class="punright" style="width: 35%">Signature</td>404:                         <td class="punright" style="width: 35%">Signature</td>
401:                         <td style="width: 35%"><input type="text" name="form[signature]" size="35" maxlength="512" tabindex="10"></td>405:                         <td style="width: 35%"><input type="text" name="form[signature]" size="35" maxlength="512" tabindex="11"></td>
402:                     </tr>406:                     </tr>
403:                     <tr>407:                     <tr>
404:                         <td class="punright" style="width: 35%">Admin note</td>408:                         <td class="punright" style="width: 35%">Admin note</td>
405:                         <td style="width: 35%"><input type="text" name="form[admin_note]" size="30" maxlength="30" tabindex="11"></td>409:                         <td style="width: 35%"><input type="text" name="form[admin_note]" size="30" maxlength="30" tabindex="12"></td>
406:                     </tr>410:                     </tr>
407:                     <tr>411:                     <tr>
408:                         <td class="punright" style="width: 35%">Number of posts greater than</td>412:                         <td class="punright" style="width: 35%">Number of posts greater than</td>
409:                         <td style="width: 35%"><input type="text" name="posts_greater" size="5" maxlength="8" tabindex="12"></td>413:                         <td style="width: 35%"><input type="text" name="posts_greater" size="5" maxlength="8" tabindex="13"></td>
410:                     </tr>414:                     </tr>
411:                     <tr>415:                     <tr>
412:                         <td class="punright" style="width: 35%">Number of posts less than</td>416:                         <td class="punright" style="width: 35%">Number of posts less than</td>
413:                         <td style="width: 35%"><input type="text" name="posts_less" size="5" maxlength="8" tabindex="13"></td>417:                         <td style="width: 35%"><input type="text" name="posts_less" size="5" maxlength="8" tabindex="14"></td>
414:                     </tr>418:                     </tr>
415:                     <tr>419:                     <tr>
416:                         <td class="punright" style="width: 35%">Last post is after<br>(yyyy-mm-dd hh:mm:ss)</td>420:                         <td class="punright" style="width: 35%">Last post is after<br>(yyyy-mm-dd hh:mm:ss)</td>
417:                         <td style="width: 35%"><input type="text" name="last_post_after" size="24" maxlength="19" tabindex="14"></td>421:                         <td style="width: 35%"><input type="text" name="last_post_after" size="24" maxlength="19" tabindex="15"></td>
418:                     </tr>422:                     </tr>
419:                     <tr>423:                     <tr>
420:                         <td class="punright" style="width: 35%">Last post is before<br>(yyyy-mm-dd hh:mm:ss)</td>424:                         <td class="punright" style="width: 35%">Last post is before<br>(yyyy-mm-dd hh:mm:ss)</td>
421:                         <td style="width: 35%"><input type="text" name="last_post_before" size="24" maxlength="19" tabindex="15"></td>425:                         <td style="width: 35%"><input type="text" name="last_post_before" size="24" maxlength="19" tabindex="16"></td>
422:                     </tr>426:                     </tr>
423:                     <tr>427:                     <tr>
424:                         <td class="punright" style="width: 35%">Registered after<br>(yyyy-mm-dd hh:mm:ss)</td>428:                         <td class="punright" style="width: 35%">Registered after<br>(yyyy-mm-dd hh:mm:ss)</td>
425:                         <td style="width: 35%"><input type="text" name="registered_after" size="24" maxlength="19" tabindex="16"></td>429:                         <td style="width: 35%"><input type="text" name="registered_after" size="24" maxlength="19" tabindex="17"></td>
426:                     </tr>430:                     </tr>
427:                     <tr>431:                     <tr>
428:                         <td class="punright" style="width: 35%">Registered before<br>(yyyy-mm-dd hh:mm:ss)</td>432:                         <td class="punright" style="width: 35%">Registered before<br>(yyyy-mm-dd hh:mm:ss)</td>
429:                         <td style="width: 35%"><input type="text" name="registered_before" size="24" maxlength="19" tabindex="17"></td>433:                         <td style="width: 35%"><input type="text" name="registered_before" size="24" maxlength="19" tabindex="18"></td>
430:                     </tr>434:                     </tr>
431:                     <tr>435:                     <tr>
432:                         <td class="punright" style="width: 35%">Order by</td>436:                         <td class="punright" style="width: 35%">Order by</td>
433:                         <td style="width: 35%">437:                         <td style="width: 35%">
434:                             <select name="order_by" tabindex="18">438:                             <select name="order_by" tabindex="19">
435:                                 <option value="username" selected>username</option>439:                                 <option value="username" selected>username</option>
436:                                 <option value="email">e-mail</option>440:                                 <option value="email">e-mail</option>
437:                                 <option value="num_posts">posts</option>441:                                 <option value="num_posts">posts</option>
438:                                 <option value="last_post">last post</option>442:                                 <option value="last_post">last post</option>
439:                                 <option value="registered">registered</option>443:                                 <option value="registered">registered</option>
440:                             </select>&nbsp;&nbsp;&nbsp;<select name="direction" tabindex="19">444:                             </select>&nbsp;&nbsp;&nbsp;<select name="direction" tabindex="20">
441:                                 <option value="ASC" selected>ascending</option>445:                                 <option value="ASC" selected>ascending</option>
442:                                 <option value="DESC">descending</option>446:                                 <option value="DESC">descending</option>
443:                             </select>447:                             </select>
446:                     <tr>450:                     <tr>
447:                         <td class="punright" style="width: 35%">User group</td>451:                         <td class="punright" style="width: 35%">User group</td>
448:                         <td style="width: 35%">452:                         <td style="width: 35%">
449:                             <select name="user_group" tabindex="20">453:                             <select name="user_group" tabindex="21">
450:                                 <option value="all" selected>All groups</option>454:                                 <option value="all" selected>All groups</option>
451:                                 <option value="<?php echo PUN_USER ?>">Users</option>455:                                 <option value="<?php echo PUN_USER ?>">Users</option>
452:                                 <option value="<?php echo PUN_MOD ?>">Moderators</option>456:                                 <option value="<?php echo PUN_MOD ?>">Moderators</option>
474:                 <table class="punplain" cellspacing="0" cellpadding="4">478:                 <table class="punplain" cellspacing="0" cellpadding="4">
475:                     <tr>479:                     <tr>
476:                         <td class="punright" style="width: 35%"><b>IP address</b><br>The IP address to search for in the post database.</td>480:                         <td class="punright" style="width: 35%"><b>IP address</b><br>The IP address to search for in the post database.</td>
477:                         <td style="width: 35%"><input type="text" name="show_users" size="18" maxlength="15" tabindex="22"></td>481:                         <td style="width: 35%"><input type="text" name="show_users" size="18" maxlength="15" tabindex="23"></td>
478:                         <td style="width: 30%"><input type="submit" value=" Find " tabindex="23"></td>482:                         <td style="width: 30%"><input type="submit" value=" Find " tabindex="24"></td>
479:                     </tr>483:                     </tr>
480:                 </table>484:                 </table>
481:             </td>485:             </td>


punbb-1.1/upload/edit.php punbb-1.1.5/upload/edit.php
124: 124: 
125:     if ($smilies != '1') $smilies = '0';125:     if ($smilies != '1') $smilies = '0';
126: 126: 
127:     if (!isset($_POST['silent']) || !$is_admmod)127:     $edited_sql = (!isset($_POST['silent']) || !$is_admmod) ? $edited_sql = ', edited='.time().', edited_by=\''.addslashes($cur_user['username']).'\'' : '';
128:         $edited_sql = ', edited='.time().', edited_by=\''.addslashes($cur_user['username']).'\''; 
129: 128: 
130:     if ($is_topicpost && $is_admmod)129:     if ($is_topicpost && $is_admmod)
131:     {130:     {


punbb-1.1/upload/footer.php punbb-1.1.5/upload/footer.php
 72:                             <select name="id" onchange="window.location=('viewforum.php?id='+this.options[this.selectedIndex].value)"> 72:                             <select name="id" onchange="window.location=('viewforum.php?id='+this.options[this.selectedIndex].value)">
 73: <?php 73: <?php
 74:  74: 
 75:     if ($cur_user['status'] < PUN_MOD) 75:     $extra_sql = ($cur_user['status'] < PUN_MOD) ? ' WHERE f.admmod_only=\'0\'' : '';
 76:         $extra = ' WHERE f.admmod_only=\'0\''; 
 77:  76: 
 78:     $result = $db->query('SELECT c.id AS cid, c.cat_name, f.id AS fid, f.forum_name FROM '.$db->prefix.'categories AS c INNER JOIN '.$db->prefix.'forums AS f ON c.id=f.cat_id'.$extra.' ORDER BY c.disp_position, c.id, f.disp_position') or error('Unable to fetch category/forum list', __FILE__, __LINE__, $db->error()); 77:     $result = $db->query('SELECT c.id AS cid, c.cat_name, f.id AS fid, f.forum_name FROM '.$db->prefix.'categories AS c INNER JOIN '.$db->prefix.'forums AS f ON c.id=f.cat_id'.$extra_sql.' ORDER BY c.disp_position, c.id, f.disp_position') or error('Unable to fetch category/forum list', __FILE__, __LINE__, $db->error());
 79:  78: 
 80:     while ($cur_forum = $db->fetch_assoc($result)) 79:     while ($cur_forum = $db->fetch_assoc($result))
 81:     { 80:     {
108:     else if ($footer_style == 'topic' && $is_admmod)107:     else if ($footer_style == 'topic' && $is_admmod)
109:     {108:     {
110:         echo "\t\t\t\t\t\t".'<br><a href="moderate.php?fid='.$forum_id.'&amp;tid='.$id.'&amp;p='.$p.'">'.$lang_common['Delete posts'].'</a><br>'."\n";109:         echo "\t\t\t\t\t\t".'<br><a href="moderate.php?fid='.$forum_id.'&amp;tid='.$id.'&amp;p='.$p.'">'.$lang_common['Delete posts'].'</a><br>'."\n";
111:         echo "\t\t\t\t\t\t".'<a href="moderate.php?fid='.$forum_id.'&amp;move='.$id.'">'.$lang_common['Move topic'].'</a><br>'."\n";110:         echo "\t\t\t\t\t\t".'<a href="moderate.php?fid='.$forum_id.'&amp;move_topics='.$id.'">'.$lang_common['Move topic'].'</a><br>'."\n";
112: 111: 
113:         if ($closed == '1')112:         if ($closed == '1')
114:             echo "\t\t\t\t\t\t".'<a href="moderate.php?fid='.$forum_id.'&amp;open='.$id.'">'.$lang_common['Open topic'].'</a><br>'."\n";113:             echo "\t\t\t\t\t\t".'<a href="moderate.php?fid='.$forum_id.'&amp;open='.$id.'">'.$lang_common['Open topic'].'</a><br>'."\n";


punbb-1.1/upload/header.php punbb-1.1.5/upload/header.php
 23: ************************************************************************/ 23: ************************************************************************/
 24:  24: 
 25:  25: 
  26: // Make sure no one attempts to run this script "directly"
  27: if (!defined('PUN'))
  28:     exit;
  29: 
 26: // Send no-cache headers 30: // Send no-cache headers
 27: header('Cache-Control: no-store, no-cache, must-revalidate'); 31: //header('Cache-Control: no-store, no-cache, must-revalidate');
 28: header('Cache-Control: post-check=0, pre-check=0', false); 32: header('Cache-Control: post-check=0, pre-check=0', false);
 29: header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); 33: header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
 30: header('Expires: Thu, 21 Jul 1977 07:30:00 GMT');    // When yours truly first set eyes on this world! :) 34: header('Expires: Thu, 21 Jul 1977 07:30:00 GMT');    // When yours truly first set eyes on this world! :)


punbb-1.1/upload/help.php punbb-1.1.5/upload/help.php
 93:                 <?php echo $lang_help['Quotes info'] ?><br><br> 93:                 <?php echo $lang_help['Quotes info'] ?><br><br>
 94:                 &nbsp;&nbsp;&nbsp;&nbsp;[quote=James]<?php echo $lang_help['Quote text'] ?>[/quote]<br><br> 94:                 &nbsp;&nbsp;&nbsp;&nbsp;[quote=James]<?php echo $lang_help['Quote text'] ?>[/quote]<br><br>
 95:                 <?php echo $lang_help['produces quote box'] ?><br><br> 95:                 <?php echo $lang_help['produces quote box'] ?><br><br>
 96:                 <table style="width: 95%" align="center" cellspacing="4" cellpadding="6"><tr><td class="punquote"><span class="puntext"><b>James <?php echo $lang_common['wrote'] ?>:</b><br><br>Text</span></td></tr></table><br> 96:                 <table style="width: 95%" align="center" cellspacing="4" cellpadding="6"><tr><td class="punquote"><span class="puntext"><b>James <?php echo $lang_common['wrote'] ?>:</b><br><br><?php echo $lang_help['Quote text'] ?></span></td></tr></table><br>
 97:                 <?php echo $lang_help['Quotes info 2'] ?><br><br> 97:                 <?php echo $lang_help['Quotes info 2'] ?><br><br>
 98:                 &nbsp;&nbsp;&nbsp;&nbsp;[quote]<?php echo $lang_help['Quote text'] ?>[/quote]<br><br> 98:                 &nbsp;&nbsp;&nbsp;&nbsp;[quote]<?php echo $lang_help['Quote text'] ?>[/quote]<br><br>
 99:                 <?php echo $lang_help['produces quote box'] ?><br><br> 99:                 <?php echo $lang_help['produces quote box'] ?><br><br>


punbb-1.1/upload/include/common.php punbb-1.1.5/upload/include/common.php
 31: //define('PUN_SHOW_QUERIES', 1); 31: //define('PUN_SHOW_QUERIES', 1);
 32:  32: 
 33:  33: 
 34: @include $pun_root.'config.php'; 34: if (is_dir($pun_root)) @include $pun_root.'config.php';
 35:  35: 
 36: // If PUN isn't defined, config.php is missing or corrupt 36: // If PUN isn't defined, config.php is missing or corrupt
 37: if (!defined('PUN')) 37: if (!defined('PUN'))
 48: // Turn off magic_quotes_runtime 48: // Turn off magic_quotes_runtime
 49: set_magic_quotes_runtime(0); 49: set_magic_quotes_runtime(0);
 50:  50: 
 51: // Attempt to turn off register_globals (this really isn't needed, but we'll do it anyway) 
 52: @ini_set('register_globals', 0); 
 53:  
 54: // Seed the random number generator 51: // Seed the random number generator
 55: mt_srand((double)microtime()*1000000); 52: mt_srand((double)microtime()*1000000);
 56:  53: 


punbb-1.1/upload/include/common_admin.php punbb-1.1.5/upload/include/common_admin.php
 82: // 82: //
 83: function prune($forum_id, $prune_sticky, $prune_date) 83: function prune($forum_id, $prune_sticky, $prune_date)
 84: { 84: {
 85:     global $db; 85:     global $pun_root, $db;
 86:  86: 
 87:     if ($prune_date != -1) 87:     $extra_sql = ($prune_date != -1) ? ' AND last_post<'.$prune_date : '';
 88:         $extra = ' AND last_post<'.$prune_date; 
 89:  88: 
 90:     if (!$prune_sticky) 89:     if (!$prune_sticky)
 91:         $extra .= ' AND sticky=\'0\''; 90:         $extra_sql .= ' AND sticky=\'0\''; 
 92:  91: 
 93:     // Fetch topics to prune 92:     // Fetch topics to prune
 94:     $result = $db->query('SELECT id FROM '.$db->prefix.'topics WHERE forum_id='.$forum_id.$extra) or error('Unable to fetch topics', __FILE__, __LINE__, $db->error()); 93:     $result = $db->query('SELECT id FROM '.$db->prefix.'topics WHERE forum_id='.$forum_id.$extra_sql) or error('Unable to fetch topics', __FILE__, __LINE__, $db->error());
 95:  94: 
 96:     while ($row = $db->fetch_row($result)) 95:     while ($row = $db->fetch_row($result))
 97:         $topic_ids .= (($topic_ids != '') ? ',' : '').$row[0]; 96:         $topic_ids .= (($topic_ids != '') ? ',' : '').$row[0];
112:             $db->query('DELETE FROM '.$db->prefix.'posts WHERE id IN('.$post_ids.')') or error('Unable to prune posts', __FILE__, __LINE__, $db->error());111:             $db->query('DELETE FROM '.$db->prefix.'posts WHERE id IN('.$post_ids.')') or error('Unable to prune posts', __FILE__, __LINE__, $db->error());
113: 112: 
114:             // We removed a bunch of posts, so now we have to update the search index113:             // We removed a bunch of posts, so now we have to update the search index
115:             require $pun_root.'include/search_idx.php';114:             require_once $pun_root.'include/search_idx.php';
116:             strip_search_index($post_ids);115:             strip_search_index($post_ids);
117:         }116:         }
118:     }117:     }


punbb-1.1/upload/include/dblayer/pgsql.php punbb-1.1.5/upload/include/dblayer/pgsql.php
 23: ************************************************************************/ 23: ************************************************************************/
 24:  24: 
 25:  25: 
 26: // Make sure we have built in support for MySQL 26: // Make sure we have built in support for PostgreSQL
 27: if (!function_exists('pg_connect')) 27: if (!function_exists('pg_connect'))
 28:     exit('This PHP environment doesn\'t have PostgreSQL support built in. PostgreSQL support is required if you want to use a PostgreSQL database to run this forum. Consult the PHP documentation for further assistance.'); 28:     exit('This PHP environment doesn\'t have PostgreSQL support built in. PostgreSQL support is required if you want to use a PostgreSQL database to run this forum. Consult the PHP documentation for further assistance.');
 29:  29: 
111:                 if (defined('PUN_SHOW_QUERIES'))111:                 if (defined('PUN_SHOW_QUERIES'))
112:                     $this->saved_queries[] = array('BEGIN', 0);112:                     $this->saved_queries[] = array('BEGIN', 0);
113: 113: 
114:                 if (!@pg_exec($this->link_id, 'BEGIN'))114:                 if (!@pg_query($this->link_id, 'BEGIN'))
115:                     return false;115:                     return false;
116:             }116:             }
117: 117: 
118:             if (defined('PUN_SHOW_QUERIES'))118:             if (defined('PUN_SHOW_QUERIES'))
119:                 $q_start = get_microtime();119:                 $q_start = get_microtime();
120: 120: 
121:             $this->query_result = @pg_exec($this->link_id, $sql);121:             $this->query_result = @pg_query($this->link_id, $sql);
122:             if ($this->query_result)122:             if ($this->query_result)
123:             {123:             {
124:                 if (defined('PUN_SHOW_QUERIES'))124:                 if (defined('PUN_SHOW_QUERIES'))
131:                     if (defined('PUN_SHOW_QUERIES'))131:                     if (defined('PUN_SHOW_QUERIES'))
132:                         $this->saved_queries[] = array('COMMIT', 0);132:                         $this->saved_queries[] = array('COMMIT', 0);
133: 133: 
134:                     if (!@pg_exec($this->link_id, 'COMMIT'))134:                     if (!@pg_query($this->link_id, 'COMMIT'))
135:                     {135:                     {
136:                         if (defined('PUN_SHOW_QUERIES'))136:                         if (defined('PUN_SHOW_QUERIES'))
137:                             $this->saved_queries[] = array('ROLLBACK', 0);137:                             $this->saved_queries[] = array('ROLLBACK', 0);
138: 138: 
139:                         @pg_exec($this->link_id, 'ROLLBACK');139:                         @pg_query($this->link_id, 'ROLLBACK');
140:                         return false;140:                         return false;
141:                     }141:                     }
142:                 }142:                 }
154:                     $this->saved_queries[] = array('ROLLBACK', 0);154:                     $this->saved_queries[] = array('ROLLBACK', 0);
155: 155: 
156:                 if ($this->in_transaction)156:                 if ($this->in_transaction)
157:                     @pg_exec($this->link_id, 'ROLLBACK');157:                     @pg_query($this->link_id, 'ROLLBACK');
158: 158: 
159:                 $this->in_transaction = false;159:                 $this->in_transaction = false;
160: 160: 
170:                 if (defined('PUN_SHOW_QUERIES'))170:                 if (defined('PUN_SHOW_QUERIES'))
171:                     $this->saved_queries[] = array('COMMIT', 0);171:                     $this->saved_queries[] = array('COMMIT', 0);
172: 172: 
173:                 if (!@pg_exec($this->link_id, 'COMMIT'))173:                 if (!@pg_query($this->link_id, 'COMMIT'))
174:                 {174:                 {
175:                     if (defined('PUN_SHOW_QUERIES'))175:                     if (defined('PUN_SHOW_QUERIES'))
176:                         $this->saved_queries[] = array('ROLLBACK', 0);176:                         $this->saved_queries[] = array('ROLLBACK', 0);
177: 177: 
178:                     @pg_exec($this->link_id, 'ROLLBACK');178:                     @pg_query($this->link_id, 'ROLLBACK');
179:                     return false;179:                     return false;
180:                 }180:                 }
181:             }181:             }
260:     function num_rows($query_id = 0)260:     function num_rows($query_id = 0)
261:     {261:     {
262:         if (!$query_id)262:         if (!$query_id)
263:         { 
264:             $query_id = $this->query_result;263:             $query_id = $this->query_result;
265:         } 
266: 264: 
267:         return ($query_id) ? @pg_num_rows($query_id) : false;265:         return ($query_id) ? @pg_num_rows($query_id) : false;
268:     }266:     }
286:             if (preg_match('/^INSERT[\t\n ]+INTO[\t\n ]+([a-z0-9\_\-]+)/is', $this->last_query_text[$query_id], $tablename))284:             if (preg_match('/^INSERT[\t\n ]+INTO[\t\n ]+([a-z0-9\_\-]+)/is', $this->last_query_text[$query_id], $tablename))
287:             {285:             {
288:                 $sql = 'SELECT currval(\''.$tablename[1].'_id_seq\') AS lastval';286:                 $sql = 'SELECT currval(\''.$tablename[1].'_id_seq\') AS lastval';
289:                 $temp_q_id = @pg_exec($this->link_id, $sql);287:                 $temp_q_id = @pg_query($this->link_id, $sql);
290: 288: 
291:                 if (!$temp_q_id)289:                 if (!$temp_q_id)
292:                     return false;290:                     return false;
318:         if (!$query_id)316:         if (!$query_id)
319:             $query_id = $this->query_result;317:             $query_id = $this->query_result;
320: 318: 
321:         return ($query_id) ? @pg_freeresult($query_id) : false;319:         return ($query_id) ? @pg_free_result($query_id) : false;
322:     }320:     }
323: 321: 
324: 322: 
343:                 if (defined('PUN_SHOW_QUERIES'))341:                 if (defined('PUN_SHOW_QUERIES'))
344:                     $this->saved_queries[] = array('COMMIT', 0);342:                     $this->saved_queries[] = array('COMMIT', 0);
345: 343: 
346:                 @pg_exec($this->link_id, 'COMMIT');344:                 @pg_query($this->link_id, 'COMMIT');
347:             }345:             }
348: 346: 
349:             if ($this->query_result)347:             if ($this->query_result)
350:                 @pg_freeresult($this->query_result);348:                 @pg_free_result($this->query_result);
351: 349: 
352:             return @pg_close($this->link_id);350:             return @pg_close($this->link_id);
353:         }351:         }


punbb-1.1/upload/include/functions.php punbb-1.1.5/upload/include/functions.php
328:     if ($user['title'] != '')328:     if ($user['title'] != '')
329:         $user_title = pun_htmlspecialchars($user['title']);329:         $user_title = pun_htmlspecialchars($user['title']);
330:     // If the user is banned330:     // If the user is banned
331:     else if (in_array(strtolower($user['username']), $ban_list))331:     else if (in_array(strtolower($user['username']), $ban_list, true))
332:         $user_title = $lang_common['Banned'];332:         $user_title = $lang_common['Banned'];
333:     else if ($user['status'] <= PUN_USER)333:     else if ($user['status'] <= PUN_USER)
334:     {334:     {
607: {607: {
608:     global $pun_config, $lang_common;608:     global $pun_config, $lang_common;
609: 609: 
610:     if (!preg_match('#^'.preg_quote($pun_config['o_base_url'].'/'.$script, '#').'#i', $_SERVER['HTTP_REFERER']))610:     if (!preg_match('#^'.preg_quote(str_replace('www.', '', $pun_config['o_base_url']).'/'.$script, '#').'#i', str_replace('www.', '', $_SERVER['HTTP_REFERER'])))
611:         message($lang_common['Bad referer']);611:         message($lang_common['Bad referer']);
612: }    612: }    
613: 613: 


punbb-1.1/upload/include/parser.php punbb-1.1.5/upload/include/parser.php
 72: { 72: {
 73:     global $lang_common; 73:     global $lang_common;
 74:  74: 
 75:     set_time_limit(3); 
 76:  
 77:     // The maximum allowed quote depth 75:     // The maximum allowed quote depth
 78:     $max_depth = 3; 76:     $max_depth = 3;
 79:  77: 
175: {173: {
176:     global $cur_user;174:     global $cur_user;
177: 175: 
178:     $full_url = $url;176:     $full_url = str_replace(' ', '%20', $url);
179:     if (strpos($url, 'www.') === 0)177:     if (strpos($url, 'www.') === 0)
180:         $full_url = 'http://'.$full_url;178:         $full_url = 'http://'.$full_url;
181:     else if (strpos($url, 'ftp.') === 0)179:     else if (strpos($url, 'ftp.') === 0)
182:         $full_url = 'ftp://'.$full_url;180:         $full_url = 'ftp://'.$full_url;
 181:     else if (!preg_match('#^([a-z]{3,5})://#', $url))
 182:         $full_url = 'http://'.$full_url;
183: 183: 
184:     // Ok, not very pretty :-)184:     // Ok, not very pretty :-)
185:     $link = ($link == '' || $link == $url) ? ((strlen($url) > 55) ? substr($url, 0 , 39).' ... '.substr($url, -10) : $url) : stripslashes($link);185:     $link = ($link == '' || $link == $url) ? ((strlen($url) > 55) ? substr($url, 0 , 39).' ... '.substr($url, -10) : $url) : stripslashes($link);
207:                      '#\[email=(.*?)\](.*?)\[/email\]#',207:                      '#\[email=(.*?)\](.*?)\[/email\]#',
208:                      '#\[color=([a-zA-Z]*|\#?[0-9a-fA-F]{6})](.*?)\[/color\]#s');208:                      '#\[color=([a-zA-Z]*|\#?[0-9a-fA-F]{6})](.*?)\[/color\]#s');
209: 209: 
210:     $replace = array('<b>$1</b>',210:     $replace = array('<strong>$1</strong>',
211:                      '<i>$1</i>',211:                      '<em>$1</em>',
212:                      '<u>$1</u>',212:                      '<u>$1</u>',
213:                      'truncate_url("$1")',213:                      'truncate_url(\'$1\')',
214:                      'truncate_url("$1", "$2")',214:                      'truncate_url(\'$1\', \'$2\')',
215:                      '<a href="mailto:$1">$1</a>',215:                      '<a href="mailto:$1">$1</a>',
216:                      '<a href="mailto:$1">$2</a>',216:                      '<a href="mailto:$1">$2</a>',
217:                      '<span style="color: $1">$2</span>');217:                      '<span style="color: $1">$2</span>');
239: 239: 
240:     $message = ' '.$message;240:     $message = ' '.$message;
241: 241: 
242:     $message = preg_replace('#([\t\n\(\) ])(https?|ftp|news){1}://([\w\-]+\.([\w\-]+\.)*[\w]+(:[0-9]+)?(/[^ "\(\)\n\r\t<]*)?)#ie', '"$1".truncate_url("$2://$3")', $message);242:     $message = preg_replace('#([\s\(\)])(https?|ftp|news){1}://([\w\-]+\.([\w\-]+\.)*[\w]+(:[0-9]+)?(/[^"\s\(\)<\[]*)?)#ie', '\'$1\'.truncate_url(\'$2://$3\')', $message);
243:     $message = preg_replace('#([\t\n\(\) ])(www|ftp)\.(([\w\-]+\.)*[\w]+(:[0-9]+)?(/[^ "\(\)\n\r\t<]*)?)#ie', '"$1".truncate_url("$2.$3", "$2.$3")', $message);243:     $message = preg_replace('#([\s\(\)])(www|ftp)\.(([\w\-]+\.)*[\w]+(:[0-9]+)?(/[^"\s\(\)<\[]*)?)#ie', '\'$1\'.truncate_url(\'$2.$3\', \'$2.$3\')', $message);
244: 244: 
245:     return substr($message, 1);245:     return substr($message, 1);
246: }246: }


punbb-1.1/upload/include/search_idx.php punbb-1.1.5/upload/include/search_idx.php
 43:  43: 
 44:     if (empty($noise_match)) 44:     if (empty($noise_match))
 45:     { 45:     {
 46:         $noise_match =         array('^', '$', '&', '(', ')', '<', '>', '`', '\'', '"', '|', ',', '@', '_', '?', '%', '-', '~', '+', '.', '[', ']', '{', '}', ':', '\\', '/', '=', '#', ';', '!', '*'); 46:         $noise_match =         array('quote', 'code', 'url', 'img', 'email', 'color', 'colour', '^', '$', '&', '(', ')', '<', '>', '`', '\'', '"', '|', ',', '@', '_', '?', '%', '-', '~', '+', '.', '[', ']', '{', '}', ':', '\\', '/', '=', '#', ';', '!', '*');
 47:         $noise_replace =    array(' ', ' ', ' ', ' ', ' ', ' ', ' ', '',  '',   ' ', ' ', ' ', ' ', '',  ' ', ' ', '',  ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '' ,  ' ', ' ', ' ', ' ', ' ', ' '); 47:         $noise_replace =    array('',      '',     '',    '',    '',      '',      '',       ' ', ' ', ' ', ' ', ' ', ' ', ' ', '',  '',   ' ', ' ', ' ', ' ', '',  ' ', ' ', '',  ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '' ,  ' ', ' ', ' ', ' ', ' ', ' ');
 48:  48: 
 49:         $stopwords = @file('lang/'.$language.'/'.$language.'_stopwords.txt'); 49:         $stopwords = @file('lang/'.$language.'/'.$language.'_stopwords.txt');
 50:     } 50:     }


punbb-1.1/upload/index.php punbb-1.1.5/upload/index.php
 53:  53: 
 54:  54: 
 55: // Print the categories and forums 55: // Print the categories and forums
 56: if ($cur_user['status'] < PUN_MOD) 56: $extra_sql = ($cur_user['status'] < PUN_MOD) ? ' WHERE f.admmod_only=\'0\'' : '';
 57:     $extra = ' WHERE f.admmod_only=\'0\''; 
 58:  57: 
 59: $result = $db->query('SELECT c.id AS cid, c.cat_name, f.id AS fid, f.forum_name, f.forum_desc, f.moderators, f.num_topics, f.num_posts, f.last_post, f.last_post_id, f.last_poster, f.closed FROM '.$db->prefix.'categories AS c INNER JOIN '.$db->prefix.'forums AS f ON c.id=f.cat_id'.$extra.' ORDER BY c.disp_position, c.id, f.disp_position') or error('Unable to fetch category/forum list', __FILE__, __LINE__, $db->error()); 58: $result = $db->query('SELECT c.id AS cid, c.cat_name, f.id AS fid, f.forum_name, f.forum_desc, f.moderators, f.num_topics, f.num_posts, f.last_post, f.last_post_id, f.last_poster, f.closed FROM '.$db->prefix.'categories AS c INNER JOIN '.$db->prefix.'forums AS f ON c.id=f.cat_id'.$extra_sql.' ORDER BY c.disp_position, c.id, f.disp_position') or error('Unable to fetch category/forum list', __FILE__, __LINE__, $db->error());
 60:  59: 
 61: while ($cur_forum = $db->fetch_assoc($result)) 60: while ($cur_forum = $db->fetch_assoc($result))
 62: { 61: {


punbb-1.1/upload/install.php punbb-1.1.5/upload/install.php
 24:  24: 
 25:  25: 
 26: // The PunBB version this script installs 26: // The PunBB version this script installs
 27: $punbb_version = '1.1'; 27: $punbb_version = '1.1.5';
 28:  28: 
 29:  29: 
 30: $pun_root = './'; 30: $pun_root = './';
289:             break;289:             break;
290: 290: 
291:         default:291:         default:
292:             exit('\''.$db_type.'\' is not a valid database type. <a href="JavaScript: history.go(-1)">Go back</a>.');292:             exit('\''.htmlspecialchars($db_type).'\' is not a valid database type. <a href="JavaScript: history.go(-1)">Go back</a>.');
293:             break;293:             break;
294:     }294:     }
295: 295: 
864:     $db->query('INSERT INTO '.$db_prefix."users (username, password, email) VALUES('Guest', 'Guest', 'Guest')", 1)864:     $db->query('INSERT INTO '.$db_prefix."users (username, password, email) VALUES('Guest', 'Guest', 'Guest')", 1)
865:         or exit('Unable to insert into table '.$db_prefix.'users. Please check your configuration and try again. <a href="JavaScript: history.go(-1)">Go back</a>.');865:         or exit('Unable to insert into table '.$db_prefix.'users. Please check your configuration and try again. <a href="JavaScript: history.go(-1)">Go back</a>.');
866: 866: 
867:     $db->query('INSERT INTO '.$db_prefix."users (username, password, email, num_posts, status, last_post, registered, last_visit) VALUES('".addslashes($username)."', '".pun_hash($password1)."', '$email', 1, 2, ".$now.", ".$now.", ".$now.')')867:     $db->query('INSERT INTO '.$db_prefix."users (username, password, email, num_posts, status, last_post, registered, last_visit, last_action) VALUES('".addslashes($username)."', '".pun_hash($password1)."', '$email', 1, 2, ".$now.", ".$now.", ".$now.", ".$now.')')
868:         or exit('Unable to insert into table '.$db_prefix.'users. Please check your configuration and try again. <a href="JavaScript: history.go(-1)">Go back</a>.');868:         or exit('Unable to insert into table '.$db_prefix.'users. Please check your configuration and try again. <a href="JavaScript: history.go(-1)">Go back</a>.');
869: 869: 
870:     // Insert config data870:     // Insert config data
975: 975: 
976: 976: 
977:     /// Display config.php and give further instructions977:     /// Display config.php and give further instructions
978:     $config = '<?php'."\n\n".'$db_type = \''.$db_type."';\n".'$db_host = \''.$db_host."';\n".'$db_name = \''.$db_name."';\n".'$db_username = \''.$db_username."';\n".'$db_password = \''.$db_password."';\n".'$db_prefix = \''.$db_prefix."';\n".'$p_connect = true;'."\n\n".'$cookie_name = '."'punbb_cookie';\n".'$cookie_domain = '."'';\n".'$cookie_path = '."'/';\n".'$cookie_secure = 0;'."\n\n".'$language = \'en\';'."\n\ndefine('PUN', 1);\n\n?>";978:     $config = '<?php'."\n\n".'$db_type = \''.$db_type."';\n".'$db_host = \''.$db_host."';\n".'$db_name = \''.$db_name."';\n".'$db_username = \''.$db_username."';\n".'$db_password = \''.$db_password."';\n".'$db_prefix = \''.$db_prefix."';\n".'$p_connect = false;'."\n\n".'$cookie_name = '."'punbb_cookie';\n".'$cookie_domain = '."'';\n".'$cookie_path = '."'/';\n".'$cookie_secure = 0;'."\n\n".'$language = \'en\';'."\n\ndefine('PUN', 1);\n\n?>";
979: 979: 
980: 980: 
981: ?>981: ?>


punbb-1.1/upload/lang/en/en_common.php punbb-1.1.5/upload/lang/en/en_common.php
  4: $lang_common = array(  4: $lang_common = array(
  5:   5: 
  6: // Text orientation and encoding  6: // Text orientation and encoding
  7: 'lang_direction'        =>    'LTR',    // LTR (Left-To-Right) or RTL (Right-To-Left)  7: 'lang_direction'        =>    'ltr',    // ltr (Left-To-Right) or rtl (Right-To-Left)
  8: 'lang_encoding'            =>    'iso-8859-1',  8: 'lang_encoding'            =>    'iso-8859-1',
   9: 'lang_multibyte'        =>    false,
  9:  10: 
 10: // Notices 11: // Notices
 11: 'Bad request'            =>    'Bad request. The link you followed is incorrect or outdated.', 12: 'Bad request'            =>    'Bad request. The link you followed is incorrect or outdated.',


punbb-1.1/upload/lang/en/en_edit.php punbb-1.1.5/upload/lang/en/en_edit.php
  8: 'Too long subject'        =>    'Subjects cannot be longer than 70 characters.',  8: 'Too long subject'        =>    'Subjects cannot be longer than 70 characters.',
  9: 'No caps subject'        =>    'Subjects must not contain only capital letters and special characters in this forum.',  9: 'No caps subject'        =>    'Subjects must not contain only capital letters and special characters in this forum.',
 10: 'No message'            =>    'You must enter a message.', 10: 'No message'            =>    'You must enter a message.',
 11: 'Too long message'        =>    'Posts cannot be longer that 65535 characters (64 Kb).', 11: 'Too long message'        =>    'Posts cannot be longer that 65535 characters (64 KB).',
 12: 'No caps message'        =>    'Messages must not contain only capital letters and special characters in this forum.', 12: 'No caps message'        =>    'Messages must not contain only capital letters and special characters in this forum.',
 13:  13: 
 14: // Miscellaneous 14: // Miscellaneous
 15: 'Show smilies'            =>    'Show smilies', 15: 'Show smilies'            =>    'Convert smilies to icons',
 16: 'Silent edit'            =>    'Silent edit (don\'t display "Edited by ..." in topic view)', 16: 'Silent edit'            =>    'Silent edit (don\'t display "Edited by ..." in topic view)',
 17: 'Edit message'            =>    'Edit message', 17: 'Edit message'            =>    'Edit message',
 18: 'Edit redirect'            =>    'Post updated. Redirecting ...' 18: 'Edit redirect'            =>    'Post updated. Redirecting ...'


punbb-1.1/upload/lang/en/en_post.php punbb-1.1.5/upload/lang/en/en_post.php
  8: 'Too long subject'        =>    'Subjects cannot be longer than 70 characters.',  8: 'Too long subject'        =>    'Subjects cannot be longer than 70 characters.',
  9: 'No caps subject'        =>    'Subjects must not contain only capital letters and special characters in this forum.',  9: 'No caps subject'        =>    'Subjects must not contain only capital letters and special characters in this forum.',
 10: 'No message'            =>    'You must enter a message.', 10: 'No message'            =>    'You must enter a message.',
 11: 'Too long message'        =>    'Posts cannot be longer that 65535 characters (64 Kb).', 11: 'Too long message'        =>    'Posts cannot be longer that 65535 characters (64 KB).',
 12: 'No caps message'        =>    'Messages must not contain only capital letters and special characters in this forum.', 12: 'No caps message'        =>    'Messages must not contain only capital letters and special characters in this forum.',
 13:  13: 
 14: // Miscellaneous 14: // Miscellaneous
 15: 'Post redirect'            =>    'Post entered. Redirecting ...', 15: 'Post redirect'            =>    'Post entered. Redirecting ...',
 16: 'Post a reply'            =>    'Post a reply', 16: 'Post a reply'            =>    'Post a reply',
 17: 'Post new topic'        =>    'Post new topic', 17: 'Post new topic'        =>    'Post new topic',
 18: 'Show smilies'            =>    'Show smilies as icons', 18: 'Show smilies'            =>    'Convert smilies to icons',
 19: 'Subscribe'                =>    'Subscribe to this topic', 19: 'Subscribe'                =>    'Subscribe to this topic',
 20: 'Topic review'            =>    'Topic review (newest first)', 20: 'Topic review'            =>    'Topic review (newest first)',
 21: 'Flood start'            =>    'At least', 21: 'Flood start'            =>    'At least',


punbb-1.1/upload/lang/en/en_stopwords.txt punbb-1.1.5/upload/lang/en/en_stopwords.txt
142: yet142: yet
143: you143: you
144: your144: your
145: yours145: yours
146: lol 
147: quote 
148: code 
149: img 
150: wrote 
151: 146: 


punbb-1.1/upload/lang/en/mail_templates/activate_email.tpl punbb-1.1.5/upload/lang/en/mail_templates/activate_email.tpl
  2:   2: 
  3: Hello <username>,  3: Hello <username>,
  4:   4: 
  5: You have requested to have a new e-mail address assigned to your account in the discussion forum at <base_url>. If you didn't request this or if you don't want to change your e-mail address you should just ignore this message. Only if you visit the activation page below will your password be changed. In order for the activation page to work, you must be logged in to the forum.  5: You have requested to have a new e-mail address assigned to your account in the discussion forum at <base_url>. If you didn't request this or if you don't want to change your e-mail address you should just ignore this message. Only if you visit the activation page below will your e-mail address be changed. In order for the activation page to work, you must be logged in to the forum.
  6:   6: 
  7: To change your e-mail address, please visit the following page:  7: To change your e-mail address, please visit the following page:
  8: <activation_url>  8: <activation_url>


punbb-1.1/upload/lang/en/mail_templates/form_email.tpl punbb-1.1.5/upload/lang/en/mail_templates/form_email.tpl
 10: ----------------------------------------------------------------------- 10: -----------------------------------------------------------------------
 11:  11: 
 12: --  12: -- 
 13: <board_mailer> 
 14: (Do not reply to this message) 
 15:  13: 
  14: <board_mailer>
 16:  15: 


punbb-1.1/upload/login.php punbb-1.1.5/upload/login.php
 81: else if ($action == 'out') 81: else if ($action == 'out')
 82: { 82: {
 83:     if ($cookie['is_guest']) 83:     if ($cookie['is_guest'])
  84:     {
 84:         header('Location: index.php'); 85:         header('Location: index.php');
  86:         exit;
  87:     }
 85:  88: 
 86:     // Remove user from "users online" list. 89:     // Remove user from "users online" list.
 87:     $db->query('DELETE FROM '.$db->prefix.'online WHERE ident=\''.addslashes($cur_user['username']).'\'') or error('Unable to delete from online list', __FILE__, __LINE__, $db->error()); 90:     $db->query('DELETE FROM '.$db->prefix.'online WHERE ident=\''.addslashes($cur_user['username']).'\'') or error('Unable to delete from online list', __FILE__, __LINE__, $db->error());


punbb-1.1/upload/misc.php punbb-1.1.5/upload/misc.php
105: 105: 
106:         pun_mail($recipient_email, $mail_subject, $mail_message, $cur_user['username'].' <'.$cur_user['email'].'>');106:         pun_mail($recipient_email, $mail_subject, $mail_message, $cur_user['username'].' <'.$cur_user['email'].'>');
107: 107: 
108:         redirect('profile.php?id='.$recipient_id, $lang_misc['E-mail sent redirect']);108:         redirect($_POST['redirect_url'], $lang_misc['E-mail sent redirect']);
109:     }109:     }
110: 110: 
111: 111: 
 112:     // Try to determine if the data in HTTP_REFERER is valid (if not, we redirect to the users profile after the e-mail is sent)
 113:     $redirect_url = (isset($_SERVER['HTTP_REFERER']) && preg_match('#^'.preg_quote($pun_config['o_base_url']).'/(.*?)\.php#i', $_SERVER['HTTP_REFERER'])) ? $_SERVER['HTTP_REFERER'] : 'index.php';
 114: 
112:     $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Send e-mail'];115:     $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Send e-mail'];
113:     $validate_form = true;116:     $validate_form = true;
114:     $element_names = array('req_subject' => $lang_misc['E-mail subject'], 'req_message' => $lang_misc['E-mail message']);117:     $element_names = array('req_subject' => $lang_misc['E-mail subject'], 'req_message' => $lang_misc['E-mail message']);
121: 124: 
122: <form method="post" action="misc.php?email=<?php echo $recipient_id ?>" id="email" onsubmit="return process_form(this)">125: <form method="post" action="misc.php?email=<?php echo $recipient_id ?>" id="email" onsubmit="return process_form(this)">
123:     <input type="hidden" name="form_sent" value="1">126:     <input type="hidden" name="form_sent" value="1">
 127:     <input type="hidden" name="redirect_url" value="<?php echo $redirect_url ?>">
124:     <table class="punmain" cellspacing="1" cellpadding="4">128:     <table class="punmain" cellspacing="1" cellpadding="4">
125:         <tr class="punhead">129:         <tr class="punhead">
126:             <td class="punhead" colspan="2"><?php echo $lang_misc['Send e-mail'] ?></td>130:             <td class="punhead" colspan="2"><?php echo $lang_misc['Send e-mail'] ?></td>


punbb-1.1/upload/moderate.php punbb-1.1.5/upload/moderate.php
 39:         message($lang_common['No permission']); 39:         message($lang_common['No permission']);
 40:  40: 
 41:     $result = $db->query('SELECT poster_ip FROM '.$db->prefix.'posts WHERE id='.$get_host) or error('Unable to fetch post IP address', __FILE__, __LINE__, $db->error()); 41:     $result = $db->query('SELECT poster_ip FROM '.$db->prefix.'posts WHERE id='.$get_host) or error('Unable to fetch post IP address', __FILE__, __LINE__, $db->error());
  42:     if (!$db->num_rows($result))
  43:         message($lang_common['Bad request']);
  44: 
 42:     $ip = $db->result($result, 0); 45:     $ip = $db->result($result, 0);
 43:  46: 
 44:     message('The IP address is: '.$ip.'<br>The host name is: '.gethostbyaddr($ip).'<br><br><a href="admin_users.php?show_users='.$ip.'">Show more users for this IP</a>'); 47:     message('The IP address is: '.$ip.'<br>The host name is: '.gethostbyaddr($ip).'<br><br><a href="admin_users.php?show_users='.$ip.'">Show more users for this IP</a>');
313:                 $moved_to = $db->fetch_assoc($result);316:                 $moved_to = $db->fetch_assoc($result);
314: 317: 
315:                 // Create the redirect topic318:                 // Create the redirect topic
316:                 $db->query('INSERT INTO '.$db->prefix.'topics (poster, subject, posted, last_post, moved_to, forum_id) VALUES(\''.$moved_to['poster'].'\', \''.$moved_to['subject'].'\', '.$moved_to['posted'].', '.$moved_to['last_post'].', '.$cur_topic.', '.$fid.')') or error('Unable to create redirect topic', __FILE__, __LINE__, $db->error());319:                 $db->query('INSERT INTO '.$db->prefix.'topics (poster, subject, posted, last_post, moved_to, forum_id) VALUES(\''.addslashes($moved_to['poster']).'\', \''.addslashes($moved_to['subject']).'\', '.$moved_to['posted'].', '.$moved_to['last_post'].', '.$cur_topic.', '.$fid.')') or error('Unable to create redirect topic', __FILE__, __LINE__, $db->error());
317:             }320:             }
318:         }321:         }
319: 322: 


punbb-1.1/upload/post.php punbb-1.1.5/upload/post.php
 40:         message($lang_post['Flood start'].' '.$pun_config['o_flood_interval'].' '.$lang_post['flood end']); 40:         message($lang_post['Flood start'].' '.$pun_config['o_flood_interval'].' '.$lang_post['flood end']);
 41:  41: 
 42:     // Make sure form_user is correct 42:     // Make sure form_user is correct
 43:     if (($cookie['is_guest'] && $_POST['form_user'] != 'Guest') || (!$cookie['is_guest'] && $_POST['form_user'] != $cur_user['username'])) 43:     if (($cookie['is_guest'] && $_POST['form_user'] != 'Guest') || (!$cookie['is_guest'] && unescape($_POST['form_user']) != $cur_user['username']))
 44:         message($lang_common['Bad request']); 44:         message($lang_common['Bad request']);
 45:  45: 
 46:     $smilies = $_POST['smilies']; 46:     $smilies = $_POST['smilies'];
110:     else110:     else
111:     {111:     {
112:         $username = trim(unescape($_POST['req_username']));112:         $username = trim(unescape($_POST['req_username']));
113:         $email = trim($_POST['req_email']);113:         $email = strtolower(trim($_POST['req_email']));
114: 114: 
115:         // Load the register.php/profile.php language files115:         // Load the register.php/profile.php language files
116:         require $pun_root.'lang/'.$language.'/'.$language.'_prof_reg.php';116:         require $pun_root.'lang/'.$language.'/'.$language.'_prof_reg.php';
117:         require $pun_root.'lang/'.$language.'/'.$language.'_register.php';117:         require $pun_root.'lang/'.$language.'/'.$language.'_register.php';
118: 118: 
119:         // It's a guest, so we have to check the username119:         // It's a guest, so we have to validate the username
120:         if (strlen($username) < 2)120:         if (strlen($username) < 2)
121:             message($lang_prof_reg['Username too short']);121:             message($lang_prof_reg['Username too short']);
122:         else if (!strcasecmp($username, 'Guest') || !strcasecmp($username, $lang_common['Guest']))122:         else if (!strcasecmp($username, 'Guest') || !strcasecmp($username, $lang_common['Guest']))
123:             message($lang_prof_reg['Username guest']);123:             message($lang_prof_reg['Username guest']);
124:         else if (preg_match('/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/', $username))124:         else if (preg_match('/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/', $username))
125:             message($lang_prof_reg['Username IP']);125:             message($lang_prof_reg['Username IP']);
126:         else if (preg_match('#\[b\]|\[/b\]|\[u\]|\[/u\]|\[i\]|\[/i\]|\[color|\[/color\]|\[quote\]|\[/quote\]|\[code\]|\[/code\]|\[img\]|\[/img\]|\[url|\[/url\]|\[email|\[/email\]#i', $username))126:         else if ((strpos($username, '[') !== false || strpos($username, ']') !== false) && strpos($username, '\'') !== false && strpos($username, '"') !== false)
 127:             message($lang_prof_reg['Username reserved chars']);
 128:         else if (preg_match('#\[b\]|\[/b\]|\[u\]|\[/u\]|\[i\]|\[/i\]|\[color|\[/color\]|\[quote\]|\[quote=|\[/quote\]|\[code\]|\[/code\]|\[img\]|\[/img\]|\[url|\[/url\]|\[email|\[/email\]#i', $username))
127:             message($lang_prof_reg['Username BBCode']);129:             message($lang_prof_reg['Username BBCode']);
128: 130: 
129:         // Check username for any censored words131:         // Check username for any censored words
364:                 if (strpos($q_poster, '[') !== false || strpos($q_poster, ']') !== false)366:                 if (strpos($q_poster, '[') !== false || strpos($q_poster, ']') !== false)
365:                 {367:                 {
366:                     if (strpos($q_poster, '\'') !== false)368:                     if (strpos($q_poster, '\'') !== false)
367:                         $q_poster =  '"'.$q_poster.'"';369:                         $q_poster = '"'.$q_poster.'"';
368:                     else370:                     else
369:                         $q_poster = '\''.$q_poster.'\'';371:                         $q_poster = '\''.$q_poster.'\'';
370:                 }372:                 }
 373:                 else
 374:                 {
 375:                     // Get the characters at the start and end of $q_poster
 376:                     $ends = substr($q_poster, 0, 1).substr($q_poster, -1, 1);
 377: 
 378:                     // Deal with quoting "Username" or 'Username' (becomes '"Username"' or "'Username'")
 379:                     if ($ends == '\'\'')
 380:                         $q_poster = '"'.$q_poster.'"';
 381:                     else if ($ends == '""')
 382:                         $q_poster = '\''.$q_poster.'\'';
 383:                 }
371: 384: 
372:                 $quote = '[quote='.$q_poster.']'.$q_message.'[/quote]'."\n";385:                 $quote = '[quote='.$q_poster.']'.$q_message.'[/quote]'."\n";
373:             }386:             }
374:             else387:             else
375:                 $quote = '> '.$q_poster.' '.$lang_post['wrote'].':'."\n\n".'> '.$q_message."\n";388:                 $quote = '> '.$q_poster.' '.$lang_common['wrote'].':'."\n\n".'> '.$q_message."\n";
376:         }389:         }
377: 390: 
378:         // We have to fetch the forum name in order to display Title / Forum / Topic391:         // We have to fetch the forum name in order to display Title / Forum / Topic
525: ?>538: ?>
526:     <tr>539:     <tr>
527:         <td class="puncon1" style="width: 140px; vertical-align: top"><?php echo pun_htmlspecialchars($cur_post['poster']) ?></td>540:         <td class="puncon1" style="width: 140px; vertical-align: top"><?php echo pun_htmlspecialchars($cur_post['poster']) ?></td>
528:         <td class="puncon2"><?php echo $cur_post['message'] ?></td>541:         <td class="puncon2"><span class="puntext"><?php echo $cur_post['message'] ?></span></td>
529:     </tr>542:     </tr>
530: <?php543: <?php
531: 544: 


punbb-1.1/upload/profile.php punbb-1.1.5/upload/profile.php
 49:     { 49:     {
 50:         // If the user is already logged in we shouldn't be here :) 50:         // If the user is already logged in we shouldn't be here :)
 51:         if (!$cookie['is_guest']) 51:         if (!$cookie['is_guest'])
  52:         {
 52:             header('Location: index.php'); 53:             header('Location: index.php');
  54:             exit;
  55:         }
 53:  56: 
 54:         $key = $_GET['key']; 57:         $key = $_GET['key'];
 55:  58: 
600:     if ($cur_user['id'] != $id && $cur_user['status'] < PUN_MOD)603:     if ($cur_user['id'] != $id && $cur_user['status'] < PUN_MOD)
601:         message($lang_common['No permission']);604:         message($lang_common['No permission']);
602: 605: 
603:     $form = $_POST['form'];606:     // Extract elements from $_POST['form']
 607:     $wanted_elements = array('realname', 'url', 'icq', 'msn', 'aim', 'yahoo', 'location', 'use_avatar', 'disp_topics', 'disp_posts', 'timezone', 'email_setting', 'save_pass', 'notify_with_post', 'smilies', 'show_img', 'show_avatars', 'show_sig', 'link_to_new_win', 'style');
 608:     $form = array();
 609: 
 610:     while (list($key, $value) = @each($_POST['form']))
 611:     {
 612:         if (in_array($key, $wanted_elements))
 613:             $form[$key] = $value;
 614:     }
604: 615: 
605: 616: 
606:     if ($cur_user['status'] > PUN_USER)617:     if ($cur_user['status'] > PUN_USER)
612: 623: 
613:         if (strlen($username) < 2)624:         if (strlen($username) < 2)
614:             message($lang_prof_reg['Username too short']);625:             message($lang_prof_reg['Username too short']);
 626:         else if (pun_strlen($username) > 25)    // This usually doesn't happen since the form element only accepts 25 characters
 627:             message($lang_common['Bad request']);
615:         else if (!strcasecmp($username, 'Guest') || !strcasecmp($username, $lang_common['Guest']))628:         else if (!strcasecmp($username, 'Guest') || !strcasecmp($username, $lang_common['Guest']))
616:             message($lang_prof_reg['Username guest']);629:             message($lang_prof_reg['Username guest']);
617:         else if (preg_match('/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/', $username))630:         else if (preg_match('/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/', $username))
669:         $form['url'] = 'http://'.$form['url'];682:         $form['url'] = 'http://'.$form['url'];
670: 683: 
671:     // If the ICQ UIN contains anything other than digits it's invalid684:     // If the ICQ UIN contains anything other than digits it's invalid
672:     if ($form['icq'] != '' && preg_match('/[^0-9]/', $form[icq]))685:     if ($form['icq'] != '' && preg_match('/[^0-9]/', $form['icq']))
673:         message($lang_prof_reg['Bad ICQ']);686:         message($lang_prof_reg['Bad ICQ']);
674: 687: 
675: 688: 
940:         {953:         {
941:             $username_field = '<input type="hidden" name="old_username" value="'.pun_htmlspecialchars($user['username']).'"><input type="text" name="username" value="'.pun_htmlspecialchars($user['username']).'" size="25" maxlength="25">';954:             $username_field = '<input type="hidden" name="old_username" value="'.pun_htmlspecialchars($user['username']).'"><input type="text" name="username" value="'.pun_htmlspecialchars($user['username']).'" size="25" maxlength="25">';
942:             $email_field = '<input type="text" name="req_email" value="'.$user['email'].'" size="40" maxlength="50"> - <a href="misc.php?email='.$id.'">'.$lang_common['Send e-mail'].'</a>';955:             $email_field = '<input type="text" name="req_email" value="'.$user['email'].'" size="40" maxlength="50"> - <a href="misc.php?email='.$id.'">'.$lang_common['Send e-mail'].'</a>';
943:             $user_title_field = '<input type="text" name="title" value="'.$user['title'].'" size="30" maxlength="50">&nbsp;&nbsp;'.$lang_prof_reg['Leave blank'];956:             $user_title_field = '<input type="text" name="title" value="'.$user['title'].'" size="30" maxlength="50">&nbsp;&nbsp;'.$lang_profile['Leave blank'];
944: 957: 
945:             if ($cur_user['status'] == PUN_ADMIN && $img_size)958:             if ($cur_user['status'] == PUN_ADMIN && $img_size)
946:                 $avatar_field .= '<br>&nbsp;<a href="profile.php?action=delete_avatar&amp;id='.$id.'">'.$lang_profile['Delete avatar'].'</a>';959:                 $avatar_field .= '<br>&nbsp;<a href="profile.php?action=delete_avatar&amp;id='.$id.'">'.$lang_profile['Delete avatar'].'</a>';
955:                 $email_field = '<input type="text" name="req_email" value="'.$user['email'].'" size="40" maxlength="50">';968:                 $email_field = '<input type="text" name="req_email" value="'.$user['email'].'" size="40" maxlength="50">';
956: 969: 
957:             if ($pun_config['p_users_set_title'] == '1')970:             if ($pun_config['p_users_set_title'] == '1')
958:                 $user_title_field = '<input type="text" name="title" value="'.$user['title'].'" size="30" maxlength="50">&nbsp;&nbsp;'.$lang_prof_reg['Leave blank'];971:                 $user_title_field = '<input type="text" name="title" value="'.$user['title'].'" size="30" maxlength="50">&nbsp;&nbsp;'.$lang_profile['Leave blank'];
959:             else972:             else
960:             {973:             {
961:                 $user_title_field = get_title($user);974:                 $user_title_field = get_title($user);
1040:         </tr>1053:         </tr>
1041: <?php endif; ?>        <tr>1054: <?php endif; ?>        <tr>
1042:             <td class="puncon1right" style="width: 140px; white-space: nowrap">1055:             <td class="puncon1right" style="width: 140px; white-space: nowrap">
1043:                 <?php echo $lang_prof_reg['Signature'] ?>&nbsp;&nbsp;<br><br>1056:                 <?php echo $lang_profile['Signature'] ?>&nbsp;&nbsp;<br><br>
1044:                 <a href="help.php#bbcode" target="_blank"><?php echo $lang_common['BBCode'] ?></a>: <?php echo ($pun_config['p_sig_bbcode'] == '1') ? $lang_common['on'] : $lang_common['off']; ?>&nbsp;&nbsp;<br>1057:                 <a href="help.php#bbcode" target="_blank"><?php echo $lang_common['BBCode'] ?></a>: <?php echo ($pun_config['p_sig_bbcode'] == '1') ? $lang_common['on'] : $lang_common['off']; ?>&nbsp;&nbsp;<br>
1045:                 <a href="help.php#img" target="_blank"><?php echo $lang_common['img tag'] ?></a>: <?php echo ($pun_config['p_sig_img_tag'] == '1') ? $lang_common['on'] : $lang_common['off']; ?>&nbsp;&nbsp;<br>1058:                 <a href="help.php#img" target="_blank"><?php echo $lang_common['img tag'] ?></a>: <?php echo ($pun_config['p_sig_img_tag'] == '1') ? $lang_common['on'] : $lang_common['off']; ?>&nbsp;&nbsp;<br>
1046:                 <a href="help.php#smilies" target="_blank"><?php echo $lang_common['Smilies'] ?></a>: <?php echo ($pun_config['o_smilies_sig'] == '1') ? $lang_common['on'] : $lang_common['off']; ?>&nbsp;&nbsp;<br>1059:                 <a href="help.php#smilies" target="_blank"><?php echo $lang_common['Smilies'] ?></a>: <?php echo ($pun_config['o_smilies_sig'] == '1') ? $lang_common['on'] : $lang_common['off']; ?>&nbsp;&nbsp;<br>
1125:                 &nbsp;<select name="form[style]">1138:                 &nbsp;<select name="form[style]">
1126: <?php1139: <?php
1127: 1140: 
1128:         $d = dir('style');1141:         $d = dir($pun_root.'style');
1129:         while (($entry = $d->read()) !== false)1142:         while (($entry = $d->read()) !== false)
1130:         {1143:         {
1131:             if (substr($entry, strlen($entry)-4) == '.css')1144:             if (substr($entry, strlen($entry)-4) == '.css')


punbb-1.1/upload/register.php punbb-1.1.5/upload/register.php
 29:  29: 
 30: // If we are logged in, we shouldn't be here 30: // If we are logged in, we shouldn't be here
 31: if (!$cookie['is_guest']) 31: if (!$cookie['is_guest'])
  32: {
 32:     header('Location: index.php'); 33:     header('Location: index.php');
  34:     exit;
  35: }
 33:  36: 
 34: // Load the register.php language file 37: // Load the register.php language file
 35: require $pun_root.'lang/'.$language.'/'.$language.'_register.php'; 38: require $pun_root.'lang/'.$language.'/'.$language.'_register.php';
 99:     // Validate username and passwords102:     // Validate username and passwords
100:     if (strlen($username) < 2)103:     if (strlen($username) < 2)
101:         message($lang_prof_reg['Username too short']);104:         message($lang_prof_reg['Username too short']);
 105:     else if (pun_strlen($username) > 25)    // This usually doesn't happen since the form element only accepts 25 characters
 106:         message($lang_common['Bad request']);
102:     else if (strlen($password1) < 4)107:     else if (strlen($password1) < 4)
103:         message($lang_prof_reg['Pass too short']);108:         message($lang_prof_reg['Pass too short']);
104:     else if ($password1 != $password2)109:     else if ($password1 != $password2)


punbb-1.1/upload/search.php punbb-1.1.5/upload/search.php
 53:  53: 
 54:  54: 
 55: // Detect two byte character sets 55: // Detect two byte character sets
 56: $multibyte = (in_array($lang_common['lang_encoding'], array('utf-8', 'gb2312', 'big5', 'shift_jis', 'euc-kr'))) ? true : false; 56: $multibyte = (isset($lang_common['lang_multibyte']) && $lang_common['lang_multibyte']) ? true : false;
 57:  57: 
 58:  58: 
 59: // Figure out what to do :-) 59: // Figure out what to do :-)
188:                         while (list(, $word) = @each($stopwords))188:                         while (list(, $word) = @each($stopwords))
189:                         {189:                         {
190:                             $word = trim($word);190:                             $word = trim($word);
191:                             if ($word != 'and' || $word != 'or' || $word != 'not')191:                             if ($word != 'and' && $word != 'or' && $word != 'not')
192:                                 $text = preg_replace('#\b'.preg_quote($word).'\b#', ' ', $text);192:                                 $keywords = preg_replace('#\b'.preg_quote($word).'\b#', ' ', $keywords);
193:                         }193:                         }
194:                     }194:                     }
195: 195: 
196:                     // Split up keywords196:                     // Split up keywords
197:                     $keywords_array = preg_split('#[\s]+#', substr($keywords, 1, -1));197:                     $keywords_array = preg_split('#[\s]+#', trim($keywords));
198: 198: 
199:                     // Should we search in message body or topic subject specifically?199:                     // Should we search in message body or topic subject specifically?
200:                     if ($search_in)200:                     $search_in_cond = ($search_in) ? (($search_in > 0) ? ' AND m.subject_match = 0' : ' AND m.subject_match = 1') : '';
201:                         $search_in_cond = ($search_in > 0) ? ' AND m.subject_match = 0' : ' AND m.subject_match = 1'; 
202:                 }201:                 }
203: 202: 
204:                 $match_type = 'or';203:                 $match_type = 'or';
565:                 if ($search_set[$i]['poster_id'] > 1)564:                 if ($search_set[$i]['poster_id'] > 1)
566:                     $pposter = '<a href="profile.php?id='.$search_set[$i]['poster_id'].'">'.$pposter.'</a>';565:                     $pposter = '<a href="profile.php?id='.$search_set[$i]['poster_id'].'">'.$pposter.'</a>';
567: 566: 
568:                 if (pun_strlen($message) == 140)567:                 if (pun_strlen($message) >= 140)
569:                     $message .= ' ...';568:                     $message .= ' ...';
570: 569: 
571: ?>570: ?>
693:     echo "\t\t\t\t\t".'<option value="-1">'.$lang_search['All forums'].'</option>'."\n";692:     echo "\t\t\t\t\t".'<option value="-1">'.$lang_search['All forums'].'</option>'."\n";
694: 693: 
695: 694: 
696: if ($cur_user['status'] < PUN_USER)695: $extra_sql = ($cur_user['status'] < PUN_MOD) ? ' WHERE f.admmod_only=\'0\'' : '';
697:     $extra = ' WHERE f.admmod_only=\'0\''; 
698: 696: 
699: $result = $db->query('SELECT c.id AS cid, c.cat_name, f.id AS fid, f.forum_name FROM '.$db->prefix.'categories AS c INNER JOIN '.$db->prefix.'forums AS f ON c.id=f.cat_id'.$extra.' ORDER BY c.disp_position, c.id, f.disp_position') or error('Unable to fetch category/forum list', __FILE__, __LINE__, $db->error());697: $result = $db->query('SELECT c.id AS cid, c.cat_name, f.id AS fid, f.forum_name FROM '.$db->prefix.'categories AS c INNER JOIN '.$db->prefix.'forums AS f ON c.id=f.cat_id'.$extra_sql.' ORDER BY c.disp_position, c.id, f.disp_position') or error('Unable to fetch category/forum list', __FILE__, __LINE__, $db->error());
700: $num_forums = $db->num_rows($result);698: $num_forums = $db->num_rows($result);
701: 699: 
702: while ($num_forums--)700: while ($num_forums--)


punbb-1.1/upload/userlist.php punbb-1.1.5/upload/userlist.php
161: 161: 
162: <table class="punspacer" cellspacing="1" cellpadding="4">162: <table class="punspacer" cellspacing="1" cellpadding="4">
163:     <tr>163:     <tr>
164:         <td><?php echo $lang_common['Pages'].': '.paginate($num_pages, $p, 'userlist.php?prefix='.$prefix.'&amp;order_by='.$order_by.'&amp;direction='.strtolower($direction)) ?></td>164:         <td><?php echo $lang_common['Pages'].': '.paginate($num_pages, $p, 'userlist.php?order_by='.$order_by.'&amp;direction='.strtolower($direction)) ?></td>
165:     </tr>165:     </tr>
166: </table>166: </table>
167: <?php167: <?php


punbb-1.1/upload/viewtopic.php punbb-1.1.5/upload/viewtopic.php
 81:         header('Location: viewtopic.php?pid='.$first_new_post_id.'#'.$first_new_post_id); 81:         header('Location: viewtopic.php?pid='.$first_new_post_id.'#'.$first_new_post_id);
 82:     else    // If there is no new post, we go to the last post 82:     else    // If there is no new post, we go to the last post
 83:         header('Location: viewtopic.php?id='.$id.'&action=last'); 83:         header('Location: viewtopic.php?id='.$id.'&action=last');
  84: 
  85:     exit;
 84: } 86: }
 85:  87: 
 86:  88: 
 91:     $last_post_id = $db->result($result, 0); 93:     $last_post_id = $db->result($result, 0);
 92:  94: 
 93:     if ($last_post_id) 95:     if ($last_post_id)
  96:     {
 94:         header('Location: viewtopic.php?pid='.$last_post_id.'#'.$last_post_id); 97:         header('Location: viewtopic.php?pid='.$last_post_id.'#'.$last_post_id);
  98:         exit;
  99:     }
 95: }100: }
 96: 101: 
 97: 102: 
257: 262: 
258:         $info .= $lang_common['Registered'].': '.$registered.'<br>';263:         $info .= $lang_common['Registered'].': '.$registered.'<br>';
259: 264: 
260:         if ($pun_config['o_show_post_count'] == '1') 
261:             $info .= "\n\t\t\t\t\t\t\t".$lang_common['Posts'].': '.$cur_post['num_posts']; 
262:  
263:         if ($cur_user['status'] > PUN_USER)265:         if ($cur_user['status'] > PUN_USER)
264:         {266:         {
265:             $info .= '<br>'."\n\t\t\t\t\t\t\t".'IP: <a href="moderate.php?get_host='.$cur_post['id'].'">'.$cur_post['poster_ip'].'</a>';267:             $info .= "\n\t\t\t\t\t\t\t".$lang_common['Posts'].': '.$cur_post['num_posts'].'<br>'."\n\t\t\t\t\t\t\t".'IP: <a href="moderate.php?get_host='.$cur_post['id'].'">'.$cur_post['poster_ip'].'</a>';
266: 268: 
267:             if ($cur_post['admin_note'] != '')269:             if ($cur_post['admin_note'] != '')
268:                 $info .= '<br><br>'."\n\t\t\t\t\t\t\t".$lang_topic['Note'].': <b>'.$cur_post['admin_note'].'</b>';270:                 $info .= '<br><br>'."\n\t\t\t\t\t\t\t".$lang_topic['Note'].': <b>'.$cur_post['admin_note'].'</b>';
269:         }271:         }
 272:         else if ($pun_config['o_show_post_count'] == '1')
 273:             $info .= "\n\t\t\t\t\t\t\t".$lang_common['Posts'].': '.$cur_post['num_posts'];
270: 274: 
271:         // Generate an array of links that appear at the bottom of every message.275:         // Generate an array of links that appear at the bottom of every message.
272:         $links = array();276:         $links = array();


hdiff - version: 2.1.0 (modified)