This method allows you to create custom HTMLHeader and HTTPHeader objects and pass it to this method for output creation.
o.HTMLHeaderEx(lvHTMLHeader, lvHTTPHeader)
Return Value
"" or string if llNoOutput = .T.
Parameters
lvHTMLHeader
An instance of the wwHTMLHeader class which contains output for the HTML document header including <HTML>, <BODY> and <HEAD> sections of the document. If left blank a default header is used. (<html><body>).
Alternately you can pass a Title string which generates a basic default header. If not passed or passed blank a default header is also generated.
lvHTTPHeader
An instance of the wwHTTPHeader object, which contains output for the HTTP header. An HTTP header is required on every outgoing docment. If object is not passed a default text/html header is created.
You can also pass in a default header string that contains just the content type (like text/xml for example) or a directive (like FORCE RELOAD).
If not passed or passed empty a default header is generated.
Example
FUNCTION Headertest loHTMLHeader = CREATEOBJECT("wwHTMLHeader",Response) loHTTPHeader = CREATEOBJECT("wwHTTPHeader",Response) loHTTPHeader.DefaultHeader() loHTTPHeader.AddForceReload() loHTTPHeader.AddCookie("laston",TTOC(DATETIME())) loHTMLHeader.AddTitle("Header Test Page") loHTMLHeader.AddPageRefresh(Request.GetCurrentUrl(),5) loHTMLHeader.AddJavaScript([function test {] + CRLF + [alert("test"); } ] ) loHTMLHeader.AddVBScript([function test ] + CRLF + [MsgBoxt("test") ] + CRLF + [end func]) loHTMLHeader.AddStyleSheet("/westwind.css") loHTMLheader.cBodyTag = [<body bgcolor="#FFFFFF">] Response.HTMLHeaderEx(loHTMLHeader,loHTTPHeader) *** This is Response.Write("<h1>Header Test Page</h1>") Response.Write("<hr>" + TIME() ) Response.HTMLFooter() ENDFUNC
See also:
Class wwResponse | Class wwHTTPHeader | Class wwHTMLHeader© West Wind Technologies, 1996-2024 • Updated: 11/26/15
Comment or report problem with topic