<?php
// You can place PHP like this
global $scripturl;
$num_pages = 173;
$cover_image_url ="http://baask.com/literature/abid_askani/rushnoo/rushnoo.jpg";
$page_image_url = "http://baask.com/literature/abid_askani/rushnoo/0%s.gif";
if (empty($_GET['number']) || $_GET['number'] < 1 || $_GET['number'] > $num_pages)
{
$current_page = 0;
$image_url = $cover_image_url;
}
else
{
$current_page = (int) $_GET['number'];
$image_url = sprintf($page_image_url, ($current_page>9 ? '' : '0') . $current_page);
}
echo '
<div style="text-align: center;">
Page ', $current_page, ' of ', $num_pages, '
<p><img src="', $image_url, '" alt="', $current_page, '" /></p>';
for ($i = 0; $i <= $num_pages; $i++)
echo '
<a href="', $scripturl, '?page=rushnoo;number=', $i, '">', ($i == $current_page ? '<strong>[' : ''), ($i == 0 ? 'Cover' : $i), ($i == $current_page ? ']</strong>' : ''), '</a>';
echo '
<a href="http://baask.com/diwwan/index.php?topic=6722">Click for Comments and feedback </a>;
</div>';
?>