 |
|
 |
Hi ,
I am submitting a html form in ASP.NET 1.1, to a websphere server. I am browsing excel file and submitting through object to Websphere server, by sybmitting form with action as Websphere hosted address.
Whenever I login to app, and try to upload the file with above functionality, for the first time, I get redirected to Login.aspx automatically. But when I re-login again and does the same thing as above, the file is uploaded successfully.
Can you please help me regarding this, as I have maintained releative values of timeout for session and form-authentication in web.config file.
- Ajay K
|
|
|
|
 |
|
 |
easy to use any very detailed for use.
|
|
|
|
 |
|
 |
Guys, I wrote this script years ago. It uses classic ASP, which is SO out of date it's not funny. If you want to send mail, go look on google for formmail.cgi, or find a php mail script, or find an ASP.Net script. Trying to resolve ASP issues at this point is like asking for support on an old Apple IIE computer.
|
|
|
|
 |
|
|
 |
|
 |
not compatible with Windows 2003
|
|
|
|
 |
|
 |
I have the script installed, html form and email template set-up correctly , but when I select "Send" on the form, the browser simply opens the asp text file rather than executing the script.
I'm certain there is something very simple i've overlooked, but I'm banging my head against the wall right now.
Anyone have some insight?
Thanks
|
|
|
|
 |
|
 |
i encountered the problem after clicked Send.
CDO.Message.1 error '80040220'
The "SendUsing" configuration value is invalid.
/sendmail_cdo.asp, line 120
Please guide me to solve this problem
Thanks
|
|
|
|
 |
|
 |
try this
http://www.codeproject.com/KB/asp/cdoex.aspx
|
|
|
|
 |
|
|
 |
|
 |
This is what i got after including all necessary things like smtpserver, port, senduing:
CDO.Message.1 error '80040213'
The transport failed to connect to the server.
Pls help solve this problem.
|
|
|
|
 |
|
 |
I am new to ASP and went through the sample code thoroughly but do not know where I am to add my smtp server or if I need to add it at all. I get the thanks.htm page but no email sent when email is placed. Can anyone specify where I would need to change code to test this out to go to my email.
dim pde : set pde = createobject("scripting.dictionary")
'---------------------------------------------------------------------------------------------------
'PREDEFINED ADDRESSES for the "mailto" hidden field
'if you don't want to reveal email addresses in hidden fields, use a token word instead and specify
'below which email address it applies to. e.g. <input type="hidden" name="mailto" value="%stratdepartment%">
'ALSO, in the same way, you can use %mailfrom% to hide the originating email address
pde.add "%contactform%", "helpme@yahoo.com"
pde.add "%salesenquiry%", "helpme@yahoo.com"
'---------------------------------------------------------------------------------------------------
function getTextFromFile(path)
dim fso, f, txt
set fso = createobject("Scripting.FileSystemObject")
if not fso.fileexists(path) then
getTextFromFile = ""
exit function
end if
set f = fso.opentextfile(path,1)
if f.atendofstream then txt = "" else txt = f.readall
f.close
set f = nothing
set fso = nothing
getTextFromFile = txt
end function
dim redir, mailto, mailfrom, subject, item, body, cc, bcc, message, html, template, usetemplate, testmode
redir = request.form("redirect")
mailto = request.form("mailto")
if pde.exists(mailto) then mailto = pde(mailto)
cc = request.form("cc")
bcc = request.form("bcc")
mailfrom = request.form("mailfrom")
if mailfrom = "" then mailfrom = pde("%mailfrom%")
subject = request.form("subject")
message = request.form("message")
template = request.form("template")
testmode = lcase(request.form("testmode"))="yes"
if len(template) > 0 then template = getTextFromFile(server.mappath(template))
if len(template) > 0 then usetemplate = true else usetemplate = false
dim msg : set msg = server.createobject("CDO.Message")
msg.subject = subject
msg.to = mailto
msg.from = mailfrom
if len(cc) > 0 then msg.cc = cc
if len(bcc) > 0 then msg.bcc = bcc
if not usetemplate then
body = body & message & vbcrlf & vbcrlf
else
body = template
end if
for each item in request.form
select case item
case "redirect", "mailto", "cc", "bcc", "subject", "message", "template", "html", "testmode"
case else
if not usetemplate then
if item <> "mailfrom" then body = body & item & ": " & request.form(item) & vbcrlf & vbcrlf
else
body = replace(body, "[$" & item & "$]", replace(request.form(item),vbcrlf,"<br>"))
end if
end select
next
if usetemplate then 'remove any leftover placeholders
dim rx : set rx = new regexp
rx.pattern = "\[\$.*\$\]"
rx.global = true
body = rx.replace(body, "")
end if
if usetemplate and lcase(request.form("html")) = "yes" then
msg.htmlbody = body
else
msg.textbody = body
end if
if testmode then
if lcase(request.form("html")) = "yes" then
response.write "<pre>" & vbcrlf
response.write "Mail to: " & mailto & vbcrlf
response.write "Mail from: " & mailfrom & vbcrlf
if len(cc) > 0 then response.write "Cc: " & cc & vbcrlf
if len(bcc) > 0 then response.write "Bcc: " & bcc & vbcrlf
response.write "Subject: " & subject & vbcrlf & string(80,"-") & "</pre>"
response.write body
else
response.write "<html><head><title>Sendmail.asp Test Mode</title></head><body><pre>" & vbcrlf
response.write "Mail to: " & mailto & vbcrlf
response.write "Mail from: " & mailfrom & vbcrlf
if len(cc) > 0 then response.write "Cc: " & cc & vbcrlf
if len(bcc) > 0 then response.write "Bcc: " & bcc & vbcrlf
response.write "Subject: " & subject & vbcrlf & vbcrlf
response.write string(80,"-") & vbcrlf & vbcrlf & "<span style=""color:blue;"">"
response.write body & "</span>" & vbcrlf & vbcrlf
response.write string(80,"-") & vbcrlf & "**END OF EMAIL**</pre></body></html>"
end if
else
msg.send
response.redirect redir
end if
set msg = nothing
%>
|
|
|
|
 |
|
 |
Wow... you realise this article is about 5 years old, right? I honestly can't remember enough to answer the question. Classic ASP isn't really something you should be learning in this day and age. Go check out ASP.Net or PHP.
NATHAN RIDLEY
Web Application Developer
email: snowdevil [@] gmail.com
!! Are you a skilled ASP.Net programmer or web designer and would like to help bring the best new ASP.Net CMS ( http://www.sprocketcms.com[ ^]) into the forefront of the ASP.Net community? Please contact me and let me know.
|
|
|
|
 |
|
 |
I have your form up and running on my site and it works great. It works so great that I get robots filling it out and sending me sales pitches for viagra and the like . What can I do to prevent this? Can some sort of validation be added that is not machine readable? The form is on my main page, I suppose moving it would help, but I like it where it is. Any ideas?
John in PA
|
|
|
|
 |
|
 |
Has anybody found a solution to this error?
At my current domain www.worldofrugs.com the sendmail_cdo.asp script works wonderful!, but at my new hosting I get this error (see www3.worldofrugs.com/Password.html, submit the form and see the error)
Any help would be highly appriciated, as I am lost with this!
Thanks!
-- modified at 15:22 Monday 22nd October, 2007
Ok, found the solution!
I added:
msg.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver")="smtp.www.myserver.com"
This worked perfect!
Hope it will help others ;o)
|
|
|
|
 |
|
 |
Hi,
I've found your script really useful. However, I would like to now be able to save the details filled in the form to a file as well as emailing them on. Is this possible ? If so, I'd appreciate any help with this?
Thanks
Danielle
|
|
|
|
 |
|
 |
I've never done a form before so please excuse me if I'm being thick... I keep getting an error message:
CDO.Message.1 error '8004020d'
At least one of the From or Sender fields is required, and neither was found.
/lightfoot/contact/sendmail_cdo.asp, line 120
*******************************
I've got the form set up, see code: http://www.lightfootfoundation.com/contact/form.htm
And the form results see code: http://www.lightfootfoundation.com/contact/formresults.htm
I'm using sendmail_cdo.asp (and am probably messing up here):
http://www.lightfootfoundation.com/contact/CDO.htm
********************************
Any help would be greatly appreciated.
Brenda
|
|
|
|
 |
|
|
 |
|
 |
I am very new to ASP and am trying to get this to work. The CDO code itself would submit, but I would get no email so I added the send mail configs as follows under msg.from = mailfrom on line 66. I have the correct sendmail.server.com in there as well. Now the page submits, but gives me HTTP 500 internal error.
msg.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing")=2
msg.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver")="sendmail.mjmi.com"
msg.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport")=25
msg.Configuration.Fields.Update
What am I doing wrong here?
Thanks for any help.
|
|
|
|
 |
|
 |
Well first nice script man Very easy to setup
I just set it up on a form I had.
I added the correct field names in the format shown in the sample email template.
I also set the neccessary hidden fields in my form.
I get the message however the last 5 fields come up empty even though I field them out.
I have triple checked the field names and they are fine.
Thanks, Kenny
|
|
|
|
 |
|
 |
I figured it out myself, hopefully this helps someone.
The problem was the carriage returns etc in the remaing fields which were all text areas.
I found nice little script which I call before submitting it replaces all my carriage returns with
http://javascript.internet.com/forms/removereturns.html
I also put my destinations in my email template within PRE tags. That saved any extra spaces tabs etc that was in the info.
For Example: [$TextArea1]
And once again great job on this script man!
I'm gonna look like a genius when I show them this
|
|
|
|
 |
|
 |
Above example should be:
[$TextArea1$]
|
|
|
|
 |
|
 |
I am new to ASP. Can you help me on how to work on it. Because i read through your note and found not really understand.
I worked on it but it doesn't work. program just jump to your data text mode of sendmail_cdo.asp.
|
|
|
|
 |
|
 |
I have the exact same issue. Did you ever get it resolved?
Chee Shai Choon wrote: program just jump to your data text mode of sendmail_cdo.asp. [Confused]
|
|
|
|
 |
|
 |
I see that other people have had this problem.... did anyone figure out what was causing the problem?
CDO.Message.1 error '80040220'
The "SendUsing" configuration value is invalid.
sendmail_cdo.asp, line 120
Any help would be appreciated !
Nicola
|
|
|
|
 |
|
|
 |