Click here to Skip to main content
15,882,329 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
<link rel="stylesheet" type="text/css" href="css/bootstrap.css">
<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript" src="js/bootstrap.min.js"></script>
<script type="text/javascript" src="js/jquery.history.js"></script>
  <a class="btn btn-primary" data-toggle="modal" href="" data-target="#myModal" onclick="dummyurl()">Click me</a>

<!-- Modal -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-body">
      its modal content
      </div><!-- /.modal-content -->
  </div><!-- /.modal-dialog -->
</div><!-- /.modal -->

<script type="text/javascript">
 var dummyurl = (function (window, undefined) {
    History.pushState(null, null, "?ChangePassword");

After i click button, open modal dialop with dummy url
like forgetpassword.html?ChangePassword

but i need url back to forgetpassword.html
when i close modal dialog box and also click outside modal dialog ,it should back to original url
Updated 29-Jul-14 22:18pm

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900