Jump to content

rhock_95

Members
  • Posts

    120
  • Joined

  • Last visited

    Never

Everything posted by rhock_95

  1. I do appreciate the efforts and the replys but I am afraid they are of no help... I have tried combining both my existing forms (query text field) and the captcha forms (security code text field) to no end...I am still unable to get anything to work with a single "submit" button... the query will execute but the captcha is ignored or the captcha executes but I get no query results...??? viewing existing (html) forms is of no help what so ever... abd BTW are youy seriously using the captcha cited on your link? 12 (jumbled) characters ? very confusing...! can anyone help me with the form syntax required to execute two scripts with a single button where the the qury script will not execute unless the security code is correct?
  2. <?php $captcha_value = $_POST['captcha']; if ($captcha_value == $test_value) { // CAPTCHA IS OKAY, GO AHEAD AND DO SEARCH // Search code in here. } else { // CAPTCHA IS NOT OKAY. SHOW AN ERROR $error = "CAPTCHA is not okay."; echo $error; } ?> again...what I am seeking is the exactly what the form looks like (complete syntax) can you show me what the form would look like that executes your php ?
  3. The "original HTML page" is what AI am trying to develop...how do I get a single "submit" button to execute both the captcha and the query scripts?
  4. What I am trying to avoid is two forms...I don't want a user to have to enter the security code before being presented with the actual serch (query) form... I am looking for a single form with both query and security code text boxes using a single "submit" button...but if the security code is incorrect echo error message/form again
  5. can anyone show an example that incorporates a captcha security code element into an existing script/form that queries a database? Of the many captcha scripts that have "demos" I can't get any of them to work within any of my existing search scripts...The captcha scripts work but only as a gateway to the search scripts (different page or frame etc)... ...How can I get the query search to only execute if/when the correct security code is entered...by clicking a single "submit/search" button ...that executes both the captcha and the query scripts?
  6. The initial query posts (last) last and returns the records that match the "$query" what I'm trying to do is run a second query (from an integrated form $first) that when submitted sorts the initial results by a second column (first)...where the second query input can be just a single letter (first initial etc)...
  7. thanks for the reply...but that does not allow the user to select a "first initial/name" etc...
  8. what I am hoping to do is just reuse the original query and run a second query using the original $query (variable) what I am seeking is the correct syntax $sql="select * from my_table where last='$query' and first LIKE '%$first%' ORDER BY first"; the above is not working "$query is the original "last name" searched for
  9. A script lets users search a database for 'last name' and displays those results what is the simplest way to let them sort those (further query) results by 'first name' ?
  10. the (HTML) needs to be a different doc...otherwise the pagination menu/display is printed That's what I said to do. Put the php code in a separate file where the form points to in the action field. It does not work... it still prints all the records
  11. the (HTML) needs to be a different doc...otherwise the pagination menu/display is printed
  12. I have no idea what this is, sorry
  13. Eh, can you tell me exactly what you need? I reread your original post and you say that you want it to display an error if nothing is entered but also append that error to the top of the form? Not really sure what you need. I just want the script to return a message stating the form was submitted without any data...please click the back button and try again...etc right now everything I have tried still pulls down all the records...some of the snippets I've tried print the error message but the script still pulls down all the records and some even when a valid query is entered it still prints the error message
  14. the form is just an html doc it calls the script from the action parameter Exactly. You said you wanted it to show the form again if nothing was submitted. This checks that and then redirects to wherever you want if the data is correct. You should consider doing js data validation too... so where does this code call the script?
  15. the form is just an html doc it calls the script from the action parameter
  16. throws a line error Parse error: parse error, expecting `'('' if empty($query) { echo "error message here";}
  17. there is only one variable "$query"
  18. Can you explain how to use this snippet? do I have to declare the variables? if so how?
  19. if empty($_POST[variable]||$_POST[variable2]) { echo "sorry you must fill in the form";}
  20. that throws a line error regardless of where in the script I set it Parse error: parse error, expecting `'(''
  21. exactly if the form is submitted with no entry in the form field display message
  22. sorry I can't do that...without stripping all the comments the html form is a different page/file the action of the form(page) calls the script some of the suggestions in already posted print the error message but the script still returns all the records
  23. Yes thanks for the efforts... it throws numorious line errors starting with }else{ insert record ;}
×
×
  • 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.