How to use ONE form but modify script to contain different videos (HTML object tags)

  • Profile Image
    xtasy171
    Asked on October 19, 2011 at 04:19 PM

    I am using a form to display a lightbox of an object.

     

    <p style="text-align: center;">

                  <object width="600" height="600" data="http://MYURL.com/file.swf">

                  </object>

                </p>

     

    I want to be able to use the same form and modify the content in the embed script so I can show a different object by changing the source.

    This way, I can post the form (lightbox) to different places, but just change the source line to show a different video and avoid making 100s of the same form for every video i want to show.

  • Profile Image
    Mike_T
    Answered on October 19, 2011 at 06:44 PM

    Thank you for contacting us.

    Unfortunately, we do not support such a feature. However, please note that we do allow unlimited number of forms per account. If you have some content on your form you may save a lot of time using Clone Existing Form feature. We hope for your understanding in this matter.

    Please feel free to contact us if you have any further questions.

  • Profile Image
    fxr
    Answered on October 19, 2011 at 06:58 PM

    I have had a little think about your options here:

    Is the form likely to be relatively static? i.e once done creating, are you unlikely to need to make changes to it?

    if so, you could download the source, place it on a php enabled server and embed your video url with some php.

    basic method:

    download the forms source files.

    Extract that zip file & upload the form & associated files to your server.

    Rename the .html file to .php. 

    edit your new .php file & change your embed line to look like this:

    <object width="600" height="600" data="<?php echo $_GET['video']; ?>">

     

    I have tested this and it does work. 

  • Profile Image
    xtasy171
    Answered on October 19, 2011 at 07:05 PM

    Thanks guys! 

     

    Yes I know i can have unlimited forms... its just a pain is all. though it could probably work.

    the PHP thing may be over my head but I can try it.

     

    how on earth did you pull the video example from my account? to be honest that's a breach of privacy I am a bit miffed about. i specifically omitted the actual video linkage as the video is property of my employing company.

  • Profile Image
    fxr
    Answered on October 19, 2011 at 07:12 PM

    Sorry. I had a quick look at your form, I needed something to base an example around. I just wanted to make sure this undocumented method would work.

    I left it in without thinking, I have removed the offending line. 

     

    My method only really calls for one line of php.