-
☆ A M B ☆
- 24,524 Posts
Try /assets/flash/Promo.flv without the leading ..
Thanks for the response and I did try various configurations of ../ or / etc
I changed the .flv to just a simple .jpg so --> @FILE /assets/flash/intro.jpg and this is the response back on the page Could not retrieve document ’/assets/flash/intro.jpg’
I note the quotes is this I wonder something to do with magic quotes a problem I have had with permissions in the past?
Further Edit- Have tried this on another server that does not have any magic quotes issue and the same occurs
Try removing that leading slash before assets, i.e.
/assets/flash/Promo.flv should be assets/flash/Promo.flv
-
☆ A M B ☆
- 24,524 Posts
Sorry, I was half-asleep when responding. @FILE returns the contents of the specified file using fgets(). All you want is the filename itself. That’s what a file input type TV produces; just the filename with path, not the contents of the file. Your default value should just be the filename, no @FILE.
-
☆ A M B ☆
- 24,524 Posts
You do NOT want to use the @FILE binding here. All you want the TV to return is the file’s path. @FILE binding returns the contents of the file. If it were a text file containing the text "Now is the time for all good men to come to the aid of their party", that text is what would be inserted into the page. What you want is the file’s path to be inserted into the page so the player can load it. By using @FILE what you are doing is telling the TV to open the file and insert the file’s contents into the page! The browser won’t like that at all.
-
☆ A M B ☆
- 24,524 Posts
I presume you want different files played for different pages? If that is correct, then the TV should be a file type (unfortunately there is no "video" type that would access the assets/flash folder), and the default should just be the path to the default video to play if nothing else is selected. The TV would return the path to the file. You may need to add parts of the path in the HTML code for the player if the relative path provided by the TV isn’t acceptable to it. Sometimes those can be a real pain figuring out just what kind of a path they want.
What I did for one site that I wanted to do this with (using Flowplayer) was to name the files after the page alias, and used a snippet to check if such a file did exist and to return the default file’s name if there wasn’t one. The code in the chunk had most of the path, just the filename part was provided by the return value of the snippet.
If you are selecting between a set number of video files, you could use a radio button with again just the file name being supplied by the TV, and the default value being the filename of the default video. Again, most of the path would be in the chunk containing the player code, the TV would only supply the name part of the file.