Quote:
Originally Posted by manya1011 actually
It works sometimes not all of the time.. It will depend on how the websites have it setup.
It worked when it was just title as the address but when they had for example..
What : Something : The story
Something would show up and not story...
I think the code only Eliminates if they have it setup like Website name : the story..
so eliminates everything before the : |
Change the code to this so if the format is that or website name: page title it will work:
Code:
if(preg_match("'<title>([^<]*?)</title>'", $this->html, $matches)) {
$url_title=trim($matches[1]);
$url_title = preg_split("/:|\-/", $url_title);
$url_title = array_slice($url_title, -1);
$this->url_title = $url_title[0];
Geoserv.