WebView

Q:

It seems that the html file has to be in “C:\lianja\apps\myapp” folder, then we can use that in the URL attribute of a webview section.

Can we use a html file that is in “c:\lianja\server\temp” folder as the URL source?

A:

The URL has to reference a file below the wwwroot, so you could not use c:\lianja\server\temp. If you create a temp folder under wwwroot (C:\lianja\cloudserver\tenants\public\wwwroot\ is the default), then you could specify this folder in the tmpnam() function, e.g.

Code:
m.cFile = tmpnam("c:\lianja\cloudserver\tenants\public\wwwroot\apps\myapp\temp\",".htm")
m.htmlrep = "c:\lianja\cloudserver\tenants\public\wwwroot\apps\myapp\rpt_template.htm"
m.cStr=FileToStr(htmlrep)
m.nResult=StrToFile(m.cStr, m.cFile)

return '/apps/myapp/temp/' + justfname(cFile)

 

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s