cheat Posted June 21, 2007 Share Posted June 21, 2007 ok i want to add a youtube bbcode to my online game to allow players to embed youtube into their profiles using video id so i need to convert this to work as the above bbcode <object width="425" height="350"><param name="movie" value="http://www.youtube.com/watch?v=YEfKdjOjqso"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/watch?v=YEfKdjOjqso" type="application/x-shockwave-flash" wmode="transparent" width="425" height="350"></embed></object> thats just a example embed. ive tried several different ways of doing this, any ideas? Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/ Share on other sites More sharing options...
redarrow Posted June 21, 2007 Share Posted June 21, 2007 I dont think it possable to play a utube movie via your website under your own player. i recomend you get the users recommended movies but that it sorry. Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/#findComment-279153 Share on other sites More sharing options...
cheat Posted June 21, 2007 Author Share Posted June 21, 2007 i know for certain that it can be done $txt = preg_replace("=\[youtube\]\s?\n?\r?(.*?)\[/youtube\]=is", '<embed src="">\1</embed>', $txt); i was given that code and told to edit it but ive never made a bb code for anything like this before anyone that could help it would be greatly appreciated. Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/#findComment-279155 Share on other sites More sharing options...
redarrow Posted June 21, 2007 Share Posted June 21, 2007 do you mean you want the entred link formatted to a ceton condition. Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/#findComment-279157 Share on other sites More sharing options...
cheat Posted June 21, 2007 Author Share Posted June 21, 2007 ok on youtube when you view a video you are given two links on the right 1) is the unique id link for that video 2) the html embed code for that video now what i want to do is make it so that a player can usethe video unique link here i know it can be done as ive seen it done. ive tried it serveral different ways but it wont work, Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/#findComment-279159 Share on other sites More sharing options...
Henaro Posted June 21, 2007 Share Posted June 21, 2007 Can I refer you here? http://www.phpfreaks.com/forums/index.php/topic,145449.msg622255.html Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/#findComment-279160 Share on other sites More sharing options...
cheat Posted June 21, 2007 Author Share Posted June 21, 2007 that doesnt work Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/#findComment-279166 Share on other sites More sharing options...
Henaro Posted June 21, 2007 Share Posted June 21, 2007 It does now. Quote Link to comment https://forums.phpfreaks.com/topic/56521-youtube-bbcode/#findComment-279455 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.