page_nav.inc
上传用户:xiao730204
上传日期:2007-01-04
资源大小:141k
文件大小:2k
- <?php
- $url_util = new UrlObject();
- $base_url =
- $url_util->PostUrl(
- $default->base_url,
- Array(
- 'session_id' => $session_id,
- 'form_mode' => $sort_by
- )
- );
- $first_page_url = '';
- $last_page_url = '';
- $next_page_url = '';
- $previous_page_url = '';
- if ( $page_nav->current_page != 1 ) {
- $first_page_url =
- '<A Href="' .
- $url_util->PostUrl(
- $base_url,
- Array( 'page' => $page_nav->first_page )
- ) .
- '">[ First Page ]</A>';
- $previous_page_url =
- '<A Href="' .
- $url_util->PostUrl(
- $base_url,
- Array( 'page' => $page_nav->previous_page )
- ) .
- '">[ Previous Page ]</A>';
- } else {
- $first_page_url = '[ First Page ]';
- $previous_page_url = '[ Previous Page ]';
- }
- if ( $page_nav->last_page != $page_nav->current_page ) {
- $next_page_url =
- '<A Href="' .
- $url_util->PostUrl(
- $base_url,
- Array( 'page' => $page_nav->next_page )
- ) .
- '">[ Next Page ]</A>';
- $last_page_url =
- '<A Href="' .
- $url_util->PostUrl(
- $base_url,
- Array( 'page' => $page_nav->last_page )
- ) .
- '">[ Last Page ]</A>';
- } else {
- $next_page_url = '[ Next Page ]';
- $last_page_url = '[ Last Page ]';
- }
- ?>
- <tr <?php echo $template_obj->GetValue( 'nav_bgcolor' ); ?>>
- <td colspan="5">
- <?php echo $template_obj->GetValue( 'nav_font' ); ?>
- <center>
- <table border="0" width="100%">
- <tr>
- <td align="left">
- <?php echo $template_obj->GetValue( 'nav_font' ); ?>
-
- <?php
- echo( $first_page_url );
- echo( $previous_page_url );
- ?>
- </td>
- <td>
- <center>
- <b>
- <?php echo $template_obj->GetValue( 'nav_font' ); ?>
- Page <?php echo $page_nav->current_page; ?>
- <?php
- // Mystery code segment - && $page_nave != 1 ) {
- if ( $page_nav->last_page > 0 ) {
- echo( 'of ' . $page_nav->last_page );
- }
- ?>
- </b>
- </center>
- </td>
- <td align="right">
- <?php echo $template_obj->GetValue( 'nav_font' ); ?>
- <?php
- echo( $next_page_url );
- echo( $last_page_url );
- ?>
- </td>
- </tr>
- </table>
- </center>
- </td>
- </tr>