473,484 Members | 1,687 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Auto Refresh page

2 New Member
Hi,

I need to auto refresh a page after a specific time interval. When the page is accessed the first time, a request parameter is null and hence it gets redirected to a welcome page (static html). When user clicks on a link from the left menu, i take the ID passed during the click and the page is redirected to a jsp that has information specific to that ID. Now, when i write a script to refresh this page (with some info), the ID is lost and hence the user is taken to the welcome page (static html).

I tried using the <meta > tag for refresh, but facing the same issue. I have also tried the window.location.replace and window.location.href in the script but both throw a alert message when the page refreshes ("you are transferring info ...blah...blah...Retry ? Cancel"). I need to avoid this. I need help in this regard.

thanks,
tinu
May 3 '07 #1
3 9346
acoder
16,027 Recognized Expert Moderator MVP
The meta refresh should work (I think).

Post your code.
May 3 '07 #2
dilipananth1984
3 New Member
The meta refresh should work (I think).

Post your code.
[HTML]<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
<f:loadBundle basename="messages" var="msg" />
<LINK rel="stylesheet" type="text/css"
href="../theme/DashBoardStyle.css" title="Style">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<meta http-equiv="refresh" content="3">
<f:verbatim>
<title>Welcome</title>
</f:verbatim>

<f:verbatim>
<table align="left" border="0" width="100%" cellpadding="0" cellspacing="0">

</f:verbatim>
<h:form id="welcomeOne">
<f:verbatim>
<tr>



<td width="75%" style="margin-left: 10px" align="center">
<table width="100%" border="0">
<tr align="left" valign="top">
<td align="left">
</f:verbatim>
<%
String dashboardId = request.getParameter("dashBoardID");
String path = null;

if(dashboardId == null) {

%>
<f:subview id="dashboard_included_page">
<jsp:include page="welcome.jsp" flush="true"/>
</f:subview>
<%
} else {
com.proj.ApplicationProperties properties = new com.proj.ApplicationProperties(com.proj.CommonCons tants.APPLICATION_PROPERTIES);
String URL = properties.getProperty(com.proj.CommonConstants.DA SHBOARD_URL);

%>
<f:verbatim>
<iframe src ="<%= URL %><%=(String) request.getParameter("dashBoardID")%>"
marginwidth="100px" height="1000" frameborder="0" scrolling="auto" width="100%">
</iframe>
<input type="hidden" name="dashBoardID" value="<%= request.getParameter("dashBoardID")%>" />
</f:verbatim>
<%
}
%>
<f:verbatim>
</td>
</tr>
</table>
</td>
</tr>
</f:verbatim>



<f:verbatim>


<tr>
<td height="20"></td>
</tr>
</f:verbatim>
</h:form>
<f:verbatim>
</table>
</f:verbatim>[/HTML]
May 4 '07 #3
acoder
16,027 Recognized Expert Moderator MVP
You can also use
Expand|Select|Wrap|Line Numbers
  1. window.location.reload();
May 4 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
12885
by: Scott | last post by:
I have a clickable graph that resides on page 1. If user clicks a data point on the graph, the page runs again yeilding a 2nd graph that shows a more detailed graph. Problem is, I have a...
1
34279
by: Lew | last post by:
Hi all, I'm trying to create a page that has a user-selectable page auto-refresh option (IE 5.5). Essentially, it's a page that contains a checkbox, when the user checks the checkbox, I'd like...
3
487
by: blu3g85 | last post by:
how to redirect a page? as in after a few sec, the page will auto direct u to another page. ----== Posted via Newsfeed.Com - Unlimited-Uncensored-Secure Usenet News==----...
2
1794
by: MattB | last post by:
I have a page I've migrated from HTML to asp.net that would auto-refresh every 30 seconds. I did this by putting the following in the <head> section: <meta name="refresh" content="30"> But now...
7
22672
by: Brian | last post by:
hello, I am looking for a way to auto refresh a web page that I created, but also let the user choose to stop the auto refresh. I can not figure out how to stop the auto refresh. Any help would...
4
10012
by: jack-e | last post by:
How do I auto refresh a page a particular time of the day?
3
3566
by: lezzo | last post by:
Hi Guys, I am new to this forum and find very interesting. I need your help in one of the script. I got a MySQL table bid_amount, and i want that if some new data comes in this table and...
1
3010
by: BibhuAshish | last post by:
hi, I have designed a jsp page. This jsp is able to auto refresh after 5 second. But i want after 5th times of auto refreshment the table present inside the body should change. Can anybody...
2
2901
by: =?Utf-8?B?QW1pciBUb2hpZGk=?= | last post by:
Hi I have a web page that has a TreeView on it. If I DONT'T expand the TreeView nodes, the auto refresh works nicely: my page gets refreshed every minute. As soon as I expand a node on the...
0
7079
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7137
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5403
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4838
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4527
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3044
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3038
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
587
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
234
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.