Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

refresh page js

//with no cache
document.location.reload(true);
//else
document.location.reload();

/**
 * Si le paramètre est nul, recharge la page, sinon recharge la page avec le paramètre.
 * If the parameter is null, reload the page, else, reload the page with the parameter
 * @param [param=null] - Le paramètre que vous souhaitez ajouter à l'URL.
 */
function reloadPage(param = null){

    if ( param != null ){
        window.location.href = window.location.href.replace( /[?#].*|$/, `${param}` );
    }

    else
    { 
        if ( window.location.href.split('?').length > 1 ){
            window.location.href = window.location.href.split('?')[0];
        }

        else 
            window.location.reload();
    }

    //param == null ? window.location.reload(): window.location.href = window.location.href.replace( /[?#].*|$/, `${param}` );
}
Comment

refresh page javascript

location.reload();
// OR
window.location.reload();
Comment

javascript reload page

// Works on iOS Safari as well
location.reload()
window.location.reload()
Comment

refresh page js

window.location.reload(true);
Comment

javascript refresh page

<script type="text/javascript">
    function autoRefreshPage()
    {
        window.location = window.location.href;
    }
    setInterval('autoRefreshPage()', 10000);
</script>
Comment

javascript reload page without refresh

<a href="javascript:window.top.location.reload(true)" class="continue">Continue</a>
Comment

auto refresh page javascript

<meta http-equiv="refresh" content="30"/>
Comment

PREVIOUS NEXT
Code Example
Javascript :: postman check for null or undefined 
Javascript :: node js cron restart every round hour 
Javascript :: js array none 
Javascript :: ignores _id mongoose schema 
Javascript :: node google client api to get user profile with already fetched token 
Javascript :: negative reciprocal javascript 
Javascript :: moment between exclusivity 
Javascript :: externalCodeSetup.navigationApi.replaceScreenComponent 
Javascript :: import withrouter 
Javascript :: generate secret key js Java Script 
Javascript :: electron js Not allowed to load local resource 
Javascript :: jquery add event listener to ckeditor 
Javascript :: deploy create react app pm2 
Javascript :: multi stage node js dockerfile 
Javascript :: enumerate node js 
Javascript :: how to get current year in javascript 
Javascript :: casperjs exit 
Javascript :: pipefy api card search field 
Javascript :: js simulate click 
Javascript :: node express json request urlencoded 
Javascript :: speed facebook video 
Javascript :: how to check if iframe is loaded 
Javascript :: javascript auto save input 
Javascript :: Não é possível chamar Veiculo.create(). O método create não foi configurado. O PersistedModel não foi conectado corretamente a uma DataSource! 
Javascript :: js random int 
Javascript :: how to hide javascript element by class 
Javascript :: Component should be written as a pure function 
Javascript :: how to use flatlist keyextractor 
Javascript :: refresh page js 
Javascript :: javascript parse url parameters 
ADD CONTENT
Topic
Content
Source link
Name
9+7 =