Good day, I'm learning Jquery mobile and I'm stuck with a simple thing, that maybe should be solved in a minute.
I have made a simple 2 page site, all windows are single HTML PAGES, so I have index.php, contacts.php and sendmail.php (which is only for mailing purposes).
I navigate from index to contacts smoothly, then I fill the form and click submit, the sendmail.php has a header:('location:')
that redirect the user to index.php after sending the mail, but when I get back to index.php, the navbar is pointing "sendmail.php" which is not right.
is there a way to easy change it (maybe reload a page)?
the form action is like this:
<form action="sendmail.php" method="POST">
links from page to another are like: first page:
<script type="text/javascript">
$( function() {
$('body').bind( 'swipe', function( e ) {
$.mobile.changePage( "contatti.php", {
transition: "slide",
reverse: true,
changeHash: false,
reloadPage: true
});
} );
} );
</script>
<a data-role="button" data-transition="flip" href="contatti.php" data-icon="info"
data-iconpos="left" class="ui-btn-right" data-prefetch="true">
Info
</a>
and then the action as described, when i get back to the first page, i have the url like this:
/mobile/#/mobile/sendmail.php