refresh

remember after refresh selected row in extjs grid

老子叫甜甜 提交于 2019-12-18 04:34:29
问题 I have a problem. I use extjs grid . This grid will be refreshed every seconds . I refresh with this function: ND.refresh = function() { ND.commList.load(); } var refreshSeconds = refreshRate * 1000; var t = setInterval('ND.refresh()', refreshSeconds); But when someone selected a row to highlight it it reset this selection. How can I remember the selected row and highlight it again after refresh? This is my grid: var grid = Ext.create('Ext.grid.Panel', { autoscroll: true, region: 'center',

An Iframe i need to refresh every 30 seconds (but not the whole page)

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-18 03:09:34
问题 I have this bit of code <iframe marginwidth="0" marginheight="0" width="240" height="80" scrolling="no" frameborder=0 src="irc_online.php"> </iframe> I am adding this to a html widget I have on a sidebar, Is there a way I can make this refresh say every 30 seconds and not the rest of my page? Many Thanks 回答1: You can put a meta refresh Tag in the irc_online.php <meta http-equiv="refresh" content="30"> OR you can use Javascript with setInterval to refresh the src of the Source... <script>

How to Redirect Page in PHP after a few seconds without meta http-equiv=REFRESH CONTENT=time

人走茶凉 提交于 2019-12-18 02:38:42
问题 It seems that it is not advisable to use <meta http-equiv=REFRESH CONTENT=3;url=url> for redirects but instead use header('Location: url') However, I would like to show the user some message and allow them some time to read it before redirecting. Is there a way to do it without meta? 回答1: Try use "refresh" header: header('Refresh: 3;url=page.php'); Also, you can look at this Question Refresh HTTP Header. 回答2: There is nothing wrong with using the meta refresh tag. <meta http-equiv="refresh"

How to Redirect Page in PHP after a few seconds without meta http-equiv=REFRESH CONTENT=time

天大地大妈咪最大 提交于 2019-12-18 02:38:21
问题 It seems that it is not advisable to use <meta http-equiv=REFRESH CONTENT=3;url=url> for redirects but instead use header('Location: url') However, I would like to show the user some message and allow them some time to read it before redirecting. Is there a way to do it without meta? 回答1: Try use "refresh" header: header('Refresh: 3;url=page.php'); Also, you can look at this Question Refresh HTTP Header. 回答2: There is nothing wrong with using the meta refresh tag. <meta http-equiv="refresh"

PHP array from cookie info: only shows up after you refresh the page?

耗尽温柔 提交于 2019-12-17 21:38:19
问题 So I'm trying to return items from an array that's made out of user inputted info from cookies, and it works fine, except when you first visit the page from the previous page, nothing shows up, and you have to refresh it to actually see the array. I have no idea why it wouldn't show up the first time around? (There are some JavaScript alerts in there that work fine. It's only the array that I'm having trouble with.) Here's my code, any advice would be great, thanks: $usergatsby = $_COOKIE[

C# - how do I refresh DataGridView after removing rows

岁酱吖の 提交于 2019-12-17 20:37:06
问题 In my code I need to remove rows from the DataGridView after a recurring interval, and so I call the following function when a timer expires: private void removeRows(DataGridView dgv) { foreach (DataGridViewRow row in dgv.Rows) { // if some condition holds dgv.Remove(row); } dgv.Refresh(); } I know the rows are successfully deleted from the DataGridView, though they still remains in the display for whatever reason. Any tips on what I might be doing wrong? 回答1: If you have bound your datagrid

jQuery reload div's content (dynamically rendered)

こ雲淡風輕ζ 提交于 2019-12-17 20:25:56
问题 I have a div that is generated html via Expression Engine. I'm using ajax submit: $('#login-form').ajaxForm({ // success identifies the function to invoke when the server response // has been received; here we apply a fade-in effect to the new content success: function() { $("#panel").RELOAD!!();//Just refresh this div! } }); I just want the #panel div to reload/refresh. 回答1: I assume you looking for something like that: $('#login-form').ajaxForm({ success: function( data) { $("#panel").html(

JSF, refresh periodically a component with ajax?

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-17 19:13:24
问题 I'm working on an application JSF and i want to refresh periodically a component with ajax Like facebook notification zone behaviour. How can i do that? 回答1: Poll is what you need to use Poll component make ajax calls in a specified interval. For example Primefaces Poll <h:form id="form"> <h:outputText id="txt_count" value="#{counterBean.count}" /> <p:poll interval="3" listener="#{counterBean.increment}" update="txt_count" /> </h:form> Link to showcase Primefaces Ajax Poll Pure JSF approach

QT Repaint/Redraw/Update/Do Something

北战南征 提交于 2019-12-17 19:07:59
问题 I'm New to QT. I understand that you can force a display refresh, but I've pulled all my hair out trying to figure out how. Here is what I'm specifically trying to do. I press a button (onClick signal event), which runs code that changes an image (QLabel) on the display, waits for input, and then proceeds by changing a new image (different QLabel). I've tried everything and the display doesn't refresh until the onclick signal event code is complete. Right now, I'm not waiting for user input,

Refresh Page C# ASP.NET

时光毁灭记忆、已成空白 提交于 2019-12-17 18:45:37
问题 Is there a Page.Refresh type of command to refresh a page? I don't want to redirect to the page or refresh in JavaScript. 回答1: I think this should do the trick (untested): Page.Response.Redirect(Page.Request.Url.ToString(), true); 回答2: Careful with rewriting URLs, though. I'm using this, so it keeps URLs rewritten. Response.Redirect(Request.RawUrl); 回答3: Response.Redirect(Request.Url.ToString()); 回答4: You can just do a regular postback to refresh the page if you don't want to redirect.