Jump to content

form2mail.php instead of thankyou.html

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
9 replies to this topic

#1
daraclare

daraclare

    Learning Programmer

  • Members
  • PipPipPip
  • 44 posts
Hi,

I just added a contact page to a site and when I click "submit" I get form2mail.php instead of thankyou.html.

Can anyone advise me what I'm missing? I'm using Dreamweaver CS4 if that makes a difference and I have uploaded blockip.txt, form2mail.php and thankyou.html

Thanks in advance,

DC

#2
BlaineSch

BlaineSch

    Writes binary right handed and hex left handed

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 2,448 posts
That depends a LOT on your script, I would assume thankyou.html is completely static and form2mail.php would process the request making sure it's not a blocked IP etc then redirect you to thankyou.html

can you post up some code?

#3
daraclare

daraclare

    Learning Programmer

  • Members
  • PipPipPip
  • 44 posts
No I can't post script. The admin won't let me, it keeps saying:

"To be able to post links or images your post count must be 10 or greater. You currently have 4 posts.

Please remove links from your message, then you will be able to submit your post."


Is there another way to upload something here?

Thanks for your help

#4
BlaineSch

BlaineSch

    Writes binary right handed and hex left handed

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 2,448 posts
You cant post the source code? I think you can attach files, right? Why not zip and do that?

#5
alienkinetics

alienkinetics

    Programmer

  • Members
  • PipPipPipPip
  • 154 posts
Have you got a apache and PHP installed on your development PC?

If not, then you need to upload to a server to test your PHP code.

Also, emailing wont work unless you have setup your PHP email settings.

#6
daraclare

daraclare

    Learning Programmer

  • Members
  • PipPipPip
  • 44 posts
It won't let me do that either! just tried with php, zip, txt, doc and pdf!

#7
daraclare

daraclare

    Learning Programmer

  • Members
  • PipPipPip
  • 44 posts
I have apache set up and my PHP email settings

Sorry I can't upload the code to show u!

#8
alienkinetics

alienkinetics

    Programmer

  • Members
  • PipPipPipPip
  • 154 posts
O, cool. ok. what do you mean by "I get form2mail.php" ?

That is what is ment to happen, isn't it. Most form2mail scripts use the forms action attribute to post field values to php which emails the data and then redirects to a "thankyou" page.

Did you download this script from the net? eg:

http://scripts.rings...m2mail.php.html

#9
daraclare

daraclare

    Learning Programmer

  • Members
  • PipPipPip
  • 44 posts
Thanks folks All sorted now but thanks for your help!

#10
daraclare

daraclare

    Learning Programmer

  • Members
  • PipPipPip
  • 44 posts
By the way it was just a typo on the script in the line containing "thankyou.html" Silly mistake I should have seen but your help is much appreciated!

DC