PDA

View Full Version : Meta Tags for new links,pop links


circlecity
04-11-2007, 02:15 PM
I noticed that my meta tags for description and keywords are blank for the
1. new links
2. popular links
3. top links
4. random links

Where do I input this info? some header file or something?


thank you

John Turner
04-12-2007, 10:54 AM
Hi Michael,

Here customization for you.

1. Open 'listings.php'

find following code

if($view == 'popular')
{
if(!$cached)
{
$listings = $Link->getPopular($start, $num_links, $gDirEditor['id']);
}
}
elseif($view == 'top')
{
if(!$cached)
{
$listings = $Link->getTop($start, $num_links, $gDirEditor['id']);
}
}
elseif($view == 'new')
{
$listings = $Link->getLatest($start, $num_links);
}
elseif($view == 'random')
{
$listings = $Link->getRandom($num_index);
}



replace with following code

if($view == 'popular')
{
if(!$cached)
{
$listings = $Link->getPopular($start, $num_links, $gDirEditor['id']);

$description = "popular links META description";
$keywords = "popular links META keywords";
}
}
elseif($view == 'top')
{
if(!$cached)
{
$listings = $Link->getTop($start, $num_links, $gDirEditor['id']);

$description = "top links META description";
$keywords = "top links META keywords";
}
}
elseif($view == 'new')
{
$listings = $Link->getLatest($start, $num_links);

$description = "new links META description";
$keywords = "new links META keywords";
}
elseif($view == 'random')
{
$listings = $Link->getRandom($num_index);

$description = "random links META description";
$keywords = "random links META keywords";
}

if(!$cached)
{
$gDirSmarty->assign_by_ref('description', $description);
$gDirSmarty->assign_by_ref('keywords', $keywords);
}


Thats all.
HTH