|
upload
Feb 1, 2008 1:33:29 GMT -5
Post by knoware on Feb 1, 2008 1:33:29 GMT -5
I have a file maintenance. As usual it has 2 options. 1. You can accept your changes 2. You can exit without changes Part of the maintenance is the option to do a UPLOAD if you want to add a photo. However the 2 links do not work with the UPLOAD option. Selecting either link automatically goes all the way back to the Run Basic login screen. If I take the UPLOAD command out of the maintenance the links work.
I need the UPLOAD option as part of the maintenance.
How do I do this??
Thanks for the help.
|
|
|
upload
Feb 1, 2008 3:51:58 GMT -5
Post by StefanPendl on Feb 1, 2008 3:51:58 GMT -5
Can you post an example of what you are doing If you create a sample that includes only two links and the upload, does it still crash If this is not the case, the problem is somewhere else.
|
|
|
upload
Feb 1, 2008 5:06:10 GMT -5
Post by mikeukmid on Feb 1, 2008 5:06:10 GMT -5
Have you seen the bug report for Upload? That is exactly how I discovered that Upload has no escape from an empty string. Maybe that is causing your problem.
Mike
|
|
|
upload
Feb 1, 2008 6:58:27 GMT -5
Post by knoware on Feb 1, 2008 6:58:27 GMT -5
Ok - Reduced it as much as possible. Basically is shows the master and the old photo. Every time you UPLOAD a new photo it re-displays the master, the old photo, and the new photo. If you click the test link it goes to the login.
[shoMedia] cls mediaName$ = "Im here" textbox #mediaName, mediaName$
' ------------------------------------ ' Midea Displa Current and New upload ' ------------------------------------ if mediaID$ <> "" then html "<img src='"+mediaUrl$+mediaId$+"' width=100% border=1>" else print "" html "No Old Photo" end if
if newMediaId$ <> "" then html "<img src='" + uploadPath$ + newMediaId$ + "' width=100% border=1>" else print "" html "No New Photo" end if print " " link #ac, "Test", [mediaMastAC] key$ = mediaId$ #ac setkey(key$)
preUpload$ = newMediaId$ ' ------------------------------------------ ' Upload New mediafile ' jpg, wmv, wmu ' ------------------------------------------ upload "Select a file to upload."; newMediaId$ loadPath$ = "public\uploads\"
' Kill previous upload if preUpload$ <> "" then kill loadPath$ + preUpload$
if newMediaId$ <> "" then open newMediaId$ for binary as #f filedata$ = input$(#f, LOF(#f)) close #f open loadPath$ + newMediaId$ for binary as #g print #g, filedata$ close #g 'delete uploaded newMediaId from root directory kill newMediaId$ end if
goto [shoMedia] wait
[mediaMastAC] print "Happy end" wait
|
Thanks for the help
|
|
|
upload
Feb 1, 2008 10:02:42 GMT -5
Post by mikeukmid on Feb 1, 2008 10:02:42 GMT -5
Looks like an old bug resurfaced to me, when I run your code in IE7 and click the test link it takes me to the login page, but if you click the browser backbutton your program is still running and you can continue to upload.
However, it works OK in Firefox.
One for Carl ..... ?
|
|
|
upload
Feb 1, 2008 10:19:40 GMT -5
Post by knoware on Feb 1, 2008 10:19:40 GMT -5
Ok! Sounds good to me. I don't have IE on my computer. But for some reason had an old version of Opera hanging around, and that is where Run Basic Launched. Otherwise I always use FF.
I killed Opera, now when I click [launch in Browser] it does nothing!! So being new to all this - How do I get it to launch in FireFox.
Thanks for the help.
|
|
|
upload
Feb 1, 2008 11:12:42 GMT -5
Post by StefanPendl on Feb 1, 2008 11:12:42 GMT -5
I killed Opera, now when I click [launch in Browser] it does nothing!! So being new to all this - How do I get it to launch in FireFox. On the General page of the Firefox settings, you can check, if it is set as the default browser.
|
|
|
upload
Feb 1, 2008 11:44:28 GMT -5
Post by knoware on Feb 1, 2008 11:44:28 GMT -5
Yep! That was it. I was looking all over for a setup file.
I'm on my way..
Thanks for all the help..
|
|
|
upload
Feb 1, 2008 12:56:28 GMT -5
Post by carlgundel on Feb 1, 2008 12:56:28 GMT -5
Looks like an old bug resurfaced to me, when I run your code in IE7 and click the test link it takes me to the login page, but if you click the browser backbutton your program is still running and you can continue to upload. However, it works OK in Firefox. One for Carl ..... ? Very strange. I'll probably be able to make it work in IE. We'll see. -Carl
|
|