[wp-cvs]
wordpress/wp-includes classes.php, 1.9, 1.10 functions.php,
1.145, 1.146
Ryan Boren
rboren at users.sourceforge.net
Tue Aug 24 08:43:05 UTC 2004
Update of /cvsroot/cafelog/wordpress/wp-includes
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14743/wp-includes
Modified Files:
classes.php functions.php
Log Message:
Template redirection.
Index: functions.php
===================================================================
RCS file: /cvsroot/cafelog/wordpress/wp-includes/functions.php,v
retrieving revision 1.145
retrieving revision 1.146
diff -C2 -d -r1.145 -r1.146
*** functions.php 24 Aug 2004 01:24:48 -0000 1.145
--- functions.php 24 Aug 2004 08:43:01 -0000 1.146
***************
*** 1591,1594 ****
--- 1591,1600 ----
}
+ function is_page () {
+ global $wp_query;
+
+ return $wp_query->is_page;
+ }
+
function is_archive () {
global $wp_query;
Index: classes.php
===================================================================
RCS file: /cvsroot/cafelog/wordpress/wp-includes/classes.php,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** classes.php 24 Aug 2004 01:24:48 -0000 1.9
--- classes.php 24 Aug 2004 08:43:01 -0000 1.10
***************
*** 11,14 ****
--- 11,15 ----
var $is_single = false;
+ var $is_page = false;
var $is_archive = false;
var $is_date = false;
***************
*** 25,28 ****
--- 26,30 ----
function init () {
$this->is_single = false;
+ $this->is_page = false;
$this->is_archive = false;
$this->is_date = false;
***************
*** 153,165 ****
if ('' != $qv['feed']) {
$this->is_feed = true;
! $this->feed = $qv['feed'];
}
if ( ($this->is_date || $this->is_author || $this->is_category)
! && (! $this->is_single)) {
$this->is_archive = true;
}
! if ( ! ($this->is_archive || $this->is_single || $this->is_search || $this->is_feed)) {
$this->is_home = true;
}
--- 155,170 ----
if ('' != $qv['feed']) {
$this->is_feed = true;
! }
!
! if ('' != $qv['static'] || '' != $qv['pagename']) {
! $this->is_page = true;
}
if ( ($this->is_date || $this->is_author || $this->is_category)
! && (! ($this->is_single || $this->is_page)) ) {
$this->is_archive = true;
}
! if ( ! ($this->is_archive || $this->is_single || $this->is_page || $this->is_search || $this->is_feed)) {
$this->is_home = true;
}
More information about the cvs
mailing list