Jump to content

ilikephp

Members
  • Posts

    350
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

ilikephp's Achievements

Advanced Member

Advanced Member (4/5)

0

Reputation

  1. capital C :S Thanks a lot...
  2. Hello, I am using the send mail form, everything is sent to my mail except the country field, it is sending blank. $name = $_REQUEST['name'] ; $phone = $_REQUEST['phone'] ; $email = $_REQUEST['email'] ; $country = $_REQUEST['country'] ; $message = $_REQUEST['message'] ; $headers = "From: $email"; $sent = mail( $to, $subject, $name."\n".$phone."\n".$email."\n".$country."\n".$message, $headers); How could it be fixed plz? Thx
  3. Hello, I need to add rel="..." in the first part of the script but it is not working, below is the script: echo " <a href='products/".$image[$abc]."' target='_blank'><img border=0 src='products/thumbs2/".$image[$abc]."' /></a>"; Thank you,
  4. Hello! When I fill my php form in internet explorer or firefox and click on submit, the spry validaitons will be displayed; but using google chrome or safari they are not displayed. I tried the form using safari but on localhost, they are displayed but over the internet the form will skip to the database and will not be validated. What could be the problem plz?
  5. The form is too big, I just need to echo 'Fix your Errors please anywhere, could be next to the submit button' is this one correct? <?php if($_POST['form1'] == 0){ echo 'Check your errors'; } ?>
  6. Hi, I have a form, it is working fine and it validates using spry... When the user clicks the submit button and all the fields are filled, he will be redirected to the homepage page if not the required fields will be highlighted, I want to add a message next to the submit button or a popup that displays: "Plz check the errors" this is the code, I think I should add an echo somewhere ?! if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) { $insertSQL = sprintf( GetSQLValueString($_POST['IP'], "text")); . . . mysql_select_db($database_myform, $myform); $Result1 = mysql_query($insertSQL, $myform) or die(mysql_error()); if (isset($_SERVER['QUERY_STRING'])) { $insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?"; $insertGoTo .= $_SERVER['QUERY_STRING']; } header('Location: homepage.php'); } ?>
  7. Now it is fixed, the problem was fixed by adding the connection again in the field that brings the data from mysql
  8. I want them to be displayed in the same field with a comma to separate them. I put this code in the form: <input type="checkbox" name="father[]" value="answer 1" /> answer 1</label> <br /><label> <input type="checkbox" name="father[]" value="answer 2" /> answer 2 </label> <br /> <?php $fatherValue = (isset($_POST['father']) ? implode(',', $_POST['father']) : ''); ?> and in the $insertSQL = sprintf("INSERT INTO .... GetSQLValueString($fatherValue, "text"), I dont know if I did something wrong but I am getting Null value in the Mysql database
  9. Hi, I am using this code to display the info in mysql database to dropdown list, it is working good on the localhost, when I upload everything the form is still working fine, but the drop down list are not displaying anything!! What could be the problem? * I did upload all the tables also <?php $query="SELECT ID, nationality FROM nationalities"; $result = mysql_query ($query); echo "<select name=first_nationality_father value=''></option>"; echo "<option value=''>-- Choose one --</option>"; while($nt=mysql_fetch_array($result)){ echo "<option value=$nt[nationality]>$nt[nationality]</option>"; } echo "</select>"; ?>
  10. Thx for your help! I am trying to put the values of the fields checked in the mysql databse, for example: Languages spoken by the father: * German * English * French Many fields could be checked Should I use what you wrote?
  11. the code that I wrote in the previous reply was correct?
  12. Unknown column 'answer 2' in 'field list'
  13. I tried to put this in my code: in the insert to database: GetSQLValueString($_POST['father'][1], $_POST['father'][2]), In the form: <label> <input type="checkbox" name="father[]" value="answer 1" /> answer 1</label> <br /><label> <input type="checkbox" name="father[]" value="answer 2" /> answer 2 </label> <br /> I got an error :S
  14. <input type="checkbox" name="father" value="answer 1" /> answer 1</label> <br /> <label> <input type="checkbox" name="father" value="answer 2" /> answer 2</label>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.