Is there anyone who knows how to prevent file overwriting using aspSmartUpload?From what I have read there is no function that disables this. And I have tried different other solutions but nothing seems to work.
Have a input type file where a user can select a file. Then when the user uploads the file I want an error message to be displayed if the file name already exist on the server before the file is uploaded. I have already tried differetn file comparions functions,but no one works with the aspSMartUpload script, it automaticaly gives an error everytime i use Request.Form.
The scenario is that I need to save the file names of images that people uploaded. If the image file already exists, it should be overwritten with the new image. I got the code from one of the forum posted by freeasphelp.
I am using ASPSmartUpload to move file from user computer to web server through company network. If the file is small (<1 MB), everything is fine. But if file is big (more than 50 MB) it will stay forever. Does anyone know in this situation, which component you recommend.
I want to upload images from people and save the name of the files in a database so I can later populate from there. The uploading part is working fine, except that when I use SaveAs, if the file exist it rewrites the existing file...
I did do a search in the forums and tried to use a code that memnoch posted but it wont work since the aspsmartupload objetc doesnt support the FileExist Method... the code from Memnoch that i tried to use is the following: Code:
Currently i am doing a file management project where user are able to create folder and upload files to it. The file ownner would be able to set permission (from database linking to the file path) if a user able to download it or not.
*each file info will be stored into a table e.g. fileid, filename, path, access.
Now i am facing a problem where if a user does not have permission to click on the link to download, the user can guess the path and the file name and directly type the path on the address bar to download the file.
We have offer a web space to hosting our client website. We offer them to upload asp files to their web space. How can I prevent the client from uploading asp files that will harm our web server.
For example, deleting files in our server using Scripting.FileSystemObject to delete our systemmfiles.
Does anyone know what sort of command I need to use so that if someone posts an entry to my database with a primary key that's already been used, the old entry is overwritten by the new one
I am using AspSmartUpload component in my project. In one of my forms there are one file field, checkbox and textbox. I need to save the file in the webserver directory by changing filename and then i need to store these values(new filename, textbox value and checkbox value) into database.
please dont give advices search it in google.co.in. I have tried alot. I could not find required code for this.
I'm using ASPSmartUpLoad free component in order to upload files in a browser based way, but I would like to add a Progress Bar to my page during the big files uploading, I mean something like the small html windows that appear when you are "downloading" any file. Please, Does anyone could indicate me a way or idea about to do this?
I know what the error means and everything, but I can't seem to fix it. I've read the FAQ and Setup but they don't seem to help. I tried both copying the DLL to system32 and I also tried modifying the PATH with the instructions they give, but I still get the error. I know it gets annoying to have people say it, but this is urgent. Code:
I am using aspsmartupload and I can upload fine but I am trying to validate the file extension before it is uploaded. I know you cannot use request and you can get the file name and extension after it has been uploaded but I need to get the file extension before the upload takes place.
i am having a upload script which is giving internal server error. I am using ASPSmartupload and my server is windows2003. The code which i am using is working fine in windows XP dev mechine but not working in windows 2k3. Is there is anyone who can help me in sorting out the error. The error given is internal server error. I can't able to trap that also. It is calling some http_500.html i don't remember exactly. But it is internal server error.
I have aspsmartuplod component on my server. I have from of information with attachment field. I success to upload file on server with that form but i want that upload file will come at my end as mail with attachement.
I tried at my end but not find any code. Can any one help me to get that code. I want user infromation and his uploaded file through mail.
I am a webdesigner.We have recently taken over a site created in ASP. The site remains on the original server, but my company does the updates on the site.I do not touch the ASP at all, as I not familiar with it other then I know ASP automatically becomes html when you view it from the browser and u can save the file from there.Anyways, I edit the pages as required, new text, new photos, new links, and create new pages (any new pages I create in html if not tied to the database). I save the pages with a .asp extension and upload. This does not seem to mess anything up. The person who hosts the site, is upset that someone else is editing the site, so he's really not easy to work with. Anyways, after uploading files, everything works fine, and then a day later, all of a sudden, any .ASP pgs you click on give the following error or similar pasted below. What I'd like to know is if these errors are because of me..and if so, how do I prevent it.
I've got an intranet application that presents a list of files in sort of a 'central repository' web page. Each file is an href in the form <a href=file://server/share/path/filename.ext>.
When the user clicks on an excel file,it is opening within the browser,which unforntuntely confuses the heck out of them because the usual Print/Print Preview menu options are not available. I would like the user to be presented with the typical Open/Save dialog when clicking on this link.
Is there any way that I can force the browser to do the same thing as 'Save Target As', without modifying the user mime configuration in IE (another common suggestion), or hosting the files on the web server?
i have a form by asp and database by MS access.so i want to prevent the duplicate value in empID because when i add a new employee with the same id ASP gives me this error.
Error Type: Microsoft OLE DB Provider for ODBC Drivers (0x80040E14) [Microsoft][ODBC Microsoft Access Driver] The changes you requested to the table were not successful because they would create duplicate values in the index, primary key, or relationship. Change the data in the field or fields that contain duplicate data, remove the index, or redefine the index to permit duplicate entries and try again. /employee/admin/addemp1.asp, line 48
so i want the employee to get a message like this empID already exist or somthing like this.
If you look around on the web for advice on cache-control and using 'Option Explicit' you get a paradox. Both features are supposed to be the first piece of ASP code on the page. Well they can't BOTH be first can they?
What would the logic be to prevent flooding? On my forum they have a timer, so if the user has submitted a post, it starts the timer, and after 30 seconds it will allow him to post again.
When the user comments, record the date in a session (StartTime) and when the user tries again, DateDiff in seconds to see if the Now() time is more than 30 seconds after the StartTime. If it is, clear the session.
i tried to open Window B using window.open() from Main Window. And from Window B i open another new Window C which fires up session("topic")="something"
So i tried to open another window link from Main Window, and the session("topic") value is still the same. how can i overcome it? Beacuse im using same session("Topic") var for all the sql query statement. so if 1 window is opening and another different session window start, it will overwrite it each other.
How can you prevent the database error from displaying on screen? Can you redirect users to a more friendly error screen that is custom created. Using ASP/SQL Server. For instance, if the database cannot be found, instead of displaying,
Microsoft OLE DB Provider for SQL Server error '80004005' [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied. /myConn.asp, line 7
Can you make it to where you could display something like this:
"I'm sorry, a database error has occured, please try your request later, click hyperlink for list of possibilities."
I have a form which when submitted will validate the fields and then add the record to a database. If a mandatory field is not completed, there is an instruction to return to the form and complete the mandatory fields and then submit.
The problem I have is preventing the user from resubmitting the same form once it has been added to the database. I cannot deactivate the submit button, because if they need to return to complete mandatory fields, the submit button is still required.
I have read the article "Programming Forms To Submit Only Once" from 15seconds.com and this looks exactly what I need......
To prevent the same form from being submitted more than once we must:
Initialize the data structures. Create a mechanism to give each form a unique identification. Find a way to store a list of already submitted forms. When processing a form submit, we just have to check if its ID is on the list.
I am having problems when adding the recommended code to my form and my process form pages.
This may not be possible on the server side, so apologies if this is the wrong group for this post.My form consists of an unknown number of pairs of text boxes. They are named textbox_a and textbox_b. I then split the comma separated list that gets posted:
textbox_a = split(Request.Form("textbox_a"),",") for i = ubound(textbox_a) ...insert into db
then do the same for textbox_b
If anyone puts a comma into one of the text boxes, this will result in unmatched pairs. How can I deal with the comma, or prevent it?
I want to prevent multiple logins in my web application. For eg:If a user "userA" logs into the application,some other user with same userid "userA" should not be allowed to login as long as previously logged in "userA" is active.
Is there any solution? One method I thought was when user logs into application, I set a flag in table.If user logs out of application from the logout button explicitly provided in application, I reset the flag for that userid.But if user closes the application from browser(close) , I am unable to find a way to reset a flag.
due to my 'Language for non-Unicode Setting' in Regional Settings,my ASP page keeps outputing the date format as Chinese Simplified characters when issuing say, <%=Now()%>. In addition, my client script also interpret it as Chinese characters, which I don't want it to behave this way.
However, I can't remove my 'Chinese (PRC)' settings in control panel as I need it for other Chinese version software. Does anyone knows how can I display the date in my ASP page in normal English? I did try out the META tag Content Type and put in several charset to try out, but seems like it doesn't work at all.