Link to home
Start Free TrialLog in
Avatar of jeffmace
jeffmace

asked on

Help insert this HTML code into CFFORM

I am trying to learn how to use action script and CF FORMS, this is the first time I have been trying to use it.  Basically I am trying to load mp3 files dynamically.  Here is my code:

<cfquery name="x" datasource="jem_music">
SELECT * FROM Music
</cfquery>

<cfform format="Flash">
  <cfgrid name="UsersGrid" format="Flash" query="x" maxRows="5" rowheaders="Yes">
    <cfgridcolumn name="song" header="Song Title">
    <cfgridcolumn name="band" header="Group Name">
    <cfgridcolumn name="category" header="Category">
  </cfgrid>
  <cfformitem type="text" name="song" label="Song Name" bind="Song Title: {UsersGrid.dataProvider[UsersGrid.selectedIndex]['song']}">}"></cfformitem>
  <cfformitem type="text" name="band" label="Band" bind="Group Name: {UsersGrid.dataProvider[UsersGrid.selectedIndex]['band']}"></cfformitem>
  <cfformgroup type="horizontal">
  <cfformitem type="html" height="100" width="100" bind=""></cfformitem>
  </cfformgroup>
</cfform>

Basically all I want to do is load the "Wimpy Button" (which is a flash mp3 player) with a mp3 file dynamically from my database.  Here is the code they use

http://www.wimpyplayer.com/products/wimpy_button.html

      <!-- Start Wimpy Button Code -->
<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
 codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,47,0" name="wimpy_button01"
 WIDTH="40" HEIGHT="40" id="wimpy_button_1">
      <PARAM NAME=movie VALUE="wimpy_button.swf?theFile=example.mp3">
      <PARAM NAME=quality VALUE=high>
      <PARAM NAME=wmode VALUE=transparent>
      <EMBED src="wimpy_button.swf?theFile=example.mp3" WIDTH="40" HEIGHT="40" quality=high NAME="wimpy_button01"
 TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED>
</OBJECT>
<!-- End Wimpy Button Code -->

I have a column in my mySQL database called mp3 which has the file name like testfile.mp3, so I want to bind this flash code with the grid so that if i choose i different song with the grid it will change this line below to reflect what the new mp3 file name is:

<PARAM NAME=movie VALUE="wimpy_button.swf?theFile=example.mp3">



So to sum it all up, how can I include the mp3 button into my grid code so that I can play an MP3 file dynamically.


Thank you,
Jeff
ASKER CERTIFIED SOLUTION
Avatar of digicidal
digicidal
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial