Functionize some stuff

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18751 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Maurus Cuelenaere 2008-10-09 09:57:21 +00:00
parent 8c0b661d07
commit ae569c6f82
2 changed files with 17 additions and 38 deletions

View file

@ -334,4 +334,11 @@ function do_markup($data)
return $data;
}
function get_tpl_part($search, $haystack)
{
$tpl = array();
ereg($search[0].".*".$search[1], $haystack, $tpl);
return str_replace(array($search[0], $search[1]), "", $tpl[0]);
}
?>