I have a page that displays all movie of various cat. and i designed it to help people in my community click any old movie want to watch and it will send it through a URL parameter to the view video page. So any movie clicked is filtered on the playvideo.cfm page for viewing. It makes possible for only one movie to watched at a time.

One i use the single path link without database it works, but with database dynamic link, it wont play.

Here is the code to the request page (1)

1) movie displayed page (basic.cfm)

<td height="33" colspan="3" class="yellowish_green"><a href="/@unicast/movies/playmovie_db.cfm?MediaID=<cfoutput>#rsMovies.MediaID#</cfoutput>"><strong><cfoutput>#rsMovies.Title#</cfoutput></strong></a></td>

Here is the code to the embed Window Media Player from through the URL request from database(2)

2) video view page (playmovie.cfm)

DATABASE TABLE STRUCTURE

<cfparam name="URL.MediaID" default="0">
<cfquery name="rsMovies" datasource="#Request.DSN#">
SELECT MediaID, CatID, SubCat, Title, FileName, FileImg, DateReleased, "Cast", Director, Translator, AudioRating, AudioFM, VideoFM, "Language", Length, Awards, RatingID, AgeRating, Features, AddOnline
FROM media
WHERE MediaID = <cfqueryparam value="#URL.MediaID#" cfsqltype="cf_sql_bit">
</cfquery>

EMBEDDED WMPLAYER WITH URL REQUEST FROM DATABASE

<object
classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95' data="<cfoutput>#rsMovies.FileName#</cfoutput>"' type='application/x-oleobject' name="mediaPlayer" width="676" height="500" id='mediaPlayer'
components...>
<param name='animationatStart' value='true' />
<param name='transparentatStart' value='true' />
<param name='autoStart' value="false" />
<param name='showControls' value="true" />
<param name='loop' value="true" />
<param name="fullscreen" value="true" />
<embed
src="<cfoutput>#rsMovies.FileName#</cfoutput>"

width="676" height="500"

autostart="false" loop="true" type='application/x-mplayer2'


pluginspage='http://microsoft.com/windows/mediaplayer/en/downl

oad/'
id='mediaPlayer' name='mediaPlayer' displaysize='4'

autosize='-1'
bgcolor='darkblue' showcontrols="true" showtracker='-1'
showdisplay='0' showstatusbar='-1' videoborder3d='-1' designtimesp='5311' animationatstart="true" transparentatstart="true" fullscreen="true" mediaid="<cfoutput>#rsMovies.MediaID#</cfoutput>"> </embed>
</object>

One i use the single path link without database it works, but with database dynamic link, it wont play.

You mean it works with a hard coded path but not when you use variables? Do a view source and look at the html generated. Compare it to the hard-coded-working version and see how it differs.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.