Jump to content
php.lv forumi

embed


eT`

Recommended Posts

Tātad gribu embeddot klipus savā webā un gribu 2 dažādus veidus.

1. ja tu ieliec .flv linku ( video atskaņojas caur manu player.swf )

2. ja tu ieliec linku ( piem. no youtubes ), tad izpildās f-ja, kas pārveido linku par embed.

 

Man vajag pārbaudi, kas nosaka vai iepostototajā linkā ir .flv un ja ir tad attiecīgi atskaņo bet ja nav tad atskaņo kā linku.

 

Pašlaik esmu ticis šeit:

$code = $rowe["code"];
if(empty(strpos($code, ".flv")))
{
$video=new video_embed();
$video->embed($code);
}
else
{
?>
<embed type="application/x-shockwave-flash" src="include/player.swf" id="mpl" name="mpl" quality="high" allowfullscreen="true" flashvars="file=<?=$code?>&height=420&width=500&location=include/player.swf &showdigits=true&shownavigation=true&type=flv&usekeys=false" height="420" width="500">
<?
}

 

bet ar empty, nekas nenotiek.

kā var noteikt vai tur ir .flv?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...