• I want to insert a record in to the backend table from the insert form the issue is when we submit this form it shows 404 page not found error please help me to solve this error. I m at basic level in php if i made any mistake in syntax im sorry for that.
    <!–****Insertion*****–>
    [insert_php]
    echo “done”;
    if(isset($_POST[‘ins’])){
    extract($_POST);

    $ins=mysql_query(“insert into BENCH values (null,’$name’,’$profile’,$experience,’$phone’,’$email’,’$immigration’,$marketingrate,’$relocation’,’$noticeperiod’,’$consultantemployer’,’$status’)”);
    if($ins==1)
    echo “Record Added Successfully”;
    else
    echo mysql_error();
    }
    [/insert_php]
    <form method=”POST” action=””>
    <label>NAME: </label>
    <input type=”text” name=”name”></br>
    <label>PROFILE: </label>
    <input type=”text” name=”profile”></br>
    <label>EXPERIENCE: </label>
    <input type=”text” name=”experience”></br>
    <label>PHONE: </label>
    <input type=”text” name=”phone”></br>
    <label>EMAIL: </label>
    <input type=”text” name=”email”></br>
    <label>IMMIGRATION: </label>
    <input type=”text” name=”immigration”></br>
    <label>MARKETINGRATE: </label>
    <input type=”text” name=”marketingrate”></br>
    <label>RELOCATION: </label>
    <input type=”text” name=”relocation”></br>
    <label>NOTICEPERIOD: </label>
    <input type=”text” name=”noticeperiod”></br>
    <label>CONSULTANTEMPLOYER: </label>
    <input type=”text” name=”consultantemployer”></br>
    <label>STATUS: </label>
    <input type=”text” name=”status”></br>
    <input type=”submit” name=”ins” value=”submit”></br>
    </form>
    <!–****Insertion*****–>

    https://wordpress.org/plugins/insert-php/

Viewing 3 replies - 1 through 3 (of 3 total)
  • If you get a 404 page not found message, then that is what it is. The server is unlikely to make a mistake.

    If your permalinks setting is anything other than plain, that may be the problem. The URL rewrite may be effective only for method=”get” and not for method=”post”. NOTE: I’m not saying that’s the reason, just that it’s something to investigate. You might try temporarily changing to method=”GET” to see if you still see the 404.

    Unfortunately, I’m unable to help beyond this. It would require physical access to your machine or a duplicate WordPress installation to be definite about the solution.

    Will

    Thread Starter siddhartha dasar

    (@siddhartha-dasar)

    I tried GET method but no use same 404 error is the output

    I’m sorry to hear that.

    It’s still true, if you get a 404 error from the server then it really is a 404 error. But I’m unable to suggest anything other than I already suggested. It may require access to the computer to resolve this for you.

    Will

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Insert record error’ is closed to new replies.