Changeset 24
- Timestamp:
- 12/29/2004 12:59:50 AM (20 years ago)
- Location:
- trunk
- Files:
-
- 5 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bb-includes/functions.php
r21 r24 353 353 $post_id = $bbdb->insert_id; 354 354 $bbdb->query("UPDATE $bbdb->forums SET posts = posts + 1 WHERE forum_id = $topic->forum_id"); 355 $bbdb->query("UPDATE $bbdb->topics SET topic_ last_poster = $uid, topic_last_poster_name = '$uname',355 $bbdb->query("UPDATE $bbdb->topics SET topic_time = '$now', topic_last_poster = $uid, topic_last_poster_name = '$uname', 356 356 topic_last_post_id = $post_id, topic_posts = topic_posts + 1 WHERE topic_id = $tid"); 357 357 bb_do_action('bb_new_post', $post_id); … … 423 423 } 424 424 425 function bb_global_sanitize( $array ) { 426 foreach ($array as $k => $v) { 427 if ( is_array($v) ) { 428 $array[$k] = bb_global_sanitize($v); 429 } else { 430 if ( get_magic_quotes_gpc() ) 431 $array[$k] = trim($v); 432 else 433 $array[$k] = addslashes( trim($v) ); 434 } 435 } 436 return $array; 437 } 438 425 439 ?> -
trunk/bb-settings.php
r18 r24 29 29 $static_title = ''; 30 30 31 if ( !get_magic_quotes_gpc() ) { 32 $_GET = add_magic_quotes($_GET ); 33 $_POST = add_magic_quotes($_POST ); 34 $_COOKIE = add_magic_quotes($_COOKIE); 35 $_SERVER = add_magic_quotes($_SERVER); 36 } 31 $_GET = bb_global_sanitize($_GET ); 32 $_POST = bb_global_sanitize($_POST ); 33 $_COOKIE = bb_global_sanitize($_COOKIE); 34 $_SERVER = bb_global_sanitize($_SERVER); 37 35 38 36 function bb_shutdown_action_hook() { -
trunk/bb-templates/login-form.php
r5 r24 1 1 <form name="login" method="post" action="<?php option('uri'); ?>bb-login.php"> 2 <p> 2 <p> <a href="<?php option('uri'); ?>register.php">Register</a> or login:<br /> 3 3 <label>Username: 4 4 <input name="username" type="text" id="username" size="15" maxlength="40" value="<?php echo bb_specialchars($_COOKIE['bb_user_' . BBHASH], 1); ?>" /> -
trunk/bb-templates/post-form.php
r5 r24 2 2 <form name="post" id="post" method="post" action="<?php option('uri'); ?>bb-post.php"> 3 3 <?php if ( is_forum() ) : ?> 4 <p>Before posting a new topic, <a href="<?php option('uri'); ?>search.php">be sure to search</a> to see if one has been started already.</p> 4 5 <p> 5 6 <label>Topic:<br />
Note: See TracChangeset
for help on using the changeset viewer.