Forum archive 2000-2006

Lars Jensen - Documentation about headers?

Lars Jensen - Documentation about headers?

by Arnold Pizer -
Number of replies: 0
inactiveTopicDocumentation about headers? topic started 1/29/2005; 9:29:24 PM
last post 1/31/2005; 11:22:25 AM
userLars Jensen - Documentation about headers?  blueArrow
1/29/2005; 9:29:24 PM (reads: 993, responses: 2)
Hi,

Is any documentation available describing how to use the different header files in the conf/snippets directory?

Do you recommend that we place all the files of this directory in the template directory of every course?

Thanks, Lars.

<| Post or View Comments |>


userMichael Gage - Re: Documentation about headers?  blueArrow
1/31/2005; 9:27:32 AM (reads: 1271, responses: 0)
Different people use headers differently. I'll describe my preferred method, which treats the header as if it was a .pg problem and therefore uses the same file for producing both hardcopy and the HTML version of the header.

A model for this is setHeader.pg which is in the conf/snippets section. If you create a set using the default headers, this will be the default file assigned. You can customize it to reflect the contents of the set by viewing the problem set (starting at "Homework Sets" link and clicking on the new problem set, let's call it Test_Set. Clicking on "edit" on the description on the right takes you to a copy of setHeader.pg displayed in the problem editor. There is a well defined section in the text of setHeader.pg (with comments) where information particular to that set can be displayed. (setHeader.pg fills this space with a comment about where setHeader.pg is stored).

If you edit these comments you can then save the file as testSetHeader.pg using the "Save as" button (you will not be able to modify the original template setHeader). A header file should always have "header" somewhere in the file title. This is how header files are recognized by the problem set editor.

Finally, once the problem is saved, click on "make this set header" for set Test_Set. From now on you can edit and save the setHeader directly from viewing the set header, just as you can for problems.

While the basic setHeader.pg works well enough for me, I think it can probably be improved so that it is a bit easier for newbies to see which spots are safe to edit freely.

Some people prefer to keep the HTML and TeX code in separate files, but for me, there is enough overlap in the information that I frequently update (information for students about which problems are harder, or how they relate to other material in the course) that I don't want to type the information in twice, once for HTML and once for TeX. With this scheme I just type it once and the usual PG magic prepares it for either TeX or HTML output.

Hope this helps.

-- Mike

<| Post or View Comments |>


userLars Jensen - Re: Documentation about headers?  blueArrow
1/31/2005; 11:22:25 AM (reads: 1247, responses: 0)
Hi Mike,

Thanks - that was very helpful. I was looking for info like this in the WeBWorK 2.1 Installation Manual and the Course Administration Manual. It might be useful to copy your info above in one of these. Otherwise I think the manuals are fairly complete and easy to follow.

Thanks again, Lars.

<| Post or View Comments |>