Php help please

New to all this and have been following a tute on youtube, the tute is using CS3 but I am using CS6 and this has arrisen:
Can someone please point me in the right direction to fixing this issue?
Cheers
J

Can someone confirm that I have this code correct please?
Contact form:
<form id="form1" method="post" action="jmacphot.php">
      <table width="80%" border="0" cellspacing="5" cellpadding="6">
        <tr>
          <td width="26%"><label for="email">Email:</label></td>
          <td width="74%"><input name="email" type="text" id="email" size="35" maxlength="90" /></td>
        </tr>
        <tr>
          <td><label for="name">Name:</label></td>
          <td><input name="name" type="text" id="name" size="35" maxlength="80" /></td>
        </tr>
        <tr>
          <td><label for="phone">Phone:</label></td>
          <td><input name="phone" type="text" id="phone" size="35" maxlength="12" /></td>
        </tr>
        <tr>
          <td>How did you hear about this site?</td>
          <td><p>
            <label>
              <input type="radio" name="found" value="google" id="found_0" />
              Google Search</label>
            <br />
            <label>
              <input type="radio" name="found" value="tv" id="found_1" />
              TV Add</label>
            <br />
            <label>
              <input type="radio" name="found" value="radio" id="found_2" />
              Radio Add</label>
            <br />
            <label>
              <input type="radio" name="found" value="friend" id="found_3" />
              Friend</label>
            <br />
            <label>
              <input type="radio" name="found" value="gossip" id="found_4" />
              Gossip</label>
            <br />
            <label>
              <input type="radio" name="found" value="ciggy packet" id="found_5" />
              Written on the back of a ciggy packet</label>
            <br />
          </p></td>
        </tr>
        <tr>
          <td><label for="cameras">Number of cameras owned:</label></td>
          <td><select name="cameras" size="1" id="cameras">
            <option>Choose</option>
            <option value="1">1</option>
            <option value="2">2</option>
            <option value="3">3</option>
            <option value="4+">4+</option>
          </select></td>
        </tr>
        <tr>
          <td><label for="comments">Comments:</label></td>
          <td><textarea name="comments" id="comments" cols="30" rows="5"></textarea></td>
        </tr>
        <tr>
          <td> </td>
          <td><input type="checkbox" name="newsletter" id="newsletter" />
          <label for="newsletter">Subscribe to my newsletter!</label></td>
        </tr>
        <tr>
          <td><input type="reset" name="reset" id="reset" value="Reset" /></td>
          <td><input name="submit" type="submit" id="submit" value="Submit Form" /></td>
        </tr>
      </table>
    </form>
php script:
<?php
/* subject and Email Variables */
    $emailSubject = 'Jmacphot Form';
    $webMaster = '[email protected]';
/* Gathering Data Variables */
    $emailField = $_POST['email'];
    $nameField = $_POST['name'];
    $phoneField = $_POST['phone'];
    $foundField = $_POST['found'];
    $camerasField = $_POST['cameras'];
    $commentsField = $_POST['comments'];
    $newsletterField = $_POST['newsletter'];
    $body = <<<EOD
<br><hr><br>
Email: $email <br>
Name: $name <br>
Phone Number: $phone <br>
How did you hear about this site: $found <br>
Number of cameras owned: $cameras <br>
Comments: $comments <br>
Newsletter: $newsletter <br>
EOD;
    $headers = "From: $email\r\n";
    $headers .= "Content-type: text/html\r\n";
    $success = mail ($webMaster, $emailSubject, $body, $headers);
/* Results rendered as HTML */
    $theResults = <<<EOD
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="Photography portfolio using both Nikon d3200 and canon ixus 65" />
<meta name="keywords" content="Portfolio,Pictures,Camera,Lenses,Photography,photo,informative,functional,evolvi ng,expanding,pics,new,photographer,hobby,John,MacKinnon,images,eye,catching,colourful,blac k,white
" />
<meta name="author" content="john mackinnon" />
<meta name="robots" content="index, follow" />
<meta name="revisit-after" content="3 month" />
<title>Jmacphot Home</title>
<!-- Photography, portfolio, personal -->
<link rel="shortcut icon" href="images/favicon.ico" />
<link href="css/style.css" rel="stylesheet" type="text/css"/>
<link href="SpryAssets/SpryMenuBarHorizontal.css" rel="stylesheet" type="text/css"/>
<style type="text/css">
a:link {
    text-decoration: none;
    color: #000;
    border: 0;
a:visited {
    text-decoration: none;
    color: #000;
a:hover {
    text-decoration: underline;
    color: #F00;
a:active {
    text-decoration: none;
    color: #000;
</style>
<link href="css/print.css" rel="stylesheet" type="text/css" media="print" />
<script src="SpryAssets/SpryMenuBar.js" type="text/javascript"></script>
</head>
<body bgcolor="#000000">
<div id="wrapper">
  <div id="header">
      <a href="home.html"><img src="images/header.jpg" width="800" height="150" alt="logo" /></a>
  </div><!-- End Header Div -->
  <div id="navigation">
    <ul id="MenuBar1" class="MenuBarHorizontal">
      <li><a href="home.html">Home</a></li>
      <li><a href="about.html">About</a></li>
      <li><a href="equipment.html">Equipment</a></li>
      <li><a href="gallery.html">Gallery</a></li>
      <li><a href="contact.html">Contact</a></li>
    </ul>
  </div><!-- End Navigation Div -->
  <div id="content"><br />
    <p>Thank you for completing the form, I will endeavour to get back to you shortly!</p>
    <p> </p>
    <p> </p>
  </div><!-- End Content Div -->
  <div id="footer">Copyright <a href="index.html">JMACPHOT.com</a> 2013 &copy;        
    <a href="home.html">Home</a> |   
    <a href="about.html">About</a> |   
    <a href="equipment.html">Equipment</a> |   
    <a href="gallery.html">Gallery</a> |   
    <a href="contact.html">Contact</a> |       
    <a href="site.html">Site map</a>
  </div><!-- End Footer Div -->
</div><!-- End Wrapper Div -->
</body>
</html>
EOD;
echo  "$theResults";
?>
I have been told by my web host that I am required to apply SMTP? I have no idea where or how to fit this in, can someone guide me through it? That way I will remember for the next time and not need to bother you nice people....
Thank you!
J

Similar Messages

  • Passing variable from php into flash, help please

    Here are what I'm having:
    <?PHP
    $testVal = "This is a test";
    $test = urlencode($testVal);
    $out = "test=". $testVal;
    echo $out;
    ?>
    // and this is my flash file
    function getData() {
    // Prepare request
    var urlReq:URLRequest=new URLRequest("http://localhost/test.php");
    urlReq.method=URLRequestMethod.GET;
    var loader:URLLoader = new URLLoader();
    loader.dataFormat=URLLoaderDataFormat.VARIABLES;
    loader.addEventListener(Event.COMPLETE, completeHandler);
    loader.load(urlReq);
    function completeHandler(evt:Event) {
    var vars:URLVariables = URLVariables(evt.target.data);
    trace(" TEST = ", vars.test);
    trace(" TEST = ", unescape(vars.toString()));
    // and below is the ouput
    TEST = undefined
    TEST = test=This is a test
    I've tried with several different ways to get ONLY the value of the variable - that means I only want to have "This is a test" returned, but I either got "undefined" or the whole thing "test=This is a test", instead.
    I'm new to Flash and PHP. Please help.
    Thanks

    There's no need to write any fake variables out, Flash does not need that. OK, here's a simple PHP script like yours - I called it test.php
    <?PHP
         $testVal = "This is a test";
         $out = "test=". $testVal;
         echo $out;
    ?>
    And the AS to call it:
    var myLoader:URLLoader = new URLLoader();
    myLoader.dataFormat = URLLoaderDataFormat.VARIABLES;
    myLoader.load(new URLRequest("http://www.mydomain.com/test.php"));
    myLoader.addEventListener(Event.COMPLETE, dataLoaded, false, 0, true);
    function dataLoaded(e:Event){  
        trace( e.target.data.test);
    You will see 'This is a test' traced to the output window.
    HTH

  • When I try to install Itunes, I get this error: (translated from Norwegian) There was a network error while trying to read from the file: C: \ windows \ installer \ iTunes.msi I have tried many times to reinstall, but nothing helps, please help me.

    When I try to install Itunes, I get this error: (translated from Norwegian) There was a network error while trying to read from the file: C: \ windows \ installer \ iTunes.msi I have tried many times to reinstall, but nothing helps, please help me.

    (1) Download the Windows Installer CleanUp utility installer file (msicuu2.exe) from the following Major Geeks page (use one of the links under the "DOWNLOAD LOCATIONS" thingy on the Major Geeks page):
    http://majorgeeks.com/download.php?det=4459
    (2) Doubleclick the msicuu2.exe file and follow the prompts to install the Windows Installer CleanUp utility. (If you're on a Windows Vista or Windows 7 system and you get a Code 800A0046 error message when doubleclicking the msicuu2.exe file, try instead right-clicking on the msicuu2.exe file and selecting "Run as administrator".)
    (3) In your Start menu click All Programs and then click Windows Install Clean Up. The Windows Installer CleanUp utility window appears, listing software that is currently installed on your computer.
    (4) In the list of programs that appears in CleanUp, select any iTunes entries and click "Remove", as per the following screenshot:
    (5) Quit out of CleanUp, restart the PC and try another iTunes install. Does it go through properly this time?

  • After hours of back-up, downloading and uploading...I am now updated with all the latest Mac software. However, I no longer have access to Excel and Word. Is there a way I can access my documents in either of those? Help, please.

    After hours of back-up, downloading and uploading...I am now updated with all the latest Mac software. However, I no longer have access to Excel and Word. Is there a way I can access my documents in either of those? Help, please.

    If you have older versions of excel and word that previously ran under the Rosetta emulator (allows PowerPC code to run on Intel system), they will no longer work with Lion.
    You can use the Apple programs Pages and Numbers to access the files. They can be bought and downloaded from the App store. NeoOffice is available at http://www.neooffice.org/neojava/en/index.php which has Lion support. OpenOffice doesn't talk to Lion support, it's at http://www.openoffice.org/

  • For some reason I cannot download and install the latest version of iTunes. 11.0.2. Could you help please? Each time I try, I get a command box saying 'The feature you are trying to download is on a network resource that is unavailable. Click Ok to try ag

    For some reason I cannot download and install the latest version of iTunes. 11.0.2. Could you help please? Each time I try, I get a command box saying 'The feature you are trying to download is on a network resource that is unavailable. Click Ok to try again or enter an alternate path to a folder containing the installation package iTunes.ms in the box below.
    Please help!
    Many thanks in advance
    Ben Bentley
    West Midlands
    UK

    (1) Download the Windows Installer CleanUp utility installer file (msicuu2.exe) from the following Major Geeks page (use one of the links under the "DOWNLOAD LOCATIONS" thingy on the Major Geeks page):
    http://majorgeeks.com/download.php?det=4459
    (2) Doubleclick the msicuu2.exe file and follow the prompts to install the Windows Installer CleanUp utility. (If you're on a Windows Vista or Windows 7 system and you get a Code 800A0046 error message when doubleclicking the msicuu2.exe file, try instead right-clicking on the msicuu2.exe file and selecting "Run as administrator".)
    (3) In your Start menu click All Programs and then click Windows Install Clean Up. The Windows Installer CleanUp utility window appears, listing software that is currently installed on your computer.
    (4) In the list of programs that appears in CleanUp, select any iTunes entries and click "Remove", as per the following screenshot:
    (5) Quit out of CleanUp, restart the PC and try another iTunes install. Does it go through properly this time?

  • Iframe redirect javascript help please

    Hi:
    My client uses a loan application on another service's site, and I embedded the form in an iFrame to keep the user on my client's site.
    At the Submit of the form, it redirects to the client's home page, but it does it within the confines of the frame -- I want the redirect to go to the "top" Home page.  Unfortunately, the offsite service cannot apply a target="_top" to the redirect link script.
    The link is http://sequoiapacificmortgage.com/loan-application/
    The service said this:
    "The thank you page after the application and before the redirect URL has a unique URL.
    Is it possible to code your iframe to recognize this URL and redirect the full site to your home page rather than depending on the vLender redirect within the iframe?
    I am including the unique thank you page URL from Lori's website below, the ref_ID attribute is the unique application ID number assigned to my test application (the application ID's are generated using the first 3 letters of the applicant's first name [LYN for Lynsee] and the first 3 letters of the applicant's last name [TES for Testing] followed by the numeric sequence) but you should be able to remove that and have your custom site's code recognize the .php url which would trigger a redirect within your site's code that would take place before our system enacts its redirect to the home page within the iframe.
    (https://www.vlender.com/apps/templates/new_thank_you.php?ref_id=LYNTES998262971)"
    I have seen several references to Javascript to accomplish the desired redirect, but I am not sure how to construct it, nor if it can capture the presence of the mentioned URL to trigger it.
    Can anyone help please?  Thanks much!
    Rgds, Ned

    You are talking about JavaScript - Java and JavaScript are two completely different things. Therefore, this is not the correct area to post that question.

  • TS3510 Can't receive emails or messages with FaceTime can anyone help please thanks

    Can't receive emails or messages with FaceTime can anyone help please thanks

    Using FaceTime http://support.apple.com/kb/ht4319
    Troubleshooting FaceTime http://support.apple.com/kb/TS3367
    The Complete Guide to FaceTime + iMessage: Setup, Use, and Troubleshooting
    http://tinyurl.com/a7odey8
    Troubleshooting FaceTime and iMessage activation
    http://support.apple.com/kb/TS4268
    iOS: About Messages
    http://support.apple.com/kb/HT3529
    Set up iMessage
    http://www.apple.com/ca/ios/messages/
    Troubleshooting Messages
    http://support.apple.com/kb/TS2755
    Setting Up Multiple iOS Devices for iMessage and Facetime
    http://macmost.com/setting-up-multiple-ios-devices-for-messages-and-facetime.htm l
    FaceTime and iMessage not accepting Apple ID password
    http://www.ilounge.com/index.php/articles/comments/facetime-and-imessage-not-acc epting-apple-id-password/
     Cheers, Tom

  • Help Please! How can i get rid of shopper pro from my google chrome browser?

    Help Please! How can i get rid of shopper pro from my google chrome browser?

    Read this document about malware and adware.   The solution is almost certainly within.The Safe Mac
    http://www.adwaremedic.com/index.php
    Incidentally, it would help if you entered details of your products in your profile.   There are different answers for different items with this question.

  • HELP PLEASE :( IPHONE STUCK IN RECOVERY MODE.

    Hey so this is the story.
    i wanted to update to ios4.1 so it said i needed to restore
    so i did and then it gave me error codes (1004). It would not let me restore and update. so now i am stuck in recovery mode.
    i really need help please. i have tried irecovery but no luck.
    someone please help my iphone is a must have. i need it tomorrow.
    i have
    Windows7 64bit
    iPhone4
    please someone help.

    Doing a search on Google revealed this:
    if you ever edited your hosts file ...change it back. basically do the reverse of this to about step 5:
    mac
    http://www.iclarified.com/entry/index.php?enid=7556
    windows
    http://www.iclarified.com/entry/index.php?enid=7557
    (editing the file back to the original worked for me)
    Follow those instructions and see if that helps.

  • TS1741 Bought an app last night.  Tried to buy another an hour later and got the window that says "Cannot connect to iTunes Store".  Still unable to connect today.  Tried restarting router. Help please....thanks!

    Bought an app last night.  Tried to buy another an hour later and got the window that says "Cannot connect to iTunes Store". Still unable to connect to store today.  Tried restarting router.  Help please....thanks.

    The Complete Guide to Using the iTunes Store
    http://www.ilounge.com/index.php/articles/comments/the-complete-guide-to-using-t he-itunes-store/
    Can't connect to the iTunes Store
    http://support.apple.com/kb/TS1368
    iTunes: Advanced iTunes Store troubleshooting
    http://support.apple.com/kb/TS3297
    This works for some users. Not sure why.
    Go to Settings>General>Date and Time> Set Automatically>Off. Set the date ahead by about a year.Then see if you can connect to the store.
     Cheers, Tom

  • Php database.php help!!

    heya everyone im making a empire building game in php for now just to see how it go's etc
    anyway ive got basics sorted kind of
    but now im getting ALOT of errors in my database.php file ALOT
    here is the the errors i get on homepage of game site,.
    "Warning:  mysql_query(): supplied argument is not a valid MySQL-Link resource in /www/zzl.org/s/p/o/spoonynicks/htdocs/include/database.php on line 380
    Warning:  mysql_num_rows(): supplied argument is not a valid MySQL result resource in /www/zzl.org/s/p/o/spoonynicks/htdocs/include/database.php on line 381
    Warning:  mysql_close(): supplied argument is not a valid MySQL-Link resource in /www/zzl.org/s/p/o/spoonynicks/htdocs/include/database.php on line 383
    Warning:  mysql_query(): supplied argument is not a valid MySQL-Link resource in /www/zzl.org/s/p/o/spoonynicks/htdocs/include/database.php on line 402
    Warning:  mysql_numrows(): supplied argument is not a valid MySQL result resource in /www/zzl.org/s/p/o/spoonynicks/htdocs/include/database.php on line 404
    as you can tell this anit so good for me
    in my databse file this is the first error line
    " /* Calculate number of users at site */
          $q = "SELECT * FROM ".TBL_ACTIVE_USERS;
        $result = mysql_query($sql,$con);
    echo mysql_num_rows($result);
    im stuck i have changed everything i can think of ive got new codes etc
    HERE IS THE DOWNLOAD LINK FOR DATABASE.PHP
    please download file and please if you can help please please do so.
    THANK YOU SO MUCH!!!!
    http://www.2shared.com/file/9HjFaj2p/database.html

    Looks to me like TBL_ACTIVE_USERS is a MySQL table name?  If so you need to make it part of the string.
    $q = "SELECT * FROM TBL_ACTIVE_USERS";
    If TBL_ACTIVE_USERS is a variable, then it needs the '$'..   $TBL_ACTIVE_USERS
    Am I not understanding the definition of TBL_ACTIVE_USERS ??
    Good luck.

  • HT204380 I can't access my FaceTime and messages through my iPod touch, I need help please!!!

    I can't access my FaceTime and messages through my iPod touch, I need help please!!!

    Using FaceTime http://support.apple.com/kb/ht4319
    Troubleshooting FaceTime http://support.apple.com/kb/TS3367
    The Complete Guide to FaceTime + iMessage: Setup, Use, and Troubleshooting
    http://tinyurl.com/a7odey8
    Troubleshooting FaceTime and iMessage activation
    http://support.apple.com/kb/TS4268
    Using FaceTime and iMessage behind a firewall
    http://support.apple.com/kb/HT4245
    iOS: About Messages
    http://support.apple.com/kb/HT3529
    Set up iMessage
    http://www.apple.com/ca/ios/messages/
    Troubleshooting Messages
    http://support.apple.com/kb/TS2755
    Setting Up Multiple iOS Devices for iMessage and Facetime
    http://macmost.com/setting-up-multiple-ios-devices-for-messages-and-facetime.htm l
    FaceTime and iMessage not accepting Apple ID password
    http://www.ilounge.com/index.php/articles/comments/facetime-and-imessage-not-acc epting-apple-id-password/
    Unable to use FaceTime and iMessage with my apple ID
    https://discussions.apple.com/thread/4649373?tstart=90
    For non-Apple devices, check out the TextFree app https://itunes.apple.com/us/app/text-free-textfree-sms-real/id399355755?mt=8
    You posted in the iPad forum instead of the iPod forum. To get answers to your question, next time post in the proper forum. See https://discussions.apple.com/index.jspa  I'll request that Apple relocate your post.
     Cheers, Tom

  • Xcode entering input error help please

    When i run Xcode 4.5.2 on Lion and i need to enter some input (ex. cin.getline(array,10)), i need to press enter two times to keep going.
    Here is the code:    
    player1 and palindrom are arrays of char
    and here is the output:
    I enter Juan in player1 then i press [Enter] and i need to press another [Enter] if i want the prgram to continue
    and when i enter the palindrom is not stored in the array, instead the second [Enter] is stored on the palindrom array.
    Help please
    i dont know what to do i have looked on the internet but i havent found anything to solve this problem......

    You are mixing up two different ways of getting user input.
    1. getline -- a standard <stdio> function which reads user input and a return;
    2. cin -- a C++ <iostream> function which reads user input and a return.
    See http://crasseux.com/books/ctutorial/getline.html and http://www.htmlhelpcentral.com/messageboard/showthread.php?4359-C-Tutorial-1-cou t-cin for the proper way to use either one of them; you cannot use both in the same command.
    quiban92 wrote:
    i dont know what to do i have looked on the internet but i havent found anything to solve this problem......
    Those two links were the very first hits on a search for "getline tutorial" and "cin tutorial".

  • Constant rebooting, help please!

    Constant rebooting, help please!
    Since suddenly yesterday, my computer reboots itself always
    during the Windows XP start-up, right before it should
    display "Welcome" (Choose user profile) screen. This started
    yesterday when I was just surfing the net and listening to
    some mp3s, I hadn't installed anything new for a while.
    Now I can't get the system running even in safe mode, nor does
    System restore help. After the progress bar of Windows XP
    Home Edition, the machine just beeps and reboots.
    There seems to be no heat problem (specs below), because I
    can get to the bios settings by pressing Del, and I can
    browse them as long as I want.
    I am pretty sure that there are no viruses, my McAfee
    updates itself very often. I have a ZoneAlarm firewall to
    protect agains hacking.
    I've had some reboots earlier, maybe twice a week. This
    began after I changed my processor to AMD Athlon XP 3000+.  
    But now something made my setup completely unstable.
    I know I don't have the latest bios drivers, the old ones
    did not work (had to use System Restore to get the PC
    running after installing them, but I didn't have a chance to
    install the latest ones before this catastrophe happened).
    Should I do a repair install of WinXP using the install cd?
    What should I do, and what might be causing the problem? Any
    help is greatly appreciated. Specs are below:
    CPU:AMD Athlon XP 3000+
    MOBO: KT4V
    OS: WinXP Home
    GC: ATI Radeon 9600
    HD: Hitachi 120 Gb
    RAM: 1024 DDR (2 x 512)
    Power: Nexus NX3500 (350 W) - AC Input 115/230V - 10/5A, 60/50Hz
    Heat:
    CPU 51 C
    System: 34 C
    CPU Fan Speed: 3813 rpm
    Volts:
    VCore: 1,648 V
    +5V: 4,975 V
    +12V: 12,106 V
    -12V: -11.743 V
    -5V: -4,976
    Battery: 3,360
    +5 SB: 4,921
    Frequency/Voltage Control:
    Spread Spectrum disabled
    CPU FSB 166 Mhz
    CPU Ratio x12,5/x13
    CPU Core 1,650
    DDR Voltage Auto
    Termination Vol Auto
    AGP VOltage Auto

    Hello.
    You motherboard does not support an XP3000+ unless you have BIOS 1.8.
    Do you have any BIOS updates? I recommend the latest one.
    http://www.msi.com.tw/program/support/bios/bos/spt_bos_detail.php?UID=362&kind=1
    ====================================
    "I know I don't have the latest bios drivers, the old ones
    did not work (had to use System Restore to get the PC
    running after installing them, but I didn't have a chance to
    install the latest ones before this catastrophe happened)."
    ====================================
    You mean CHIPSET drivers, VIA 4in1? BIOS is not part of OS  
    The AMD XP3000+ CPU that you have, is it the 333Mhz FSB version or the 400Mhz FSB version?
    You board does not support the 400Mhz FSB version.
    You RAM, are they the same make and model
    Are they both PC2700 or PC3200?
    Have you tried 1 stick at a time?

  • I keep being asked to update my Safari but when I do a Software update it scans but never gives me a list and just says no new updates. Help please!

    I keep being asked to update my Safari but when I do a Software update it scans but never gives me a list and just says no new updates. Help please!

    There are no updates to either OS 10.5.8 or Safari 5.0.6.
    If you need a later version of Safari you must first upgrade your operating system to a later version of OS X.

Maybe you are looking for