Ejemplo 1: javascript cambia la URL sin recargar
window.history.pushState('', 'New Page Title', '/new-url.php');
Ejemplo 2: URL de cambio de secuencia de comandos java sin recargar
window.history.replaceState({}, '','/dashboard');
Ejemplo 3: URL de cambio de JavaScript
history.pushState({}, null, newUrl);
Ejemplo 4: cambiar la URL sin recargar
function processAjaxData(response, urlPath){
document.getElementById("content").innerHTML = response.html;
document.title = response.pageTitle;
window.history.pushState({"html":response.html,"pageTitle":response.pageTitle},"", urlPath);
}
Ejemplo 5: javascript cambia el parámetro get sin recargar
Since this is the accepted answer, and no longer true, refer to this duplicate question for up to date information.
Original answer follows:
NO
You can come close with the anchor portion of the URL which is accessible by the hash property of the location object
parent.location.hash = "whatever value you want";
¡Haz clic para puntuar esta entrada!
(Votos: 0 Promedio: 0)