EXECRSP()
From Lianjapedia
Revision as of 11:42, 19 February 2015 by Yvonne.milne (Talk | contribs)
Contents
Purpose
Function to execute an rsp script
Syntax
EXECRSP(<expC1> [, <expC2>])
See Also
DO, EXECJAVASCRIPT(), EXECPHP(), EXECPYTHON(), EXECSCRIPT(), SET STRCOMPARE, SPAWN, Visual FoxPro Server Pages
Description
The EXECRSP() function executes the specified Visual FoxPro Server page (.rsp page). The name of the rsp file is specified in <expC1> along with any required parameters. The optional <expC2> is the name of the output file that the generated HTML will be sent to. If no output file is specified, it will be sent to the current output.
Example
execRSP("test.rsp?customerid=alfki")
test.rsp
<%@ Language=VFP %> <% local m_customerID = getParameter("customerID", "") local m_tempfile = tmpnam() if database() <> "southwind" open database southwind endif set strcompare on // perform autotrim and case insensitive string comparisons in queries select * from customers where customerid=m_customerid into cursor temp select temp copy to &m_tempfile type csv type &m_tempfile erase &m_tempfile %>