But if you only need a “toggle” flag in the url’s query string it might be easier to just have a single value in the ur’s query string and then check if that value is there when the page loads.
Something like this:
In account.htm have a link with a href of dashboard.htm?trigger
Then in dashboard.html check if the string “trigger” is in the url’s query string and then act accordingly
<script type="text/javascript">
if(window.location.search.substring(1) == 'trigger') {
// do this
} else {
//do that
}
</script>
Having just a single value saves you having to parse the query string.