Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 26th, 2003, 04:30 AM
Friend of Wrox
 
Join Date: Oct 2003
Location: Cairo, , Egypt.
Posts: 336
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to alyeng2000
Default submitting a form have an input File

hi all,

i need help in this amazing problem as i when i add the file input
<input type="file" name="file1" size="20"> in the form and when submitting this form it does not return any input text like Request.Form("FirstName") if i remove(this file input) it works


need help


Ahmed Ali
Software Developer
__________________
Ahmed Ali
Senior Software Developer
 
Old October 26th, 2003, 06:01 AM
Friend of Wrox
 
Join Date: Oct 2003
Location: Cairo, , Egypt.
Posts: 336
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to alyeng2000
Default

the problem is solved, i don't know how,but there is another one when inserting this image file the server return error

Error Type:
Microsoft Cursor Engine (0x80040E21)
Multiple-step operation generated errors. Check each status value.
/freechat/createAccount.asp, line 132


Browser Type:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)

Page:
POST 167 bytes to /freechat/createAccount.asp

POST Data:
username=ertyrty&userpassword=rtyrtyr&firstname=ty rtyrt&lastname=yrtyrt&emailaddress=r@.jkl&phone=&a ddress=&job=&validAcc=filled&FilePic=C%3A%5CMy+Doc uments%5Cscan.jpg

Ahmed Ali
Software Developer
 
Old October 26th, 2003, 06:04 AM
Friend of Wrox
 
Join Date: Oct 2003
Location: Cairo, , Egypt.
Posts: 336
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to alyeng2000
Default

this is the code for insertion in database

    RcAcc.AddNew
    RcAcc("userName") = Request.Form("userName")
    RcAcc("userpassword") = Request.Form("userpassword")
    RcAcc("FirstName") = Request.Form("FirstName")
    RcAcc("LastName") = Request.Form("LastName")
    RcAcc("Email") = Request.Form("Email")
    RcAcc("Address") = Request.Form("Address")
    RcAcc("Phone") = Request.Form("Phone")
    RcAcc("Job") = Request.Form("Job")
    RcAcc("Pic") = Request.Form("FilePic")

    RcAcc.Update




Ahmed Ali
Software Developer
 
Old October 26th, 2003, 06:22 AM
Friend of Wrox
 
Join Date: Oct 2003
Location: Cairo, , Egypt.
Posts: 336
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to alyeng2000
Default

the problem is solved when deleting the line
(RcAcc("Pic") = Request.Form("FilePic"))
for insetring the image but i need that insrtion happen

need help


Ahmed Ali
Software Developer
 
Old October 30th, 2003, 03:06 AM
Authorized User
 
Join Date: Jul 2003
Location: Athens, , Greece.
Posts: 50
Thanks: 0
Thanked 0 Times in 0 Posts
Default

How are you trying to retrieve the content of the field?

When I try this in my server, it works:

"pagename=test.asp"

Code:
<%
strFile=Request.Form("file1")
Response.Write strFile
%>
<form name="testFrm" action="test.asp" method="post">
<input type="file" name="file1" size="20"> 
</form>
If thats what you mean
Kostas Lagos

 
Old October 30th, 2003, 07:03 AM
Friend of Wrox
 
Join Date: Oct 2003
Location: colombo, WP, Sri Lanka.
Posts: 479
Thanks: 0
Thanked 3 Times in 3 Posts
Send a message via MSN to surendran Send a message via Yahoo to surendran
Default

''''''''''''''''''''
pagename=wroxfile.asp
'''''''''''''''''

<%
strFile=Request.Form("file1")
Response.Write strFile
%>
<SCRIPT LANGUAGE=javascript>
<!--
function submit1()
{
document.form1.action="wroxfile.asp"
document.form1.submit()
}
//-->
</SCRIPT>

<form name="form1" method="post">
<input type="file" name="file1" size="20">
<input type="button" name="file1" size="20" value=submit onclick="submit1()">

</form>


surendran
 
Old November 1st, 2003, 09:22 PM
Friend of Wrox
 
Join Date: Oct 2003
Location: Cairo, , Egypt.
Posts: 336
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to alyeng2000
Default

thanks all,

the proplem were that i was tring to insert the path for image file (text Type) in a field Type is Image when inerting in Database.

the error was conflicting me to explain the problem !!!

Ahmed Ali
Software Developer




Similar Threads
Thread Thread Starter Forum Replies Last Post
Need HELP with: Formated Input form file LoonyGenius C++ Programming 3 December 25th, 2006 06:43 PM
form submitting cro_crx Pro PHP 5 January 25th, 2005 12:19 PM
Form Submitting cro_crx Beginning PHP 3 January 17th, 2005 01:30 PM
Submitting a form YuliaKupina Classic ASP Basics 3 June 24th, 2004 01:52 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.