$value) $out[$index] = stripslashes(preg_replace($del,"",$value)); return $out; } } //now we what to obtain splited link $link = array(); $field = array(); $field[0] = "/\/thd\//"; $field[1] = "/\/$/"; $field[2] = "/^\//"; $link = split_uri(preg_replace($field,"",$_SERVER['REQUEST_URI'])); //here we know how many parameters has URI $params = count($link); if($params == 3) $three = 2; $path = pathOK(($params == 3 ? $three : $params)); if ((substr($_SERVER['REQUEST_URI'],-1,1) != "/") && $params <= 2) $path = preg_replace("/..\/$/","",$path); ?> Timeshare Resale, Sell Timeshare Resales, Timeshare Sale, Timeshare Sales, Selling & Rentals Timeshare, vacation property for rent selling, rent and b\n'. ''."\n". ''."\n". ''."\n". ''."\n"; ?>
  Links
"; //here will follow page content if(in_array($params,array(1,2))) { $catId = cat_id(urldecode($link[1])); $qry = "SELECT b.name AS cat_name,count(a.type) AS counter FROM linkshare AS a LEFT JOIN l_categs AS b ON b.id=a.type WHERE a.visible='1'".($params==2 ? " AND a.type={$catId}" : "")." GROUP BY a.type"; echo ""; $rs = mysql_query($qry,$GLOBALS['linkTBS']) or die(mysql_error($GLOBALS['linkTBS'])); if(mysql_num_rows($rs)) { while($row_cat = mysql_fetch_array($rs)) { echo ""; //here we will show pages $i = 1; $remain = $row_cat['counter']; echo ""; } } echo "
".ucfirst($row_cat['cat_name'])." ({$row_cat['counter']})
"; while($remain > 0) { echo ""; $remain -= LINKS; } echo "
".ucfirst($row_cat['cat_name'])." - ".$i++." (".($remain > LINKS ? LINKS : $remain).")
"; } elseif($params == 3) { $catId = cat_id(urldecode($link[1])); $counter = mysql_num_rows(mysql_query("SELECT id FROM linkshare WHERE type='{$catId}' AND visible='1'",$linkTBS)); echo ""; $linkno = (($link[2] * LINKS) > $counter ? $counter - ($link[2] - 1) * LINKS : LINKS); echo ""; echo ""; $start = ($link[2] - 1) * LINKS; $end = (($link[2] * LINKS) > $counter ? $counter - ($link[2] - 1) * LINKS : LINKS); $qry = "SELECT yourlink,website,description FROM linkshare WHERE type='{$catId}' AND visible='1' ORDER BY website ASC LIMIT ".$start.", ".$end; $rs = mysql_query($qry,$linkTBS) or die(mysql_error($linkTBS)); while($row = mysql_fetch_array($rs)) { $row = cleaner($row); echo ""; echo ""; echo ""; } mysql_free_result($rs); $next = $prev = $link[2]; echo ""; echo "
".ucfirst(urldecode($link[1]))." - {$link[2]} (".$linkno.")
 
{$row['website']}
{$row['description']}
 
<<< PREVIOUS PAGE | NEXT PAGE >>>
"; } ?>