note 20479 added to function.get-meta-tags

From: Date: Thu, 04 Apr 2002 20:38:11 +0000
Subject: note 20479 added to function.get-meta-tags
Groups: php.notes 
Request: Send a blank email to php-notes+get-28630@lists.php.net to get a copy of this message
If your metadata tags contain characters that PHP can't use in a named array they'll get converted to the underscore character. <meta name="geo.position" content="49.33;-86.59"> You can't get it using the tag's name as an array won't let you get [geo.position]. But it would let you get [geo_position] instead. Here's a page that shows what's returned: <? $url = "http://www.billsaysthis.com/"; $metatags = @get_meta_tags("$url",1); if (!$metatags) $metatags=@get_meta_tags("$url/",1); while (list($name, $contents) = each($metatags)) { echo "<b>$name</b> - $contents<br>"; } ?> -- http://www.php.net/manual/en/function.get-meta-tags.php http://master.php.net/manage/user-notes.php?action=edit+20479 http://master.php.net/manage/user-notes.php?action=delete+20479 http://master.php.net/manage/user-notes.php?action=reject+20479

« previous php.notes (#28630) next »