Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Script needed... A challenge for you?

Status
Not open for further replies.

oldnewbie

Technical User
Dec 6, 2000
9,142
CA
Hi all:

I'm but an occasional user of javascript, but as I try to help others on the Flash forum... Hope somebody can come to my rescue on this one.

I've been desperately trying to force a download on an embedded Real or WindowsMedia player... but to no avail, whatever I do, they both desperately try to stream the file. Being stuck, as a lot of users still, with a 56k connection, I for one, prefer waiting for the file to download and viewing it with a minimal picture quality ( I purposely encode my files at a higher bitrate than a 56k connection would support), than suffer a pixalating, breaking-up and stopping for rebuffering presentation. Real says I'm trying to defeat the technology! I'm not! I'm just trying to use it in another way, benefiting from the reduced file size of thoses encoded files, and by downloading, insuring that minimum picture quality for slow connected users, since after the download of the file, it should be considered as a local file for the players.

So here's the javascript stuff...
On a button or a link clik, this function would offer the user a download possibility. I doubt it can force it to download to Windows' temporary internet cache (which would be the ideal), but assuming it could open the default downloading application it would then, once the download was completed, have to retreive the path of that saved file, so that I can handle it back to the player. Bingo! After the download, the file would play! Doesn't seem really complicated to me... but as I've said, javascript is definately not one of my trades!

So! All you javascript freaks (to me the term is not pejorative but indicates determination...), to your drawing boards! I'm wasted... I'm in a holding pattern and running out of gas!

Any help or comments greatly appreciated!

Thanks,
François Gill ;-)
Montréal, Canada
 
Perhaps you can zip up the files and the browser will automatically download them and let the user unzip them. Other than that, this may require a server side script. I have seen it done in Perl. You can check out and search in the back orders for a article about how to do it with zip files.

Hope this helps,

-Vic vic cherubini
vikter@epicsoftware.com
====
Knows: Perl, HTML, JavScript, C/C++, PHP, Flash, Director
====
 
Thanks! Thought of that! But that's fairly complicated for unfamiliar computer users... download, unzip, find the right file, double-click... Etc... Etc. Furthermore that would open up a popup player and probably not the embedded one!
Looking for something more in this style:

... In easier terms... And them automatically retrieving the path and passing it on to the embedded player.

Anybody else?

;-)
 
it looks impossible in javascript only :-(
-> if the file is automatically played, it's because of the file association on the CLIENT side, this means you'll have to manipulate users registry (if they use windows ....)
-> if the file is not proposed for download, it's because the WEB SERVER knows its extension, that means some server manipulation (if you can access your web server ...)
-> to retrieve the path requires ??? i don't know !! but i don't think javascript is powerful enough :-(
------
so i don't think it's feasible in jscript only - unless you use vic's trick ...
 
Yes ,I agree with iza , its associated with the file types and you can force in the client side to open up the download box by unchecking the "quick view option" and checking the "confirm after download".

You can get this options

By clicking windows explorer tool bar and then click view you will see folder option click that and then click the file types search for the extension you wish to force the
download prompt box.(save to disk)and click edit button.

I don't know how this can be done automatically in javascript.

I think we need a more stronger client side javascript.

:)
 
Sorry for bringing this one back up... It's getting lost down there!

;-)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top