Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!
  • Guest, before posting your code please take these rules into consideration:
    • It is required to use our BBCode feature to display your code. While within the editor click < / > or >_ and place your code within the BB Code prompt. This helps others with finding a solution by making it easier to read and easier to copy.
    • You can also use markdown to share your code. When using markdown your code will be automatically converted to BBCode. For help with markdown check out the markdown guide.
    • Don't share a wall of code. All we want is the problem area, the code related to your issue.


    To learn more about how to use our BBCode feature, please click here.

    Thank you, Code Forum.

PHP $_POST current_password won't post to another page

220061

Well-Known Coder
Hi so right now I'm just thinkering around to slowly in the end try to make a password reset page
right now I want to post variable to my reset password backend page but I can't seem to send any post variables to this page?
I'm not seeing what I'm doing wrong
code:
passwordreset.php
PHP:
<?php
// session_start();
include "config.php";?>
<!--het gaat hier over tokens ik kan hier dus beter het backend boek voor gaan gebruiken om dit af te maken-->
<head>
<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<!------ Include the above in your HEAD tag ---------->
</head>
<style>
    .background{
        background: rgb(2,0,36);
        background: linear-gradient(90deg, rgba(2,0,36,1) 0%, rgba(9,9,121,1) 35%, rgba(0,212,255,1) 100%);
        margin-top: 30px;
        margin-left: 25%;
        margin-right: 25%;
        border-radius: 25px;
        color: white;
    }
    h3{
        display: flex;
        justify-content: center;
        padding-top: 20px;
    }
    .row{
        display: flex;
        justify-content:center;
        padding-top: 50px;
    }
    .pass_show{position: relative}
.pass_show .ptxt {
position: absolute;
top: 50%;
right: 10px;
z-index: 1;
color: blue;
margin-top: -10px;
cursor: pointer;
transition: .3s ease all;
}
.pass_show .ptxt:hover{color: #333333;}
</style>
<div class="container">
    <div class="background">
    <h3>Reset wachtwoord </h3>
    <div class="row">
        <div class="col-sm-6">
        <form method="post" action="wachtwoordresetback.php">
            <label>Current Password</label>
            <div class="form-group pass_show">
                <input type="password" id="current_pass" class="form-control" placeholder="Current Password" required>
            </div>
               <label>New Password</label>
            <div class="form-group pass_show">
                <input type="password" class="form-control" placeholder="New Password">
            </div>
               <label>Confirm Password</label>
            <div class="form-group pass_show">
                <input type="password" class="form-control" placeholder="Confirm Password">
            </div>
            <div class="form-group">
                <input name="recover-submit" class="btn btn-lg btn-primary btn-block" value="Reset Password" type="submit">
            </div>
                      
                <!-- <input type="hidden" class="hide" name="token" id="token" value="">  -->
        </form>
            
        </div> 
    </div>
</div>
</div>
<script>
      
$(document).ready(function(){
$('.pass_show').append('<span class="ptxt">Show</span>'); 
});
 
$(document).on('click','.pass_show .ptxt', function(){
$(this).text($(this).text() == "Show" ? "Hide" : "Show");
$(this).prev().attr('type', function(index, attr){return attr == 'password' ? 'text' : 'password'; });
}); 
</script>

1644921977743.png
 

Attachments

  • 1644921951542.png
    1644921951542.png
    183.7 KB · Views: 1
Back
Top Bottom