 |

soj
User
Apr 17, 2008, 6:50 PM
Post #1 of 3
(161 views)
Shortcut
|
|
Blog entry by newest (date)
|
Can't Post
|
|
How might I display only the latest blog entry in, say, my index.php (as opposed to the pageList.php, etc)? Would the following or some version of work?
$options['where'] = 'fieldname = 'date DESC'; TIA! soj
|
|
|  |
 |

Dave
Staff
/ Moderator

Apr 18, 2008, 8:42 AM
Post #2 of 3
(151 views)
Shortcut
|
|
Re: [soj] Blog entry by newest (date)
[In reply to]
|
Can't Post
|
|
Close, you don't need the fieldname = part though. So it looks like this, and if you only want the latest (1 entry) we'll add a setting for that as well:
$options['orderBy'] = 'date DESC'; $options['perPage'] = '1'; // show 1 record $options['pageNum'] = '1'; // from first page only $options['where'] = '1'; // to ignore search options Let me know if that works for you. Dave Edis - Senior Developer interactivetools.com
|
|
|  |
 |

soj
User
Apr 18, 2008, 11:29 AM
Post #3 of 3
(149 views)
Shortcut
|
|
Re: [Dave] Blog entry by newest (date)
[In reply to]
|
Can't Post
|
|
Perfect, TUVM!
|
|
|  |
|