location-href Questions
2
Solved
I need to reload a page in a success of an ajax call.
I'm seeing some code (not mine) and there are two ways:
success: function(obj) {
//code
location.href = location.href;
}
or
success: functio...
Havenot asked 7/12, 2016 at 14:45
3
Solved
I upgraded the Jest library to v25 and all unit tests that were checking location change are failing.
I checked a couple of issues opened on the Jest repository, but I didn't actually understand ho...
Transaction asked 28/1, 2020 at 17:27
5
I have the following code that's allowing me to switch between desktop and mobile versions of my website,
<script type="text/javascript">
if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMob...
Finbur asked 2/7, 2015 at 13:0
7
Solved
Is there a way to have all links on a page be relative to the root directory?
For example, on www.example.com/fruits/apples/apple.html I could have a link saying:
<a href="fruits/index.html"&g...
Heckelphone asked 5/4, 2011 at 23:1
5
Solved
I got a javascript onclick event inside a template, and I want to call one of my Django urls with an id parameter from it, like this :
$(document).on('click', '.alink', function () {
var id = $(th...
Lenticularis asked 18/5, 2016 at 22:21
6
Solved
How to pass this variable value here? Below code is not working. And all other discussions on Stackoverflow are unclear.
<script type="text/javascript">
function check()
{
var dist = docu...
Wainscoting asked 25/12, 2013 at 5:20
2
Here in my javascript function im using location.href as follows
location.href = "../Floder1/result.jsp"; it is working fine but when i used fortify tool it is showing Cross-site Scripting which ...
Unprofessional asked 22/8, 2014 at 6:35
3
Solved
I have an index.html which contains my Elm app. The Elm app uses various GETs to an API served by the same server as the one that serves the index.html.
Rather than hardcode the URLs in my Elm cod...
Whipsaw asked 3/8, 2018 at 0:0
2
Solved
I'm using JavaScript redirects after ajax call (after update content). I've tried below methods, all are very slow. In Network tab it shows waiting time is around 4.44 to 5 seconds. (Which is very ...
Compendium asked 26/2, 2016 at 7:28
1
Solved
As an example, I have the following html:
<body>
<script src="code.js?q=xyz"></script>
</body>
I want to be able to read the q=xyz query parameter from within code.js. I...
Hagi asked 18/11, 2016 at 0:10
2
I'm using location.href to get the full URL exists in browser address bar.
To provide more detail, it's important to note that our service has a js file that will be included in our customers sites...
Artis asked 6/11, 2016 at 8:3
1
Solved
I am trying to create a button in an HTML email that goes to a link in a href tag. I have practically no understanding of html code to be honest. This is what I'm trying:
<p>
<input styl...
Susurration asked 22/10, 2015 at 11:30
1
Solved
I currently have this code to check the website URL GET options for a specific ID, but whenever this code is run, I get a weird error: Uncaught TypeError: Undefined is not a function
Here is my co...
Examinant asked 28/6, 2014 at 21:41
3
Solved
I found applying the following function to a links onclose works to close Fancybox from within an iFrame:
parent.$.fancybox.close();
I want to take this further and have the link take the parent p...
Longfaced asked 7/9, 2010 at 16:42
1
© 2022 - 2024 — McMap. All rights reserved.