Forum OpenACS Q&A: Question about full-screen xowiki rendering and [[en:CSS]]

So far I have finally succeeded in putting a fully complete CSS driven templated page into xowiki having built an xowiki::Form and then filled it in. All the associated images and css files have been uploaded into xowiki and are in place.

I now want it displayed full screen.

I tried the magic invokation ?master=0 and what I received was a horrible mess! I noticed that the <head> section of the document was missing so I have added that to the template in xowiki. But the invokation:

[[my_stylesheet.css]]

no longer works its magic.

I have tried putting [[my_stylesheet.css]] in the template <head> but no cigar!

Is there any way of referrring to the css file like this or must I now put the css file into the aolserver web root and refer to it in the doc head in the usual way?

Regards
Richard

if you specify master=0, then the master templates are not used, which are normally responsible for the output of the HTML head (and other things). So, by deactivating the master, the page has to return a FULL HTML document. The problem is not that the css file is not parsed/found or whatever, but that the header information is omitted. To get a better understanding, look for header_stuff in xowiki-www-procs.tcl.

there is no easy way to get a "full-screen mode" in the general case. One has either to modify the master templates of openacs (e.g. conditionally switching the master templates) or one has to modify the method view to return optionally a full HTML document, containing the header stuff and the page content.

Gustaf,

Thank you for the reply. I understand the problem.

I think for the time being, for this application, I will simply specify a static css file in the doc <head> for my full-screen display.

From a more general point of view, it would seem to make a lot of sense to implement your second idea as an option in xowiki such that the view method, when it receives a magic invokation such as {{full_screen_display=true}}, switches off the master template but outputs a document <head> that includes the css reference.

If I find time to do that I will post the code back for your consideration.

Regards
Richard

Further to my previous post, I have just discovered that the files that xowiki invites you to upload are stored in the filesystem in a conveniently accessible location under the web root. I had assumed they were stored in the content repository as database entries.

That means that I can still upload my css file into xowiki, and I can still add the normal html stylesheet directive to the <head> of the document in the template field of the xowiki::Form specfication! 😊 Characteristically elegant Gustaf.

All of which means that since everything can still be uploaded and referenced through the xowiki interface and form specs, there is no issue to solve. Which means that there really is no need to go to the trouble of writing something to add a doc <head> since it is so trivial to simply add one to the template manually.

R.