Jump to content

create thank you page


Guest

Recommended Posts

HI

I need little help with very simple ...

On my website I have "contact us" page that sends me emails

I want to make a page that will say 'thank you for contacting us..........." and it will be inside regular template.

What and where do I have to change od add something like this

Thank you

Link to comment
Share on other sites

Guest tbladecki

look at my test site

test site

You can also look under the "request a mod" fourm somone else asked for the same thing earlier today.

is that what you are looking for??

I am in the process of writting a "MOD" that will allow you to do that and incorporate it into your site docs, but I am getting ready to go to bed and will not have it completed until the morning.

Link to comment
Share on other sites

Yes, I was trying to simply make thank you page in site docs, but it comes up with the rest of site docs, I found mod that could hide some of the boxes which works great, but this one would need to hide some site docs.

Link to comment
Share on other sites

I just want this page after someone submits the form and it tells them "thanks bah blah..." The best would be if this would be a part of site docs, but there would be an option to hide it, so it does not show up with the rest of them

Link to comment
Share on other sites

Guest tbladecki

The one that I am creating is for a site doc that is "Contact Us" there is no option to turn it off, or at least that i know of, but it is part of the site docs, and is avial. to all users on the site. It does have a "thank you" page and it is set to redirect to the main page.

I will have the instructions posted later today on how to do it.

Link to comment
Share on other sites

just one question before I start modifying CC:

This message:

print "Thank you, <b>$_POST[name]</b>, for your message!<br><br>";

print "Your e-mail address is: <b>$_POST</b><br><br>";

print "Your message is regarding: <b>$_POST</b><br><br>";

print "Your messaage was:<br>";

print "$_POST[message]<br><br>";

will it come up on blank html page like on your test page or within CC?

Link to comment
Share on other sites

Guest tbladecki

yes.... i have not figured out how to get in in the same area, i have tried the _same, _lank blah blah, but it does not work

Let me look at it and ssee if I can figure it out......

Link to comment
Share on other sites

I've approached this from a different angle. I've set up the contact page using a simple form input through source, using a mail form available through my host. But the thanks page lives on the main part of the site, that way you don't have issues with blank pages etc.

Link to comment
Share on other sites

*shrug* Don't put it into the site docs to begin with. The rationale for site docs is stuff that's available/viewable AT ALL TIMES FROM ALL PAGES on-site.

Which is why I have a thankyou page resident elsewhere linked normally. Sometimes it's better to just do what works, y'know? (As opposed to trying to reinvent the wheel, for instance....)

Link to comment
Share on other sites

I agree, I wouldnot add thank you page to side docs in the first place. But I am not that good in PHP. only thing I needs is independant page inside Cubecart template that comes up after comments sent via email...

Link to comment
Share on other sites

I have thankyou.php resident in the main site root folder. I used a simple form setup provided by my host, and use this to provide a redirect to the "outside cc resident" thank you page: <input type="hidden" name="redirect" value="http://mydomain.com/thankyou.php"/>

Caveat: my host provides a reasonably secure version of a form to mail setup. Your host may NOT provide anything of this nature, or if your host does provide this sort of form it may NOT be secure. I can't be responsible for security measures not taken by you or your host with this particular system. MY setup is relatively secure due to measures taken by MY host. YMMV....

Link to comment
Share on other sites

Guest highertechpc

Hello ranfot:

You can have your thank you page right where it is. Just don't give it a name in the admin section.

That's what I did on my page in several areas, so that it can't be accessed anywhere else except from that particular area that they are in. For example on my home page, if you click on "here", near the bottom of the page close to the Paypal logo above the credit card images, you will be sent to a "site docs" location yet it can not be accessed from any other place on my site, even in the "site docs" bar at the bottom of the page. http://www.highertechpc.com You will still be able to edit it in the admin area even though it has no name. Just hit edit in the admin section so you can view it, and of course edit it.

It appears that this is what you are asking and I'm not saying that this is the best way to go about doing what you want but it works for me.

Hope this helps.

P.S.

Sorry I think I misread and/or confused your question with another similar question, but I guess this could work also.

Link to comment
Share on other sites

Guest benlogan

ok, i have worked out how to do what you all want. it is quite simple really.

Do this

1. Open 'index.php' Around line 142 there should be 'break;'

Just below it paste this code:

case "cnThanks":

include("includes/content/cnThanks.inc.php");

$body->assign("PAGE_CONTENT",$page_content);

break;






2. Create a new document in the site documents editr. Call it 'Contact Us' or whatever.



3. Click the soure button, and paste ALL this code below. Then save it.




<!--P

/*

***************************************************************************

*

*                           CONTACT US MOD INFO

*

**************************************************************************

*

*        File info  : sitedocform.php

*        Purpose    : Let your customers leave a message via mailing from

your website instead of opening their mail program

*

*        Author     : Thomas Bladecki is the original author

*                     http://www.desertcoralaquatics.com

*             ***   Edited by Ben Logan to keep everything neat and tidy. ***

*        Last update: 9/26/2005

*       Version Info: Ver. 1.0

*

*

*      Special note : ALWAYS BACKUP YOUR FILES BEFORE ADDING ANY MODS !!

*

*

*

**************************************************************************

*/

<-->Please use the form below to submit an email to us, we will get back to you as soon as possible. Thank you for your time.<br/>

<br/>

<p style="MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px">

<form action="index.php?act=cnThanks" method="post">

    Your Name: <input size="42" name="name"/><br/>

    <br/>

    Your Email address: <input size="35" tpye="text" name="email"/><br/>

    <br/>

    Please Select a topic: <select size="1" name="topic">

    <option selected="selected">Please Select one....</option>

    <option>Question about item</option>

    <option>Question regarding shipping</option>

    <option>Question about an order</option>

    <option>General question</option>

    <option>other</option>

    </select><br/>

    <br/>

    Message:<br/>

    <textarea name="message" rows="8" cols="45"></textarea><br/>

    <br/>

    <input type="submit" value="Send Email"/> <input type="reset" value="Clear"/>

</form>

</p>




4. Open up notepad, or wordpad. Create new file. Then copy and pase the following code into this new file.




<?php

/*

cnThanks.inc.php

Created by Ben Logan

*/



if(!isset($config)){

	echo "<html>\r\n<head>\r\n<title>Forbidden 403</title>\r\n</head>\r\n<body><h3>Forbidden 403</h3>\r\nThe document you are requesting is forbidden.\r\n</body>\r\n</html>";

	exit;

}



$no_ship = new XTemplate ("skins/".$config['skinDir']."/styleTemplates/content/noShip.tpl");



	$no_ship->assign("LANG_SORRY",'Thank You');

	$no_ship->assign("LANG_DESC",'You message has been sent to the store owner.');



// Build Mail string

$msg = "Name: $_POST[name]\n";

$msg .="Email: $_POST[email]\n";

$msg .="Topic: $_POST[topic]\n";

$msg .="Message: $_POST[message]\n";



//Setup the mail format

$recipient = "ENTER_YOUR_EMAIL_ADDRESS";

$subject = "$_POST[topic]";

$mailheaders .= "From: $_POST[name]";

$mailheaders .= "Reply-To: $_POST[email]";



//Send the contact form

mail($recipient, $subject, $msg, $mailheaders);



	$no_ship->parse("no_ship");

	

$page_content = $no_ship->text("no_ship");



?>




3. Now save this file as 'cnThanks.inc.php', and place it in



/ROOT_DIR/includes/content



Now you site contact form is done. To edit your thankyou messsage find this line:




$no_ship->assign("LANG_DESC",'Your message has been sent to the store owner.');

It is obvious what piece you must edit.

I have included all the files necessary.

Contact me if you have any problems.

ContactForm.Integrated.zip

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.




×
×
  • Create New...