SitePoint Sponsor

User Tag List

Results 1 to 10 of 10
  1. #1
    SitePoint Enthusiast
    Join Date
    Sep 2006
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Problem with FormMail

    I'm currently working my way through the Sitepoint book 'Build your own standard compliant website using DW8' Part of the project site is to have a contact page with a form. ASP was supported by the hosting company I use so downloaded the script from http://www.brainjar.com/asp/formmail/ which was recommended in the book.

    If I try and submit a form in Firefox I get the following error:

    Server object error 'ASP 0177 : 800401f3'
    Server.CreateObject Failed
    /codespark/FormMail.asp, line 465
    800401f3

    If I try in IE6 I get page not available....

    I'm new to all this, so would appreciate any help.

    The contact page can be found here: http://www.houndsbaybassets.co.uk/co...tactasp2.shtml

    The ASP script here: http://www.houndsbaybassets.co.uk/co...k/FormMail.asp

    Many thanks

  2. #2
    SitePoint Wizard
    Join Date
    Nov 2004
    Location
    Nelson BC
    Posts
    2,310
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    There is no way for us to review the ASP code - it is executed and converted to HTML.

    Server.CreateObject error means that the server is unable to create an activeX component (in this case mail component) due to it being
    - missing (usually)
    - badly configured

    You would need to open your ASp file and post line 465 here.

  3. #3
    SitePoint Enthusiast
    Join Date
    Dec 2004
    Location
    Kentucky USA
    Posts
    88
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I agree... Without seeing the code... its impossible to pinpoint.
    But.. using this script myself... it looks like the customization at the start of the formmail.asp script is not setup completley.

    referers = Array()
    mailComp = "ASPMail"
    smtpServer = "INSERT YOUR EMAIL SERVER ADDRESS HERE"
    fromAddr = "INSERT YOUR EMAIL ADDRESS HERE"

    I think just changing the smtpserver and fromAddr fields is all that is required. As long as the rest of the formmail script is unaltered it should work out of the box... or at least it did for me.
    Hope this helps.

    Cheers

  4. #4
    SitePoint Enthusiast
    Join Date
    Sep 2006
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry guys, I should have realised you couldn't look the ASP Code.

    The entire code can be seen here: http://www.houndsbaybassets.co.uk/co...k/FormMail.txt

    The customized section at the top is:
    referers = Array("www.houndsbaybassets.co.uk", "houndsbaybassets.co.uk")
    mailComp = "ASPMail"
    smtpServer = "smtp.ntlworld.com"
    fromAddr = "formmail@moleabbey.co.uk"

    Line 465 is:
    set mailObj = Server.CreateObject("SMTPsvg.Mailer")

    Thanks again.

  5. #5
    SitePoint Wizard
    Join Date
    Nov 2004
    Location
    Nelson BC
    Posts
    2,310
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    are you sure the hosting company has SMTPsvg.Mailer installed?

  6. #6
    SitePoint Enthusiast
    Join Date
    Sep 2006
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by jimfraser
    are you sure the hosting company has SMTPsvg.Mailer installed?
    Not sure, I've emailed them....

  7. #7
    ALT.NET - because we need it silver trophybronze trophy dhtmlgod's Avatar
    Join Date
    Jul 2001
    Location
    Scotland
    Posts
    4,836
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm guessing by the error that they don't. Change this line:
    Code:
    mailComp   = "ASPMail"
    to
    Code:
    mailComp   = "CDOSYS"

  8. #8
    SitePoint Enthusiast
    Join Date
    Sep 2006
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by dhtmlgod
    I'm guessing by the error that they don't. Change this line:
    Code:
    mailComp   = "ASPMail"
    to
    Code:
    mailComp   = "CDOSYS"
    With that change I now get this error:

    Microsoft VBScript compilation error '800a0408'
    Invalid character
    /codespark/FormMail.asp, line 304
    for i = 1 to Len(domain?
    -----------------------^

    Line 304 reads:

    for i = 1 to Len(domain?
    charCode = Asc(Mid(domain, i, 1))

    Many thanks

  9. #9
    SitePoint Enthusiast
    Join Date
    Sep 2006
    Posts
    27
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by jimfraser
    are you sure the hosting company has SMTPsvg.Mailer installed?
    The answer was No!

  10. #10
    SitePoint Enthusiast Northern Star's Avatar
    Join Date
    Aug 2006
    Location
    Cheshire, UK
    Posts
    96
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by dazman1360
    The answer was No!
    That solves that problem then!

    Quote Originally Posted by dazman1360
    With that change I now get this error:

    Microsoft VBScript compilation error '800a0408'
    Invalid character
    /codespark/FormMail.asp, line 304
    for i = 1 to Len(domain?
    -----------------------^

    Line 304 reads:

    for i = 1 to Len(domain?
    charCode = Asc(Mid(domain, i, 1))
    !
    The correct syntax for 'Len' (in this case) should be...

    Code:
    Len(strName)
    
    Or
    
    Len("This string contains 35 characters!")
    "If it ain't broken, don't fix it!"
    ----
    Northern Star - Web design, stategy & development.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •