Hey Frank,
2016-05-18 16:16 GMT+02:00 K. Frank <kfrank2...@gmail.com>:
> Just to be sure I understand:
>
> Could this be as simple as reading in a well-formed html file (say,
> content.html,
> although the actual file name / extension is irrelevant -- could equally
> well be
> content.xyz), for example, using in c++ an ifstream, and using the
> entire contents
> of the file as the argument to WText::setText()?
>
More or less, since you're relying on the browser to be forgiving for the
erroneous <html>, <head> <body> and other tags. In pratice browsers are
(too) forgiving for these kind of markup mixups.
If you want to do it cleaner, you would have to remove this junk (e.g. by a
preprocessing step, or on the fly).
> > - serve the static HTML/CSS alongside the Wt application as a raw HTML
> > pages (using a static resource). For one customer we followed this
> approach.
>
> I think I've done this in some of my toy experiments, having links in a
> Wt app link to static html files, and having links in the files link back
> to the Wt app. (But I'm not really sure ... I'm still confused by how the
> urls, internal urls, path names, and docroot all interact.)
>
> But what do you mean by a "static resource"?
>
It's a resource (something that responds to GET (or POST, or ...) requests)
that's not tied to a single session, but has a fixed URL. In other words,
it's more similar to the web API of PHP, Python, etc...
Within the context of a Wt application, they are typically used only for
web services that complement your web UI.
They offer a bit more flexibility as plain files served from the docroot as
they can still transform the response in some more intelligent way (if
necessary).
Regards,
koen
------------------------------------------------------------------------------
Mobile security can be enabling, not merely restricting. Employees who
bring their own devices (BYOD) to work are irked by the imposition of MDM
restrictions. Mobile Device Manager Plus allows you to control only the
apps on BYO-devices by containerizing them, leaving personal data untouched!
https://ad.doubleclick.net/ddm/clk/304595813;131938128;j
_______________________________________________
witty-interest mailing list
witty-interest@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/witty-interest