Disable Auto refresh

Posted on 2005-04-19
Last Modified: 2010-04-01

 I m doin a auto refresh using the following line of code
<META HTTP-EQUIV=Refresh CONTENT="<%=refreshSeconds%>;">

I have to enable and disable refresh at certain conditions?

How can this be achieved?
Question by:ramsharma23
    1 Comment
    LVL 29

    Accepted Solution

    String refreshSeconds = request.getParameter("time")!=null ? request.getParameter("time") : 10000 ;
    <META HTTP-EQUIV=Refresh CONTENT="<%=refreshSeconds%>;">

    sets the refresh time via a request parameter that you can then alter to your needs (the initial bit uses a ternary operator to prevent a null when assigning the string)

    Featured Post

    Top 6 Sources for Identifying Threat Actor TTPs

    Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

    Join & Write a Comment

    If you're not part of the solution, you're part of the problem.   Tips on how to secure IoT devices, even the dumbest ones, so they can't be used as part of a DDoS botnet.  Use PRTG Network Monitor as one of the building blocks, to detect unusual…
    For Sennheiser, comfort, quality and security are high priority areas. This paper addresses the security of Bluetooth technology and the supplementary security that Sennheiser’s Contact Center and Office (CC&O) headsets provide.  
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
    This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor ( If you're looking for how to monitor bandwidth using netflow or packet s…

    734 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now