inv Posted February 23, 2005 Share Posted February 23, 2005 I am trying to have a customized title to when somebody is in the main entrance of my website. So far I have this <?php echo '<title>' . 'Johns Tools' . ' - ' . $breadcrumb->trail_simple(' » ') . '</title>';?> The problem is that when I am at the main domain section (www.domain.com) the title is Johns Tools - - as the - are from bread crums... how do i make it so that when on www.domain.com it desplays 1 title else when its in the other sections it uses bread crums.. thanks Link to comment Share on other sites More sharing options...
Guest Posted February 23, 2005 Share Posted February 23, 2005 Try: <title><?php echo TITLE . ' ' . strip_tags($breadcrumb->trail(' » ')); ?></title> Link to comment Share on other sites More sharing options...
inv Posted February 24, 2005 Author Share Posted February 24, 2005 I still want the "-" apear when its in subcategories. Basicly I need this if url is the main URL of the site (eg. johnstools.com, www.johnstools.com, johnstools.com/index.php, www.johnstools.com/index.php) I want the TITLE to be JOHNS TOOLS else if the url is johnstools.com/index.php/c_101 I want it to write <?php echo '<title>' . 'Johns Tools' . ' - ' . $breadcrumb->trail_simple(' » ') . '</title>';?> Link to comment Share on other sites More sharing options...
inv Posted February 24, 2005 Author Share Posted February 24, 2005 anyone? Link to comment Share on other sites More sharing options...
inv Posted February 24, 2005 Author Share Posted February 24, 2005 Try #2 How about having a title desplay 1 thing when its on the main page eg. WELCOME TO MY WEBSITE and when its not on the main page anymore use the bread crum + sitename eg. Johns Tools - Hammers - Sledge Link to comment Share on other sites More sharing options...
boxtel Posted February 24, 2005 Share Posted February 24, 2005 Try #2 How about having a title desplay 1 thing when its on the main page eg. WELCOME TO MY WEBSITE and when its not on the main page anymore use the bread crum + sitename eg. Johns Tools - Hammers - Sledge <{POST_SNAPBACK}> I use this : <?php if (isset($cPath) && tep_not_null($cPath)) { echo '<title>' . $breadcrumb->trail_simple(' » ') . ' @ ' . TITLE . '</title>'; } else { echo "<title>" . TITLE . "</title>"; } Treasurer MFC Link to comment Share on other sites More sharing options...
inv Posted February 24, 2005 Author Share Posted February 24, 2005 Perfect :) Your a life saver. Thank you Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.