Changeset 2227
- Timestamp:
- 02/06/2005 03:40:08 AM (21 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 9 edited
-
comment-functions.php (modified) (1 diff)
-
feed-functions.php (modified) (1 diff)
-
functions-post.php (modified) (3 diffs)
-
functions.php (modified) (1 diff)
-
template-functions-author.php (modified) (1 diff)
-
template-functions-category.php (modified) (5 diffs)
-
template-functions-general.php (modified) (6 diffs)
-
template-functions-links.php (modified) (8 diffs)
-
template-functions-post.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/comment-functions.php
r2168 r2227 599 599 600 600 if ($wpdb->query($query)) { 601 do_action('wp_set_comment_status', $comment_id );601 do_action('wp_set_comment_status', $comment_id, $comment_status); 602 602 return true; 603 603 } else { -
trunk/wp-includes/feed-functions.php
r2167 r2227 132 132 } 133 133 } 134 echo apply_filters('the_category_rss', $the_list );134 echo apply_filters('the_category_rss', $the_list, $type); 135 135 } 136 136 -
trunk/wp-includes/functions-post.php
r2225 r2227 390 390 global $wpdb; 391 391 392 do_action('wp_blacklist_check' );392 do_action('wp_blacklist_check', $author, $email, $url, $comment, $user_ip, $user_agent); 393 393 394 394 if ( preg_match_all('/&#(\d+);/', $comment . $author . $url, $chars) ) { … … 462 462 $time_newcomment = mysql2date('U', $now_gmt); 463 463 if ( ($time_newcomment - $time_lastcomment) < 15 ) { 464 do_action('comment_flood_trigger' );464 do_action('comment_flood_trigger', $time_lastcomment, $time_newcomment); 465 465 die( __('Sorry, you can only post a new comment once every 15 seconds. Slow down cowboy.') ); 466 466 } … … 483 483 484 484 $comment_id = $wpdb->insert_id; 485 do_action('comment_post', $comment_id );485 do_action('comment_post', $comment_id, $approved); 486 486 487 487 if ( 'spam' !== $approved ) { // If it's spam save it silently for later crunching -
trunk/wp-includes/functions.php
r2223 r2227 1670 1670 } 1671 1671 } 1672 else {1672 else if (! ststr($uri, '/')) { 1673 1673 $base = $uri . '?'; 1674 1674 $query = ''; -
trunk/wp-includes/template-functions-author.php
r2154 r2227 137 137 } 138 138 139 $link = apply_filters('author_link', $link );139 $link = apply_filters('author_link', $link, $author_id, $author_nicename); 140 140 if ($echo) echo $link; 141 141 return $link; -
trunk/wp-includes/template-functions-category.php
r2164 r2227 40 40 $catlink = get_settings('home') . trailingslashit($catlink); 41 41 } 42 $catlink = apply_filters('category_link', $catlink );42 $catlink = apply_filters('category_link', $catlink, $category_id, $category_nicename); 43 43 if ($echo) echo $catlink; 44 44 return $catlink; … … 100 100 } 101 101 } 102 echo apply_filters('the_category', $thelist );102 echo apply_filters('the_category', $thelist, $separator, $parents); 103 103 } 104 104 … … 174 174 if (!$category) $category = $cat; 175 175 $category_description = $cache_categories[$category]->category_description; 176 $category_description = apply_filters('category_description', $category_description );176 $category_description = apply_filters('category_description', $category_description, $category); 177 177 return $category_description; 178 178 } … … 213 213 if ($categories) { 214 214 foreach ($categories as $category) { 215 $cat_name = apply_filters('list_cats', $category->cat_name );215 $cat_name = apply_filters('list_cats', $category->cat_name, $category); 216 216 echo "\t<option value=\"".$category->cat_ID."\""; 217 217 if ($category->cat_ID == $selected) … … 329 329 $link .= 'title="'. sprintf(__("View all posts filed under %s"), wp_specialchars($category->cat_name)) . '"'; 330 330 } else { 331 $link .= 'title="' . wp_specialchars(apply_filters('category_description',$category->category_description )) . '"';331 $link .= 'title="' . wp_specialchars(apply_filters('category_description',$category->category_description,$category)) . '"'; 332 332 } 333 333 $link .= '>'; 334 $link .= apply_filters('list_cats', $category->cat_name ).'</a>';334 $link .= apply_filters('list_cats', $category->cat_name, $category).'</a>'; 335 335 336 336 if ( (! empty($feed_image)) || (! empty($feed)) ) { -
trunk/wp-includes/template-functions-general.php
r2184 r2227 60 60 function bloginfo($show='') { 61 61 $info = get_bloginfo($show); 62 $info = apply_filters('bloginfo', $info );62 $info = apply_filters('bloginfo', $info, $show); 63 63 echo convert_chars($info); 64 64 } … … 596 596 $previousday = $day; 597 597 } 598 $the_date = apply_filters('the_date', $the_date );598 $the_date = apply_filters('the_date', $the_date, $d, $before, $after); 599 599 if ($echo) { 600 600 echo $the_date; … … 605 605 606 606 function the_time( $d = '' ) { 607 echo apply_filters('the_time', get_the_time( $d ) );607 echo apply_filters('the_time', get_the_time( $d ), $d); 608 608 } 609 609 … … 613 613 else 614 614 $the_time = get_post_time($d); 615 return apply_filters('get_the_time', $the_time );615 return apply_filters('get_the_time', $the_time, $d); 616 616 } 617 617 … … 624 624 625 625 $time = mysql2date($d, $time); 626 return apply_filters('get_the_time', $time );626 return apply_filters('get_the_time', $time, $d, $gmt); 627 627 } 628 628 … … 643 643 $previousweekday = $day; 644 644 } 645 $the_weekday_date = apply_filters('the_weekday_date', $the_weekday_date );645 $the_weekday_date = apply_filters('the_weekday_date', $the_weekday_date, $before, $after); 646 646 echo $the_weekday_date; 647 647 } -
trunk/wp-includes/template-functions-links.php
r2195 r2227 75 75 $idpost->post_name, 76 76 ); 77 return apply_filters('post_link', get_settings('home') . str_replace($rewritecode, $rewritereplace, $permalink) );77 return apply_filters('post_link', get_settings('home') . str_replace($rewritecode, $rewritereplace, $permalink), $idpost); 78 78 } else { // if they're not using the fancy permalink option 79 79 $permalink = get_settings('home') . '/?p=' . $idpost->ID; 80 return apply_filters('post_link', $permalink );80 return apply_filters('post_link', $permalink, $idpost); 81 81 } 82 82 } … … 99 99 } 100 100 101 return apply_filters('page_link', $link );101 return apply_filters('page_link', $link, $id); 102 102 } 103 103 … … 108 108 if (!empty($yearlink)) { 109 109 $yearlink = str_replace('%year%', $year, $yearlink); 110 return apply_filters('year_link', get_settings('home') . trailingslashit($yearlink) );110 return apply_filters('year_link', get_settings('home') . trailingslashit($yearlink), $year); 111 111 } else { 112 return apply_filters('year_link', get_settings('home') .'/'. $querystring_start.'m'.$querystring_equal.$year );112 return apply_filters('year_link', get_settings('home') .'/'. $querystring_start.'m'.$querystring_equal.$year, $year); 113 113 } 114 114 } … … 122 122 $monthlink = str_replace('%year%', $year, $monthlink); 123 123 $monthlink = str_replace('%monthnum%', zeroise(intval($month), 2), $monthlink); 124 return apply_filters('month_link', get_settings('home') . trailingslashit($monthlink) );124 return apply_filters('month_link', get_settings('home') . trailingslashit($monthlink), $year, $month); 125 125 } else { 126 return apply_filters('month_link', get_settings('home') .'/'. $querystring_start.'m'.$querystring_equal.$year.zeroise($month, 2) );126 return apply_filters('month_link', get_settings('home') .'/'. $querystring_start.'m'.$querystring_equal.$year.zeroise($month, 2), $year, $month); 127 127 } 128 128 } … … 139 139 $daylink = str_replace('%monthnum%', zeroise(intval($month), 2), $daylink); 140 140 $daylink = str_replace('%day%', zeroise(intval($day), 2), $daylink); 141 return apply_filters('day_link', get_settings('home') . trailingslashit($daylink) );141 return apply_filters('day_link', get_settings('home') . trailingslashit($daylink), $year, $month, $day); 142 142 } else { 143 return apply_filters('day_link', get_settings('home') .'/'. $querystring_start.'m'.$querystring_equal.$year.zeroise($month, 2).zeroise($day, 2) );143 return apply_filters('day_link', get_settings('home') .'/'. $querystring_start.'m'.$querystring_equal.$year.zeroise($month, 2).zeroise($day, 2), $year, $month, $day); 144 144 } 145 145 } … … 171 171 } 172 172 173 return apply_filters('feed_link', $output );173 return apply_filters('feed_link', $output, $feed); 174 174 } 175 175 … … 265 265 } 266 266 267 $title = apply_filters('the_title', $post->post_title );267 $title = apply_filters('the_title', $post->post_title, $post); 268 268 269 269 $string = '<a href="'.get_permalink($post->ID).'">'; … … 285 285 } 286 286 287 $title = apply_filters('the_title', $post->post_title );287 $title = apply_filters('the_title', $post->post_title, $post); 288 288 289 289 $string = '<a href="'.get_permalink($post->ID).'">'; -
trunk/wp-includes/template-functions-post.php
r2208 r2227 32 32 $title = get_the_title(); 33 33 if (!empty($title)) { 34 $title = apply_filters('the_title', $before . $title . $after );34 $title = apply_filters('the_title', $before . $title . $after, $before, $after); 35 35 if ($echo) 36 36 echo $title;
Note: See TracChangeset
for help on using the changeset viewer.