function emaudio_odeo_extract in Embedded Media Field 5
Same name and namespace in other branches
- 6.3 contrib/emaudio/providers/odeo.inc \emaudio_odeo_extract()
- 6 contrib/emaudio/providers/odeo.inc \emaudio_odeo_extract()
Implementation of hook emaudio_odeo_extract(). This is called to extract the video code from a pasted URL or embed code.
Parameters
$embed an optional string with the pasted URL or embed code.:
Return value
either an array of regex expressions to be tested, or a string with the audio code to be used. If the hook tests the code itself, it should return either the string of the audio code (if matched), or an empty array. Otherwise, the calling function will handle testing the embed code against each regex string in the returned array.
File
- contrib/
emaudio/ providers/ odeo.inc, line 49
Code
function emaudio_odeo_extract($embed = '') {
return array(
'@odeo\\.com/audio/([0-9]+)/@i',
'@href="http://odeo.com/audio/([0-9]+)/@i',
);
}