'
' . __('Pages:'), 'after' => '
', 'next_or_number' => 'number', 'nextpagelink' => __('Next page'), 'previouspagelink' => __('Previous page'), 'pagelink' => '%', 'more_file' => '', 'echo' => 1, 'blink'=>'','alink'=>''); $r = array_merge($defaults, $r); extract($r, EXTR_SKIP); global $id, $page, $numpages, $multipage, $more, $pagenow; if ( $more_file != '' ) $file = $more_file; else $file = $pagenow; $output = ''; if ( $multipage ) { if ( 'number' == $next_or_number ) { $output .= $before; for ( $i = 1; $i < ($numpages+1); $i = $i + 1 ) { $j = str_replace('%',"$i",$pagelink); $output .= ' '; if ( ($i != $page) || ((!$more) && ($page==1)) ) { if ( 1 == $i ) { $output .= $blink.''.$j.''.$alink; } else { if ( '' == get_option('permalink_structure') || 'draft' == $post->post_status ) $output .= $blink.''.$j.''.$alink; else $output .= $blink.''.$j.''.$alink; } }else{ $output .= $blink.''.$j.''.$alink; } } $output .= $after; } else { if ( $more ) { $output .= $before; $i = $page - 1; if ( $i && $more ) { if ( 1 == $i ) { $output .= $blink.'' . $previouspagelink . ''.$alink; } else { if ( '' == get_option('permalink_structure') || 'draft' == $post->post_status ) $output .= $blink.'' . $previouspagelink . ''.$alink; else $output .= $blink.'' . $previouspagelink . ''.$alink; } } $i = $page + 1; if ( $i <= $numpages && $more ) { if ( 1 == $i ) { $output .= $blink.'' . $nextpagelink . ''.$alink; } else { if ( '' == get_option('permalink_structure') || 'draft' == $post->post_status ) $output .= $blink.'' . $nextpagelink . ''.$alink; else $output .= $blink.'' . $nextpagelink . ''.$alink; } } $output .= $after; } } } if ( $echo ) echo $output; return $output; } ?>