APD Toronto
asked on
JS Reload without Query String
Hi Experts,
Using JS how can i Reload tthe same page without Query String
Using JS how can i Reload tthe same page without Query String
ASKER
For some reason its not truncating. I do see my dummy alert('p');, but the query string remains...
<html>
<head>
<meta name="robots" content="index,follow" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="google-site-verification" content="Z5bx5dQBjZlorshNdQSqwhgaAJesfaM561PZSjeYMnY" />
<meta name="y_key" content="95b4b6bb4fe3c93f" />
<meta name="description"
content="we take pride in offering the highest quality tour at the best price,whether our legendary Toronto hop-on hop-off ticket with a free Harbour and Islands Cruise or our famous Niagara Falls day trip" />
<meta name="keywords"
content="bus company, bus tours, city sightseeing, city tours, cruise, cruises, event
events, hotel, restaurant, restaurant listings, shopping, shops, shop in, niagara, niagara falls, sightseeing, sightseeing tours, things to do, tour of, touring, tourist, tourist attractions, tourist information, tours, travel, travel guide, trips, vacation, what to do" />
<link href="../css/navigation.css" rel="stylesheet" type="text/css" />
<title>CitySightseeing Niagara Falls</title>
</head>
<body bgcolor="#6600CC">
<center>
<table border="0" width="1024">
<tr>
<td>
<table border="0" width="100%">
<tr>
<td width="495" valign="top">
<img border="0" src="../images/CSST_Logo-small.jpg" width="463" height="174" align="right"></td>
<td width="555" valign="top">
<img border="0" src="../images/CSSN_Logo-small.jpg" width="455" height="173"></td>
</tr>
</table>
<p align="center"><u><font color="#FFFF00" size="7"><b>
Administration</b></font></u></p>
<p></p>
<center>
<table border="0" width="100%" cellspacing="0" cellpadding="5">
<tr>
<td bgcolor="#5CC7EE"><b><font face="Arial" size="5">
CSST & CSSN Administration</font></b></td>
</tr>
<tr>
<td bgcolor="#FFFFFF"> <p><b><i><font face="Arial">
<link href="css/gratuity.css" rel="stylesheet" type="text/css" />
<link href="utilities/jquery.calendars.picker.css" rel="stylesheet" type="text/css" />
<form action="gratuity2.php" method="get">
<div id="divSearchArea">
<div id="divConfGroup" class="divSrchBox">
<div class="divSearchCrit">
<label for="txtConf">Conf #</label>
<input type="text" id="txtConf" name="txtConf"
value="" />
</div>
<div class="divSearchCrit">
<label for="txtGroup">Group Name</label>
<input type="text" id="txtGroup" name="txtGroup"
value="" />
</div>
</div>
<div id="divCharterDateNo" class="divSrchBox">
<div class="divSearchCrit">
<label for="txtChartDate">Charter Date</label>
<input type="text" id="txtChartDate" name="txtChartDate" readonly="readonly"
value="" />
<!--Common JS Libraries, also needed for Date Picker -->
<script type="text/javascript" src="utilities/jquery.js"></script>
<script type="text/javascript" src="utilities/jquery.plugin.js"></script>
<!--JS=Specific to Date Picker Control-->
<script type="text/javascript" src="http://localhost/CSST_subdomains/admin.citysightseeingtoronto.com//utilities/jquery.calendars.min.js"></script>
<script type="text/javascript" src="http://localhost/CSST_subdomains/admin.citysightseeingtoronto.com//utilities/jquery.calendars.plus.min.js"></script>
<script type="text/javascript" src="http://localhost/CSST_subdomains/admin.citysightseeingtoronto.com//utilities/jquery.calendars.picker.min.js"></script>
<script type="text/javascript">
$(function() {
//retrieve default commands
var todayCommand = $.extend(true, {}, $.calendarsPicker.commands);
//override only "today.action"
todayCommand.today.action = function(inst){
//show popup
$.calendarsPicker.showMonth(this);
//update value of text field
$(this).val( $.calendars.newDate() );
// uncomment the following line if you want the popup to auto-hide
$.calendarsPicker.hide(this);
//Move focus out
$(this).blur();
};
//use the altered commands saved in "todayCommand" to override the default settings for each text control
$("#txtChartDate").calendarsPicker(
{commands:todayCommand,
firstDay: 1, dateFormat: 'yyyy-mm-dd'});
});
</script>
</div>
<div class="divSearchCrit">
<label for="txtChartNo">Charter #</label>
<input type="text" id="txtChartNo" name="txtChartNo"
value="69" />
</div>
</div>
<div id="divGratuity" class="divSrchBox">
Show records with gratuity that has been:
<div class="divSearchCrit">
<input type="radio" name="optGratuity" id="optPaid" value="paid"
>
<label for="optPaid">Paid</label> <br />
<input type="radio" name="optGratuity" id="optOwing" value="owing"
>
<label for="optOwing">Owing</label> <br />
<input type="radio" name="optGratuity" id="optBoth" value="both"
checked>
<label for="optBoth">Paid & Owing</label> <br />
</div>
</div>
<div id="divSubmitReset">
<button id="btnSubmit" type="submit">Search</button>
<button id="btnReset" onclick="resetForm();">Reset</button>
</div>
<div class="divSearchCrit hidden">
<label for="txtPage">txtPage</label>
<input type="text" id="txtPage" name="txtPage"
value="1" />
</div>
</div>
</form>
</font></i></b></p>
<span id="siteseal">
<p> </td>
</tr>
</table>
</center>
</div>
<!--end ProgressBar-->
<!--end NavigationMenu2-->
</p>
</tr>
</table>
</center>
</body>
</html>
<script type="text/javascript">
// $(document).on('ready', function(){
function resetForm(){
alert('p');
window.location = window.location.href.split("?")[0];// 'gratuity2.php' + ' ';
}
// });
</script>
ASKER
It should happen when you click Reset.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you
No problem, glad it worked out!
Noticed you're not using any basic helpers on your CSS.
Check out Bootstrap. Will make your life a lot easier :)
Noticed you're not using any basic helpers on your CSS.
Check out Bootstrap. Will make your life a lot easier :)
Open in new window
Working demo