|
Mailing Lists
|
Home /
Groups /
ColdFusion Talk (CF-Talk)
Keeping of with CFFlush
I've got a report page that will sometimes consist of several thousandIan Skinner 04/23/03 05:24 P Javascript is interpreted as the browser recieves it. Therefore, you couldBen Doom 04/23/03 05:31 P Ben Doom wrote:Jesse Houwing 04/23/03 05:49 P With JS you should be able to jump to the end...Raymond Camden 04/23/03 05:46 P With JS you should be able to jump to the end...Jesse Houwing 04/25/03 02:05 A > With JS you should be able to jump to the end...Philip Arnold 04/25/03 05:57 A <cfoutput query="queryName">jon hall 04/23/03 06:13 P Another method would be to use javascript to set focus on the last line. OfShawn Grover 04/23/03 05:46 P I've got a report page that will sometimes consist of several thousand records. Do to extensive processing of each record it's can take up to 1 hour for this page to finish processing. To keep the user informed of the progress, I am using CFFlush to regularly send output to the client as each record is completed. All of this is working well, but as new output is sent it is, of course, appended to the end of the page. Thus, once the screen is full of records, if the user doesn't keep scrolling to the end, they can no longer see the new records as they are added. Does anybody know a simple way I can make the browser always display the end of the page, while it is being written? Just to save the user the annoyance of having to scroll down all the time during the generation of this report. I can't see how this could be done since I would presume the solution would involve JavaScript of some sort and I don't know how JavaScript behaves during the receiving of the http request? But, I thought I would just ask the combined mental power of this list. -------------- Ian Skinner Web Programmer BloodSource Sacramento, CA Javascript is interpreted as the browser recieves it. Therefore, you could use it to do something like expand a graphic across and change some text to indicate what's going on. -- Ben Doom Programmer & General Lackey Moonbow Software, Inc : -----Original Message----- : : Sent: Wednesday, April 23, 2003 5:19 PM : To: CF-Talk : Subject: Keeping of with CFFlush : : : I've got a report page that will sometimes consist of several thousand : records. Do to extensive processing of each record it's can take up to 1 : hour for this page to finish processing. To keep the user informed of the : progress, I am using CFFlush to regularly send output to the : client as each : record is completed. : : All of this is working well, but as new output is sent it is, of course, : appended to the end of the page. Thus, once the screen is full : of records, : if the user doesn't keep scrolling to the end, they can no longer see the : new records as they are added. : : Does anybody know a simple way I can make the browser always : display the end : of the page, while it is being written? Just to save the user : the annoyance : of having to scroll down all the time during the generation of : this report. : : I can't see how this could be done since I would presume the : solution would : involve JavaScript of some sort and I don't know how JavaScript behaves : during the receiving of the http request? But, I thought I would just ask : the combined mental power of this list. : : -------------- : Ian Skinner : Web Programmer : BloodSource : Sacramento, CA : : Ben Doom wrote: >Javascript is interpreted as the browser recieves it. Therefore, you could >use it to do something like expand a graphic across and change some text to >indicate what's going on. > There is also a javascript function that scrolls teh document by a number of pixels. I used this to get it done. Just send <script> window.scrollBy(100,0); </script> after each record You'll have to check the actual scroll function, because I'm not sure of the exact name. Jesse ----- Excess quoted text cut - see Original Post for more ----- With JS you should be able to jump to the end... <!--- This code is your report stuff... ---> <cfloop index="x" from=1 to=10000> <cfoutput>#x#<br></cfoutput> </cfloop> <!--- Add this ---> <a name="bottom"> <script> document.location.href = "#bottom"; </script> ======================================================================== === Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc (www.mindseye.com) Member of Team Macromedia (http://www.macromedia.com/go/teammacromedia) Email : jedimaster@mindseye.com Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus "My ally is the Force, and a powerful ally it is." - Yoda ----- Excess quoted text cut - see Original Post for more ----- With JS you should be able to jump to the end... ----- Excess quoted text cut - see Original Post for more ----- That only works when the document is done loading. ----- Excess quoted text cut - see Original Post for more ----- ----- Excess quoted text cut - see Original Post for more ----- If you don't use CFFLUSH, nothing will be sent to the browser until it's done building the whole page To "see" the progress, then you must put the <A NAME> and location.href in regularly and then CFFLUSH it You could use an INTERVAL on the CFFLUSH, but that's irregular for your progress and you have no real control over when it does the output (apart from the obvious INTERVAL setting) Just remember that as soon as you CFFLUSH the page, you can't set cookies or use CFHTMLHEAD <cfoutput query="queryName"> Output stuff... <a name="i#queryName.currentRow#" id="i#queryName.currentRow#"href="##">Perhaps something here too</a> <br> <script type="text/javascript"> document.getElementById('i<cfoutput>#queryName.currentRow#</cfoutput>').focus(); </script> <cfflush> </cfoutput> -- jon mailto:jonhall@ozline.net Wednesday, April 23, 2003, 5:19:19 PM, you wrote: IS> I've got a report page that will sometimes consist of several thousand IS> records. Do to extensive processing of each record it's can take up to 1 IS> hour for this page to finish processing. To keep the user informed of the IS> progress, I am using CFFlush to regularly send output to the client as each IS> record is completed. IS> All of this is working well, but as new output is sent it is, of course, IS> appended to the end of the page. Thus, once the screen is full of records, IS> if the user doesn't keep scrolling to the end, they can no longer see the IS> new records as they are added. IS> Does anybody know a simple way I can make the browser always display the end IS> of the page, while it is being written? Just to save the user the annoyance IS> of having to scroll down all the time during the generation of this report. IS> I can't see how this could be done since I would presume the solution would IS> involve JavaScript of some sort and I don't know how JavaScript behaves IS> during the receiving of the http request? But, I thought I would just ask IS> the combined mental power of this list. IS> -------------- IS> Ian Skinner IS> Web Programmer IS> BloodSource IS> Sacramento, CA IS> Another method would be to use javascript to set focus on the last line. Of course, you'd need to have something you can set focus to. Haven't tried this myself so can't say 100% fer sure it'll work, but it might save you reformatting your output too much. HTH Shawn Javascript is interpreted as the browser recieves it. Therefore, you could use it to do something like expand a graphic across and change some text to indicate what's going on. -- Ben Doom Programmer & General Lackey Moonbow Software, Inc : -----Original Message----- : : Sent: Wednesday, April 23, 2003 5:19 PM : To: CF-Talk : Subject: Keeping of with CFFlush : : : I've got a report page that will sometimes consist of several thousand : records. Do to extensive processing of each record it's can take up to 1 : hour for this page to finish processing. To keep the user informed of the : progress, I am using CFFlush to regularly send output to the : client as each : record is completed. : : All of this is working well, but as new output is sent it is, of course, : appended to the end of the page. Thus, once the screen is full : of records, : if the user doesn't keep scrolling to the end, they can no longer see the : new records as they are added. : : Does anybody know a simple way I can make the browser always : display the end : of the page, while it is being written? Just to save the user : the annoyance : of having to scroll down all the time during the generation of : this report. : : I can't see how this could be done since I would presume the : solution would : involve JavaScript of some sort and I don't know how JavaScript behaves : during the receiving of the http request? But, I thought I would just ask : the combined mental power of this list. : : -------------- : Ian Skinner : Web Programmer : BloodSource : Sacramento, CA : :
|
June 19, 2013
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||