Jump to content

robsstevejobs

Members
  • Posts

    30
  • Joined

  • Last visited

Everything posted by robsstevejobs

  1. Hello, How I can filter the password with the function preg_mettre by specifying optional special charater but the first letter is mandatory uppercase is the rest or lowercase.
  2. Hello Team , how can i check the duplicate record in the databsae rows in PHP or PDO and mysqli
  3. hi sir, how can i contact him about ios update software you have their address?
  4. Hi sir, you can help me find this server to distribute the updates in my website. here is the link I found: updates-http.cdn-apple.com/2019SpringFCS/fullrestores/041-68314/CC3C4D6, in other site when I try to download it outside the iTunes
  5. ok I understand, if you have a link you can send me to try to change the code
  6. Hi guys, someone can help me for my database. I will only when registering the form that make the comparison to enter it, like username and email using ajax and php. this is my code <?php if(isset($_POST['email'])){ $servername = "localhost"; $username = "root"; $password = "Robss123"; $dbname = "news"; // Create connection $conn = new mysqli($servername, $username, $password, $dbname); $email = $_POST['email']; // Check connection if ($conn->connect_error) { die("Connection failed: " . $conn->connect_error); } $name = mysqli_real_escape_string($conn, $_POST['name']); $email = mysqli_real_escape_string($conn, $_POST['email']); $sql = "INSERT INTO guyst(name,email) VALUES('$name', '$email')"; $sql ="SELECT *FROM guyst WHERE guyst_email='$email'"; $result = mysql_query($conn,$sql); if($result->num_row >0) { echo 'cet email est déjà utilisée'; } if ($conn->query($sql) === TRUE) { echo "New record created successfully"; } else { echo "Error: " . $sql . "<br>" . $conn->error; } } $conn->close(); function test_input($data) { $data=trim($data); $data=stripslashese($data); $data=htmlspecialchars($data); return $data; } ?>
  7. I did not understand what you mean ...
  8. hi guys, how can i check a username and email already exist in my database using php and ajax
  9. Hi guys, can you explain to me what can I do about any comment post
  10. Hi guys, I'm going to have my database record a unique email address what can I do in the code.
  11. in my case the code above, there are two functions the first function does not run, but jquery validation that run in the second position what can i do to run all the two
  12. yes I ask if in a file js, I could put more function inside this file.
  13. this is my query code $(document).ready(function(){ $('#submit').click(function(event){ event.preventDefault(); var name = $('#name').val(); var email = $('#email').val(); if(name == '' || email == '') { $('#error_message').html("Tous les champs sont obligatoire"); } else { $('#error_message').html(''); $.ajax({ type:'POST', url:'connexion.php', data:{name:name, email:email}, success:function(data){ $("form").trigger("reset"); $('#success_message').fadeIn().html(data); setTimeout(function(){ $('#success_message').fadeOut("Slow"); }, 2000); } }); } }); }); , $(function(){ $('#formu').validate({ rules:{ email:{ required:true, email:true } } }); }); </script>
  14. I will associate all the code jquery in the same file, unfortunately it does not work
  15. thank you it works, but I have little concern, I want to associate in the same file js validation and ajax function. instead of executing all the code, it runs a single
  16. thank you I try and then I will come back to you.
  17. where the link above ??
  18. how to fix this problem, because i made the ajax call but still reload the page and then it does not insert the data into database
  19. but the url does not function on, i will save the data in the database, i notice the insert.php link does not work to save the information in the database
  20. Look my code <form id="news" action="" method="POST"> <label for="name">Nom</label> <input type="text" name="name" id="name" placeholder="votre nom" required> <Br> <br> <label for="email">E-mail</label> <input type="email" name="email" id="email" placeholder="votre mail" required> <br> <br> <input type="submit" name="submit" id="submit" value="newsletters"> <span id="error_message" class="text-danger"></span> <span id="success_message" class="text-success"></span> </form> This is Ajax code $(document).ready(function(){ $('#submit').click(function(){ var name = $('#name').val(); var email = $('#email').val(); if(name == '' || email == '') { $('#error_message').html("All field are required"); } else { $('#error_message').html(''); $.ajax({ url:"validate.php", method:"POST", data:{name:name, email:email}, success:function(data){ $("#news").trigger("reset"); $('#success_message').fadeIn().html(data); setTimeout(function(){ $('#success_message').fadeOut("Slow"); }, 2000); } }); } }); }); </script>
  21. I have a problem with my form, I go when I execute the submit button, I stay in the same page without refreshing php page
  22. Hi thanks ! it works, but I have a problem running the page does not refresh. I used AJAX but it does not work
  23. thank you guys, I'll come back and give you the result of my newsletters.
  24. Hi guys, is it necessary to validate the form with PHP only, or I can also validate it with Jquery.
  25. you are sure after validating the form empty space would no longer be in the database
×
×
  • Create New...