Portal Home > Knowledgebase > Articles Database > Adding text and integer to switch($cat)


Adding text and integer to switch($cat)




Posted by bambinou, 07-25-2010, 01:32 PM
Hello, I have this code here: At the moment this code check for numbers in my url and then change the title tag to the given $title above. If let's says my site has a page called: http://www.mysite.com/1 or http://www.mysite.com/2 then the $title will add the required title tag. I now have a problem, some of my pages do not always end with a number but a word, for a example: http://www.mysite.com/download.html I would like to associate an $title to each URL finishing with a word. For example, if I have a url like the one above i would like to add this in the $cat = (int) $cat; case download.html: $title = 'this is the page title 2'; break; How to do this please? Thank you, Ben



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read
Optimize Mysql Table (Views: 343)
PuTTY Question (Views: 387)