| | |
scanning files in a spec folder
Please support our JavaScript / DHTML / AJAX advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: May 2007
Posts: 2
Reputation:
Solved Threads: 0
Hi everyone
I'm more than a little stuck and would appreciate a hint. I'm struggling to read files in a folder and then pass the variable to the following:
</body>
<OBJECT ID="MediaPlayer" width=320 height=310 classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" type="application/x-oleobject">
<PARAM NAME="FileName" VALUE="video/RC Radio Controlled Model Airplane [from].wmv">
<PARAM NAME="AutoStart" Value="false">
<PARAM NAME="ShowControls" VALUE="true">
<PARAM NAME="ShowStatusBar" VALUE="false">
<PARAM NAME="Enabled" VALUE="true">
</OBJECT>
<FORM name="MediaForm">
<SELECT NAME="VidChange" onChange="{document.MediaPlayer.FileName = document.MediaForm.VidChange.options[document.MediaForm.VidChange.selectedIndex].value}">
<OPTION VALUE="video/RC Radio Controlled Model Airplane [from].wmv">RC radio plane flick
<OPTION VALUE="C:\Desktop special\leftmenu\video\intro.wmv">Intro
</SELECT>
Loop:
<INPUT TYPE="checkbox" NAME="VidRepeat" onClick="{if ( document.forms.MediaForm.VidRepeat.checked == true){document.MediaPlayer.PlayCount = 999}else {document.MediaPlayer.PlayCount = 1 }}">
</FORM>
</body>
I just learning scripting languages...really it's all new to me.
Thanks very much
Prophetboy
I'm more than a little stuck and would appreciate a hint. I'm struggling to read files in a folder and then pass the variable to the following:
</body>
<OBJECT ID="MediaPlayer" width=320 height=310 classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" type="application/x-oleobject">
<PARAM NAME="FileName" VALUE="video/RC Radio Controlled Model Airplane [from].wmv">
<PARAM NAME="AutoStart" Value="false">
<PARAM NAME="ShowControls" VALUE="true">
<PARAM NAME="ShowStatusBar" VALUE="false">
<PARAM NAME="Enabled" VALUE="true">
</OBJECT>
<FORM name="MediaForm">
<SELECT NAME="VidChange" onChange="{document.MediaPlayer.FileName = document.MediaForm.VidChange.options[document.MediaForm.VidChange.selectedIndex].value}">
<OPTION VALUE="video/RC Radio Controlled Model Airplane [from].wmv">RC radio plane flick
<OPTION VALUE="C:\Desktop special\leftmenu\video\intro.wmv">Intro
</SELECT>
Loop:
<INPUT TYPE="checkbox" NAME="VidRepeat" onClick="{if ( document.forms.MediaForm.VidRepeat.checked == true){document.MediaPlayer.PlayCount = 999}else {document.MediaPlayer.PlayCount = 1 }}">
</FORM>
</body>
I just learning scripting languages...really it's all new to me.
Thanks very much
Prophetboy
You can't do this with a HTML scripting language.
If you use a server side language - something like JSP, ASP, PHP etc, then you can scan the server directories and populate a list in the webpage.
Also, remember to use web URL paths and not filesystem paths:
These will work when you are testing on your computer at home, but not when you publish to the web.
Cheers.
If you use a server side language - something like JSP, ASP, PHP etc, then you can scan the server directories and populate a list in the webpage.
Also, remember to use web URL paths and not filesystem paths:
•
•
•
•
C:\Desktop special\leftmenu\video\intro.wmv
Cheers.
•
•
Join Date: May 2007
Posts: 2
Reputation:
Solved Threads: 0
Thanks for replying but I think I stated my intentions poorly. What I want to do is scan a folder for specific files (on my own computer) and then put them in a list box as a selection. I'm putting this page on my desktop as a web page. I'm trying to use a scripting language such as JavaScript to read the files from a selection.
I tried to use this to read a fold but I couldn't get it to work for me.
http://www.codeproject.com/jscript/RenameAllFiles.asp
The next is a copy of the original project I found and was endeavoring to change.
http://www.codeproject.com/jscript/leftmenu.asp
you will see on the left menu there are selections. I want to be able to select one and have a media play show a list box show the videos in the folder.
Right now I live in China and can't run to the store to buy English books and I've looked on the net but I'm not having a lot of luck finding the material.
can you help
Chad
I tried to use this to read a fold but I couldn't get it to work for me.
http://www.codeproject.com/jscript/RenameAllFiles.asp
The next is a copy of the original project I found and was endeavoring to change.
http://www.codeproject.com/jscript/leftmenu.asp
you will see on the left menu there are selections. I want to be able to select one and have a media play show a list box show the videos in the folder.
Right now I live in China and can't run to the store to buy English books and I've looked on the net but I'm not having a lot of luck finding the material.
can you help
Chad
It is possible to run applications on the client machine, but this is usually not appreciated by the user and involves signing trusted code.
A better alternative may be to request the client user to browse their computer for a file they want to load.
Unless this is only meant to be for your use.
A better alternative may be to request the client user to browse their computer for a file they want to load.
Unless this is only meant to be for your use.
![]() |
Similar Threads
- Scanning of files (C#)
- windows restarts cant delete files in temp folder (Viruses, Spyware and other Nasties)
- Cant upload dreamweaver "files folder" to site (Networking Hardware Configuration)
- System 32 Folder (Windows 95 / 98 / Me)
Other Threads in the JavaScript / DHTML / AJAX Forum
- Previous Thread: Falling leaves script
- Next Thread: javascript code
| Thread Tools | Search this Thread |
ajax ajaxcode ajaxexample ajaxhelp ajaxjspservlets animate automatically beta box browser bug calendar captchaformproblem checkbox child class close column createrange() css cursor date debugger dependent disablefirebug dom download dropdown editor element embed engine error events explorer ext file form forms getselection google gwt gxt hiddenvalue highlightedword hint html htmlform ie7 ie8 iframe images internet java javascript javascripthelp2020 jawascriptruntimeerror jquery jsf jsfile jump libcurl math media microsoft mimic object onmouseoutdivproblem onreadystatechange parent paypal pdf php player position post problem programming progressbar regex runtime scroll search security select shopping size software sql text textarea unicode w3c web website window windowofwords windowsxp wysiwyg \n






