
cfflush
149
cfflush
Description
Flushes currently available data to the client.
Category
Data output tags
,
Page processing tags
Syntax
<cfflush
interval = "integer number of bytes">
See also
cfcache
,
cfheader
,
cfinclude
,
cfsetting
,
cfsilent
Attributes
Usage
The first occurrence of this tag on a page sends back the HTML headers and any other available
HTML. Subsequent
cfflush
tags on the page send only the output that was generated after the
previous flush.
When you flush data, ensure that enough information is available, as some browsers might not
respond if you flush only a small amount. Similarly, set the
interval
attribute for a few hundred
bytes or more, but not thousands of bytes.
Use the
interval
attribute only when a large amount of output will be sent to the client, such as
in a
cfloop
or a
cfoutput
of a large query. Using this form globally (such as in the
Application.cfm file) might cause unexpected errors when CFML tags that modify HTML
headers are executed.
Caution:
Because the
cfflush
tag sends data to the browser when it executes, it has several
limitations, including the following: Using any of the following tags or functions on a page anywhere
after the
cfflush
tag can cause errors or unexpected results:
cfcontent
,
cfcookie
,
cfform
,
cfheader
,
cfhtmlhead
,
cflocation
, and
SetLocale
. (These tags and functions normally modify the HTML
header, but cannot do so after a
cfflush
tag, because the
cfflush
sends the header.) Using the
cfset
tag to set a cookie anywhere on a page that has a
cfflush
tag does not set the cookie in the browser.
Using the
cfflush
tag within the body of several tags, including
cfsavecontent
,
cfquery
, and custom
tags, cause errors. If you save Client variables as cookies, any client variables that you set after a
cfflush
tag are not saved in the browser.
Note:
Normally, the
cferror
tag discards the current output buffer and replaces it with the contents of
the error page. The
cfflush
tag discards the current buffer. As a result, the
Error.GeneratedContent
variable resulting from a
cferror
tag after a
cfflush
contains any contents of the output buffer that
has not been flushed. This content is not sent to the client. The content of the error page displays to
the client after the bytes that have been sent.
Attribute
Req/Opt
Default
Description
interval
Optional
Integer.
Flushes output each time this number of bytes becomes
available. HTML headers, and data that is already available
when the tag is executed, are omitted from the count.
Содержание COLFUSION MX 7 - INSTALLING AND USING COLDFUSION MX
Страница 1: ...COLDFUSION MX7 CFML Reference...
Страница 20: ...20 Chapter 1 Reserved Words and Variables...
Страница 50: ...50 Chapter 2 ColdFusion Tags cfelse br Searching cfif cfloop cfif...
Страница 101: ...cfdefaultcase 101 cfdefaultcase cfswitch cfoutput Your grade is grade cfoutput...
Страница 115: ...cfdocumentsection 115 cfdocumentsection cfoutput cfdocument...
Страница 311: ...cfNTauthenticate 311 Please Try again H2 cfif cfoutput cfinclude template loginform cfm cfabort cfif cfif cflogin...
Страница 411: ...cftable 411 cftable body html...
Страница 515: ...Chr 515 maxlength 5 p input type Submit name input type RESET cfform...
Страница 605: ...GetEncoding 605 WriteOutput The encoding is theEncoding cfscript cfif...
Страница 629: ...GetProfileString 629 tr td input type Submit name Submit value Submit td td td tr table form...
Страница 655: ...IIf 655 cfoutput IIf Hour Now GTE 12 DE It is afternoon or evening DE It is morning cfoutput b...
Страница 664: ...664 Chapter 3 ColdFusion Functions cfelse h3 Conversion error h3 cfif...
Страница 687: ...IsStruct 687 cfoutput cfquery cfif cfoutput hr Employee Add Complete cfoutput cfcase cfswitch...
Страница 693: ...IsWDDX 693 struct data wddxPacket hr xmp cfoutput packet xmp IsWDDX returns IsWDDX packet br cfoutput...
Страница 751: ...LSDateFormat 751 hr noshade cfoutput cfloop...
Страница 861: ...StructFind 861 cfquery cfif cfoutput hr Employee Add Complete cfoutput cfcase cfswitch...
Страница 869: ...StructIsEmpty 869 cfoutput cfquery cfif cfoutput hr Employee Add Complete cfoutput cfcase cfswitch...
Страница 903: ...Val 903 value Is the beginning numeric name form...
Страница 932: ...932 Chapter 3 ColdFusion Functions...
Страница 944: ...944 Chapter 4 ColdFusion MX Flash Form Style Reference...
Страница 962: ...962 Chapter 5 Application CFC Reference...
Страница 1008: ...1008 Chapter 6 ColdFusion MX Event Gateway Reference cfset retValue Reason reason cfreturn retValue cffunction...
Страница 1054: ...1054 Chapter 6 ColdFusion MX Event Gateway Reference...