Jump to content

larissahn

Member
  • Posts

    16
  • Joined

  • Last visited

larissahn's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. hi, I have this tell a friend php script. it works, it does send the email, but without any of the fields, like subject, friend's name, message. here is the code: <?php $site_name = "[url=http://www.utilaecology.org]www.utilaecology.org[/url]"; $subject = "Tell a friend"; $body = "Hello,\r\nYour friend $name ($email) has recommended that you see our website $site_name. He has also sent this message along with the recommendation:\r\n" . $message . "\r\n Thank you,\r\n-The webmaster"; if($_POST["send"] == "true") { $to = $_POST["to"]; $name = $_POST["name"]; $email = $_POST["email"]; $message = $_POST["message"]; if (($name == "") OR ($email == "") OR ($message == "")) { print (""); print ("One of the fields was left blank. Please put something in all fields. "); print (" "); email_form(); }elseif(ereg("([[:alnum:]\.\-]+)(\@[[:alnum:]\.\-]+\.+)", $email)) { $recipient = $to; $subject = $the_subject; $additional_headers = ("From: $email\n"); if(mail($recipient, $subject, $body, $additional_headers)) { print (""); print ("Tell a friend script mailed your friend at $to about $site_name successfully. Thank you. "); print (" "); }else{ print (""); print ("Uh-Oh! Something went wrong with the script! Please try again. "); print (" "); $send = "false"; email_form(); } }else{ print (""); print ("That email address does not appear to be valid. Please try again. "); print (" "); $send = "false"; email_form(); } }else{ print (""); print (" Tell a friend"); print (" "); email_form(); } function email_form(){ global $subject_array, $recipient_array, $this_script, $PHP_SELF; print (""); print ("\n"); print (""); print ("To: \n"); print (""); print (" \n"); print (""); print ("Name: \n"); print (""); print (" \n"); print (""); print ("Your Email Address: \n"); print (""); print (" \n"); print (""); print ("Your Message: \n"); print (""); print (" \n"); print (""); print (""); print ("\n"); print (" \n"); print ("\n"); print (""); print ("\n"); print (""); print ("script by leapinglangoor"); print (""); print (""); } ?> Thanks!
  2. hi, I created this form. to avoid errors, I'd like the user to select the date from a calendar that pops up. unfortunately, I haven't been able to make it work. this is my form: http://www.utilaecology.org/research/lionfish_contact.php this is the date picker I want to use: http://www.rainforestnet.com/datetimepicker.htm and this is my code: <?php include('../includes/core.php'); layout_start(true); ?> Report lionfish sighting Please fill in the form below if you would like to report a lionfish sighting and we will get back to you as soon as possible. Name: Email: Date: thanks!
  3. larissahn

    Feedback Form

    Hi, I recently created a simple form for my website, http://www.utilaecology.org/research/lionfish_contact.php the feedback should be sent to my email, but I am not receiving anything. <?php $name = $_REQUEST['name'] ; $email = $_REQUEST['email'] ; $date = $_REQUEST['date'] ; $dive_site = $_REQUEST['dive_site'] ; $depth = $_REQUEST['depth'] ; $additional_information = $_REQUEST['additional_information'] ; if (!isset($_REQUEST['email'])) { header( "Location: http://www.utilaecology.org/contact/response.php" ); } elseif (empty($email) || empty($dive_site)) { header( "Location: http://www.utilaecology.org/contact/response.php" ); } else { mail ( "larissahn@rocketmail.com", "Report Lionfish Sighting Form", "Date: $date\n", "Dive Site Location: $dive_site\n", "Depth: $depth\n", "Additional Information: $additional_information\n", "From: $name <$email>" ) ; header ( "Location: http://www.utilaecology.org/contact/response.php" ) ; } ?>
  4. larissahn

    Drop down menu

    hi, but I just want to leave the 3, 4 and 8 week option. delete the 2-week one completely.
  5. larissahn

    Drop down menu

    hi, this question might just be the stupidest ever, but I want to be careful and not mess anything up. this is the code for a drop down menu I have in an application page. Select Programme 2-Week 4-Week 8-Week to change from a 2 week to a 3 week option, I just substitute the 3 for a 2, right? I think it is just a string, I'm just not sure what >2-Week at the end of the line is, not calling a variable, right?
  6. hello, everyone I want to make some changes to the menu of my site. I can read the code, but it has this grayish color and Dreamweaver doesn't let me copy, cut, or paste anything. however, there is other code, without the grayish color, just normal looking, that I can modify. what could be the problem?
  7. ok, i'll do the backups. but the only thing i need to do, besides that, is upload the page again, right? keep in mind that i downloaded only the page (not the images, flash files, etc.)?
  8. let's say i have to update an existing site. the page i'm working on is called programmes.php i haven't downloaded the entire site to my pc, just this one page to work on it. i made some changes to the text and i added a new pdf file (which i copied to my local root folder first). i didn't download images or anything else from the server, just the one page. i want to make sure that when i upload it, i don't ruin the page. when i finish with the changes, i only have to choose the arrow that says"put files", nothing else?
  9. i have no idea how the menu is being generated. the code i pasted above came from dreamweaver, where i could read it on every page of the site, but it wouldn't let me modify it. i've opened almost every page on the server looking for a kind of menu.php, because i imagine the menu has it's own .php file, but i've had no luck. what can i do to know how the menu is being generated?
  10. ok, let me see if i got this straight. changing the order of the menu options is plain and simple. i just copy the options in the order i want them (in the code). and to delete an option from the menu, i just delete any reference to it in the code. the menu is universal, so i should make these changes to the menu in each page and upload to the server, right?
  11. so it's probably a good idea to download the www folder from the server using BitKinex and copying it to the www directory of the wamp. that way i can preview the pages from now on without any problems.
  12. this is the code i have for a menu. what i want to do is 2 things: first, delete the beautiful oceans option and second, move the FAQs option up and place it under Programmes and Costs. what do u suggest I do? thanx. About Aims & Objectives History Staff Interns Partners Funding Responsible Travel Acknowledgements Research Coral Reefs Coral Bleaching Fisheries Megafauna Whale Sharks Cetaceans Island Ecology Coconuts Mangroves Seagrass Project Proposals Volunteer Programmes & Costs Internships Beautiful Oceans Blog FAQ Community Education Socioeconomics Traditional Knowledge Ecology Coral Reefs Seagrass Mangroves Connectivity Whale Sharks Cetaceans Downloads Documents Wallpapers Links Utila News Contact
  13. i did that, but the preview looks different. it didn't load any images, for example, nor the menu (which was generated using php).
  14. ok, i already have WampServer 2 running on my pc. i saved a page from dreamweaver in the www directory, but when i choose localhost, it doesn't give me the list of projects. basically my question is: after making the changes using dreamweaver (before uploading anything to the server), how can i preview how the page looks using WampServer 2? thanx again.
  15. ok, i will try that. i will download WAMP. the changes i need to make now are basically small, text related. thanx.
×
×
  • Create New...