开发者

Generate dynamic html

开发者 https://www.devze.com 2022-12-25 06:37 出处:网络
to export some data i want to be able to generate an html output. I have some co开发者_运维技巧nstant content to output, like html headers and footers.

to export some data i want to be able to generate an html output.

I have some co开发者_运维技巧nstant content to output, like html headers and footers.

My question is how to deal with that ? Do I have to embed some template (in a resource file) and parse it to make it dynamic ? Do I store my static content in some constant (is there a 255 char limit?) and append them while generating the dynamic content ?

Do you have some hints, useful links, or best practices to share?

Thanks


Use the Delphi TPageProducer. It generates HTML from a 'close to HTML' template which contains special tage. You respond to these tag in an event and replace them with your own data. Works a treat.


I've created a Delphi project that handles this issue also. I wanted to create a web-platform that uses Delphi-code in the same source-files as the HTML, much like other web-scripting platforms, but still compiles a library to run. (and auto-compiles on changes)

http://xxm.sf.net/

In its basic form it compiles into library that can be run by a handler for IIS (ISAPI extension), InternetExplorer (IInternetProtocol as its own URL scheme), or a stand-alone HTTP process. (Apache module and FireFix plug-in are on the way).

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号