Forum archive 2000-2006

Ted Cox - customize headers and problem sets, setHeader.pg, "make local editable copy"

Ted Cox - customize headers and problem sets, setHeader.pg, "make local editable copy"

by Arnold Pizer -
Number of replies: 0
inactiveTopiccustomize headers and problem sets, setHeader.pg, "make local editable copy" topic started 8/29/2006; 2:44:04 PM
last post 8/31/2006; 4:45:25 PM
userTed Cox - customize headers and problem sets, setHeader.pg, "make local editable copy"  blueArrow
8/29/2006; 2:44:04 PM (reads: 246, responses: 3)
I want to change the contents of setHeader.pg for a given problem set, but the changes I make directly to the file with an editor are ignored. If I try to use the web interface I get error messages and can't do it. If I put new setHeaderMyHeader.pg files in templates the web interface doesn't see them.

Error messages:

Set Header for set IntroSet The file '[WW]/conf/snippets/setHeader.pg' is protected! To edit this text you must make a copy of this file using the 'make local editable copy at ...'action below

and

Error messages

editFilePath is unsafe! at /usr/local/webwork-2.2.1/lib/WeBWorK/ContentGenerator/Instructor/PGProblemEditor.pm line 480.

AND THERE IS NO BUTTON TO MAKE A COPY.

Is there a description somewhere of what webwork2 is doing? Are the contents of a .pg file read into a dabase and therefore unchangeable? How can I tell webwork2 to use the .def and .pg files that I want it to that I create (with an editor).

I am spending hours and hours unable to get the course information webwork2 displays correct, let alone the problems and problem sets.

Any help would be appreciated.

<| Post or View Comments |>


userArnold K. Pizer - Re: customize headers and problem sets, setHeader.pg,  blueArrow
8/29/2006; 4:02:46 PM (reads: 292, responses: 0)
Hi Ted,

I'll just respond to part of your querry. You say "If I put new setHeaderMyHeader.pg files in templates the web interface doesn't see them." If you put a file named "setHeaderMyHeader.pg" in your course templates directory (with permissions so that it is readable by the webserver) and then select "Hmwk Set Editor" and click the link (the number of problems in the set) under "Edit Problems", you get to the "Set Detail" page. Under the "Headers" section, you should see "setHeaderMyHeader.pg" in the scroll down list. In fact you should see all .pg files that contain "Header" in the file name that are in the templates directory or any subdirectory.

Is this not the case with your set up or did you mean something else when you say "the web interface doesn't see them."

Arnie

<| Post or View Comments |>


userDavide P. Cervone - Re: customize headers and problem sets, setHeader.pg, "make local editable copy"  blueArrow
8/29/2006; 11:56:59 PM (reads: 287, responses: 0)
The Problem Editor underwent some pretty heavy editing over the past 2 to 7 months, and a number of interface problems and inconsistencies were ironed out. If I recall correctly, some of the problems with error handling when files are not writable or are blank problems were taken care of at the beginning of the summer. If you haven't updated recently, you may want to consider moving up to a later release.

The two issues you complain about (editFilePath is unsafe, and missing make local copy action) were fixed in June (PGProblemEditor.pm version 1.76 through 1.80), so you probably have a version older than that. I'm not sure that these changes have made it into a stable release or not. It is not always wise to update one file by itself, so if you try this, you might keep your old copy around just in case there are problems.

Davide

<| Post or View Comments |>


userSam Hathaway - Re: customize headers and problem sets, setHeader.pg,  blueArrow
8/31/2006; 4:45:25 PM (reads: 278, responses: 0)
Hi Ted,

We have a prerelease branch of WeBWorK 2.3.0 in CVS under the name rel-2-3-dev. It fixes many bugs, including "editFilePath is unsafe". Read the installation manual for 2.3 for information on how to upgrade to it.
-sam

<| Post or View Comments |>