I have added fields to my database for category title and am looking for help with making this title unique on each of the paginated result pages except for Page 1.
Page 1 = Gemstone Jewelry (the text I enter in admin for the category)
Page 2 = Gemstone Jewelry - Page 2
Page 3 = Gemstone Jewelry - Page 3
etc.
I'm using 1.5.2.1
Thanks.
This code in library pagination class needs to be modified.
if ($num_pages > 1) {
if ($num_pages <= $num_links) {
$start = 1;
$end = $num_pages;
} else {
$start = $page - floor($num_links / 2);
$end = $page + floor($num_links / 2);
if ($start < 1) {
$end += abs($start) + 1;
$start = 1;
}
if ($end > $num_pages) {
$start -= ($end - $num_pages);
$end = $num_pages;
}
}
if ($start > 1) {
$output .= ' .... ';
}
for ($i = $start; $i <= $end; $i++) {
if ($page == $i) {
$output .= ' <b>' . $i . '</b> ';
} else {
$output .= ' <a href="' . str_replace('{page}', $i, $this->url) . '">' . $i . '</a> ';
}
}
if ($end < $num_pages) {
$output .= ' .... ';
}
}
if ($num_pages > 1) {
if ($num_pages <= $num_links) {
$start = 1;
$end = $num_pages;
} else {
$start = $page - floor($num_links / 2);
$end = $page + floor($num_links / 2);
if ($start < 1) {
$end += abs($start) + 1;
$start = 1;
}
if ($end > $num_pages) {
$start -= ($end - $num_pages);
$end = $num_pages;
}
}
if ($start > 1) {
$output .= ' .... ';
}
for ($i = $start; $i <= $end; $i++) {
if ($page == $i) {
$output .= ' <b>' . $i . '</b> ';
} else {
$output .= ' <a href="' . str_replace('{page}', $i, $this->url) . '">' . $i . '</a> ';
}
}
if ($end < $num_pages) {
$output .= ' .... ';
}
}
Team of e-commerce experts.
oscprofessionals
Thanks to all who responded or messaged. I have managed to sort out the functionality I was looking for. Thanks!
STONEHINGED
Handcrafted, Semi-Precious Jewelry
http://www.stonehinged.com/
Who is online
Users browsing this forum: paulfeakins and 65 guests