Uridium Posted May 18, 2009 Posted May 18, 2009 Ive started a script which will allow staff to put up any type of video link from google, youtube and virtually any other kind of media that uses flash player. The prototype works fine for the admin section just a few editing Flash problems to overcome. Artist Name: Track Title: Alphabet Letter: SWF Link: Example http://www.domain.com/music/vplayer.swf PHP link: Example http://www.domain.com/music/flash.php?id= Allow Access: Default always Autostart Media: true or false Video ID Number: example 17635 Player Width: default 350 Player Height: default 400 Is how the staff menu is laid out havent started the user side yet but that wont take too long...... Quote
Uridium Posted May 18, 2009 Author Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game SQLS You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Call this file staff_videos.php You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Add these links to smenu Create New video Edit Exsisting video Delete video Open up global_func.php and add this You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
Uridium Posted May 18, 2009 Author Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game Ok so how does it work... All sites use either a sef link and or a php link both of which also use a unique ID for the track to be played... so For example.... if you want to play say Wonderwoman. (Bound to get some crap comments now lol) The url on youtube is...... You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. We need to extract a few parts from here example the link for swf would be the PHP link would be And the Video ID link number would be 1 to work on Youtube... for Jesusjones.com the link looks like You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. So the example would be SWF LINK = http://www.gamepapa.com/music/vplayer.swf PHP LINK = http://www.gamepapa.com/music/flash.php?id= Video Track ID = 186 Quote
Strats Posted May 18, 2009 Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game This looks nice, Will it slow a game down when loading the pages? Or be normal? Quote
Uridium Posted May 18, 2009 Author Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game Sorry found a typo on the SQLS change `videoIDlink` INT(11) NOT NULL default '186', to `videoidlink` INT(11) NOT NULL default '0', Quote
shrek1609 Posted May 18, 2009 Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game hi illusions i've been trying to work out a way to allow members to have you tube videos on their profiles by using BBCODE ie videoid i did post ages ago on here with regards to this but no one seemed to know how, this is a mod i would pay for if anyone would like to take it on board Quote
mikemastah Posted May 18, 2009 Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game hi illusions i've been trying to work out a way to allow members to have you tube videos on their profiles by using BBCODE ie videoid i did post ages ago on here with regards to this but no one seemed to know how, this is a mod i would pay for if anyone would like to take it on board you could probably do this very easily with preg_replace() Quote
Uridium Posted May 18, 2009 Author Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game Finally completed the user section..... call this files videos.php You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. And call this file playvideo.php You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Few Screenies From SELECT menu From Play Screen... TEST SITE http://www.mccode.doom-nights.com Look on left menu near bottom for Video Link. Quote
Haunted Dawg Posted May 18, 2009 Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game preg_replace('~(.?) ~is','<object>stuff here',$text); Quote
shrek1609 Posted May 18, 2009 Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game preg_replace('~(.?) ~is','<object>stuff here',$text); cheers Haunted but just cracked it, solution is one thread down from this :D managed to suss it out and inserted into existing bbcode Quote
Uridium Posted May 18, 2009 Author Posted May 18, 2009 Re: [mccodes V2] Add any type of video media to your game Media tested on phpmotion google youtube musicjesus myspace dailymotion All work perfectly Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game Liven it up a notch.. Quote
MyGunWars Posted May 19, 2009 Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game Nice Mod Man Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game You dont just have to use Video formats to work on this you can also Use mp3 wav midi even link to your own radio site if you have one it will play anything...... For MP3 media to work put the full URL for the track you want to play in both the SWF and the PHP link and set the ID number to 1...... Same applies for the Radio..... Quote
inferno564 Posted May 19, 2009 Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game i cant get it to add a video? Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game did you also ammend the SQL error i made... I did post the fix. Sorry found a typo on the SQLS change `videoIDlink` INT(11) NOT NULL default '186', to `videoidlink` INT(11) NOT NULL default '0', Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game To get videos to work breif guide When you goto youtube and open up a video link on the right there is an embed code.... <object width="560" height="340"><param name="movie" value=" "></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src=" " type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="560" height="340"></embed></object> you need to place this piece only into the SWF LINK and the PHP LINK Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game Quick Update..... When i Re-post the upgraded Mod... Users can Add, Edit their own Videos (Staff will still have power to remove any videos) And just so users dont go mental and start adding Millions od Videos they are set to only ADD 3 videos per week. Users can also save Videos to their Video Vault for easy access...... Also changed a few things on the Original script. Quote
inferno564 Posted May 19, 2009 Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game did you also ammend the SQL error i made... I did post the fix. Sorry found a typo on the SQLS change `videoIDlink` INT(11) NOT NULL default '186', to `videoidlink` INT(11) NOT NULL default '0', ya still wont work when you add a video and click [add video] it just refreshes the page :? Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game I'll repost my copy as ive made some amendements Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game one new SQL to add... ALTER TABLE videos ADD source VARCHAR (255) NOT NULL; Overwrite your staff_videos.php with this one You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Now over write your playvideo.php with this one You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. And upload this image Quote
b4ugobye Posted May 19, 2009 Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game same issue, fill in the information, click add, resets to blank form and nothing inserted into the sql. while trying to figure out why its not working, a couple things dont make sence in staff_videos.php.... shouldnt name be artist and title be tracktitle in the db query? Also I see a reference to ={$_POST['video']}"); in there and also in global func... is this a missing sql entry or am I missing something? Quote
Uridium Posted May 19, 2009 Author Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game Let me grab my copy off the FTP the one i posted is one from my PC i may have edited that before hand gizza sec. Quote
b4ugobye Posted May 19, 2009 Posted May 19, 2009 Re: [mccodes V2] Add any type of video media to your game I actually got one to work, maybe it was just the youtube video i was trying earlier wasnt compatible. Going to try a couple others and see what happens. Quote
Uridium Posted May 20, 2009 Author Posted May 20, 2009 Re: [mccodes V2] Add any type of video media to your game UPDATE TURN VIDEO PREVIEWING ON OR OFF + SEARCH FOR MEDIA This will allow your users to Turn off or on the video Preview mode which is seen from the videos.php screen SQL ALTER TABLE 'users' ADD 'preview' INT( 2 ) NOT NULL DEFAULT '0'; now open up preferences.php Add this with the rest of the LINKS.. You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. In the CASE section add You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. at the bottom of the page add You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. overwrite videos.php with this one... You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. And create a file called searchvideo.php You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
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.