By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,384 Members | 1,886 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,384 IT Pros & Developers. It's quick & easy.

Slideshow

P: n/a
I want to create a web-based slideshow where it'll hunt through all
the jpg files I put in a folder, irrespective of name or how many, and
cycle through them, one by one.
This would mean that whenever I have new pictures, I just upload
them, and they are automatically part of the slideshow merely by being
in the folder, without updating my code.
The problem, I think, is the security aspect of the web based utility
not having permission to look at files in one of its folders unless
they are named

Is this possible?
If not Javascript, what other language?
(I don't want the viewer to have to deliberately accept an activex
control, which seems one way I could make it work)

....I can dabble in a few languages, not great at any, but grateful for
a pointer in the right direction, if it's possible.

Cheers

Tont

Is it possible to set
Jul 20 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
try www.dynamicdrive.com

"TonyJeffs" <to*******@aol.com> a écrit dans le message de
news:8e**************************@posting.google.c om...
I want to create a web-based slideshow where it'll hunt through all
the jpg files I put in a folder, irrespective of name or how many, and
cycle through them, one by one.
This would mean that whenever I have new pictures, I just upload
them, and they are automatically part of the slideshow merely by being
in the folder, without updating my code.
The problem, I think, is the security aspect of the web based utility
not having permission to look at files in one of its folders unless
they are named

Is this possible?
If not Javascript, what other language?
(I don't want the viewer to have to deliberately accept an activex
control, which seems one way I could make it work)

...I can dabble in a few languages, not great at any, but grateful for
a pointer in the right direction, if it's possible.

Cheers

Tont

Is it possible to set

Jul 20 '05 #2

P: n/a
For managing files you automatically upload on a server, you should do it on
the server side.
It can be done in ASP or PHP. don't know with javascript....

Let me get the script on ASP and I'll send it to you.

BoB

"TonyJeffs" <to*******@aol.com> a écrit dans le message de
news:8e**************************@posting.google.c om...
I want to create a web-based slideshow where it'll hunt through all
the jpg files I put in a folder, irrespective of name or how many, and
cycle through them, one by one.
This would mean that whenever I have new pictures, I just upload
them, and they are automatically part of the slideshow merely by being
in the folder, without updating my code.
The problem, I think, is the security aspect of the web based utility
not having permission to look at files in one of its folders unless
they are named

Is this possible?
If not Javascript, what other language?
(I don't want the viewer to have to deliberately accept an activex
control, which seems one way I could make it work)

...I can dabble in a few languages, not great at any, but grateful for
a pointer in the right direction, if it's possible.

Cheers

Tont

Is it possible to set

Jul 20 '05 #3

P: n/a
Here is the code for getting all files from a directory automatically. In my
case, I do show all thumbnails images with a link to bigger images. You may
change it for your needs. hope this helps.

<%
Dim objFSO
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")

'Get the folder object associated with the directory
Dim objFolder
Set objFolder =
objFSO.GetFolder(Server.MapPath("../images/photogallery/thumbnails"))

'Loop through the Files collection
Dim objFile
For Each objFile in objFolder.Files
Response.Write "<div align=""center"">"
Response.Write "<a href=""../images/photogallery/images/"+objFile.Name+"""
onClick=""return
enlarge('../images/photogallery/images/"+objFile.Name+"',event)"">"
Response.Write "<img
src=""../images/photogallery/thumbnails/"+objFile.Name+"""
alt="""+objFile.Name+""" align=""bottom"" border=""1""><br>"
Response.Write "<br><br><br></a></div>"
Next

'Clean up!
Set objFolder = Nothing
Set objFile = Nothing
Set objFSO = Nothing
%>
"Bob Bedford" <be******@YouKnowWhatToDohotmail.com> a écrit dans le message
de news:3f*********************@news.sunrise.ch...
For managing files you automatically upload on a server, you should do it on the server side.
It can be done in ASP or PHP. don't know with javascript....

Let me get the script on ASP and I'll send it to you.

BoB

"TonyJeffs" <to*******@aol.com> a écrit dans le message de
news:8e**************************@posting.google.c om...
I want to create a web-based slideshow where it'll hunt through all
the jpg files I put in a folder, irrespective of name or how many, and
cycle through them, one by one.
This would mean that whenever I have new pictures, I just upload
them, and they are automatically part of the slideshow merely by being
in the folder, without updating my code.
The problem, I think, is the security aspect of the web based utility
not having permission to look at files in one of its folders unless
they are named

Is this possible?
If not Javascript, what other language?
(I don't want the viewer to have to deliberately accept an activex
control, which seems one way I could make it work)

...I can dabble in a few languages, not great at any, but grateful for
a pointer in the right direction, if it's possible.

Cheers

Tont

Is it possible to set


Jul 20 '05 #4

P: n/a
Hi,

TonyJeffs wrote:
I want to create a web-based slideshow where it'll hunt through all
the jpg files I put in a folder, irrespective of name or how many, and
cycle through them, one by one.
This would mean that whenever I have new pictures, I just upload
them, and they are automatically part of the slideshow merely by being
in the folder, without updating my code.
The problem, I think, is the security aspect of the web based utility
not having permission to look at files in one of its folders unless
they are named

Is this possible?
If not Javascript, what other language?
(I don't want the viewer to have to deliberately accept an activex
control, which seems one way I could make it work)

...I can dabble in a few languages, not great at any, but grateful for
a pointer in the right direction, if it's possible.

Cheers

Tont

Is it possible to set


This is exactly what I use WebLoadFile for:

http://www.galasoft-LB.ch/myjava/Web...Demo/Demo.html

Laurent
--
Laurent Bugnion, GalaSoft
Webdesign, Java, javascript: http://www.galasoft-LB.ch
Private/Malaysia: http://mypage.bluewin.ch/lbugnion
Support children in Calcutta: http://www.calcutta-espoir.ch

Jul 20 '05 #5

P: n/a
TonyJeffs hu kiteb:
I want to create a web-based slideshow where it'll hunt through all
the jpg files I put in a folder, irrespective of name or how many, and
cycle through them, one by one.
This would mean that whenever I have new pictures, I just upload
them, and they are automatically part of the slideshow merely by being
in the folder, without updating my code.
The problem, I think, is the security aspect of the web based utility
not having permission to look at files in one of its folders unless
they are named

Is this possible?
If not Javascript, what other language?
(I don't want the viewer to have to deliberately accept an activex
control, which seems one way I could make it work)


NOt tested, definately in need of further work, but...

var i = 0
while (i != NaN) {
preload[i] = new Image();
preload[i].src = i + ".gif";
// test for undefined somehow
if (preload[i].src is undefined) { i = "a"; }
else { i = i + 1; }
}

You'd still need to number your files sequentially with this of course.

--
--
Fabian
Visit my website often and for long periods!
http://www.lajzar.co.uk

Jul 20 '05 #6

P: n/a
JRS: In article <bq*************@ID-174912.news.uni-berlin.de>, seen in
news:comp.lang.javascript, Fabian <la****@hotmail.com> posted at Fri, 5
Dec 2003 06:42:23 :-

NOt tested, definately in need of further work, but...

var i = 0
while (i != NaN) {
preload[i] = new Image();
preload[i].src = i + ".gif";
// test for undefined somehow
if (preload[i].src is undefined) { i = "a"; }
else { i = i + 1; }
}

You'd still need to number your files sequentially with this of course.


IIRC, NaN is never equal to anything, not even another NaN or a copy of
itself. Moreover, a NaN is neither greater nor smaller than anything
else.

Better to use while (OK) { or do {...} while (OK) and compute
OK in the loop.

Consider

for (i=0;;i++) {
...
if (...) break
}

--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 MIME. ©
Web <URL:http://www.merlyn.demon.co.uk/> - FAQish topics, acronyms, & links.
Proper <= 4-line sig. separator as above, a line exactly "-- " (SonOfRFC1036)
Do not Mail News to me. Before a reply, quote with ">" or "> " (SonOfRFC1036)
Jul 20 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.