Changeset 308
- Timestamp:
- 05/08/06 05:21:43 (2 years ago)
- Files:
-
- devel/config-dist.php (modified) (1 diff)
- devel/units/templates/template_actions.php (modified) (1 diff)
- devel/units/templates/templates_add.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
devel/config-dist.php
r269 r308 79 79 //$CFG->pathtoclam = '/usr/bin/clamscan'; // OR '/usr/bin/clamdscan'; 80 80 81 // TEMPLATES HANDLING 82 //$CFG->disable_usertemplates = true; // users can only choose from available templates 83 81 84 // set up some LMS hosts. 82 85 // -------------------------------------------------- devel/units/templates/template_actions.php
r285 r308 74 74 $name = optional_param('new_template_name'); 75 75 $based_on = optional_param('template_based_on',0,PARAM_INT); 76 if ( !empty($name)) {76 if (empty($CFG->disable_usertemplates) && !empty($name)) { 77 77 $t = new StdClass; 78 78 $t->name = trim($name); devel/units/templates/templates_add.php
r269 r308 1 1 <?php 2 2 3 global $USER; 4 global $CFG; 5 6 if (empty($CFG->disable_usertemplates)) { 3 7 // Create a new template 4 8 $header = gettext("Create theme"); // gettext variable … … 40 44 </select> 41 45 END; 42 43 $panel .= templates_draw(array( 44 'context' => 'databox1', 45 'name' => gettext("Based on"), 46 'column1' => $column1 47 ) 48 ); 46 47 48 $panel .= templates_draw(array( 49 'context' => 'databox1', 50 'name' => gettext("Based on"), 51 'column1' => $column1 52 ) 53 ); 49 54 50 $buttonValue = gettext("Create Theme"); // gettext variable51 $panel .= <<< END52 55 $buttonValue = gettext("Create Theme"); // gettext variable 56 $panel .= <<< END 57 53 58 <p> 54 59 <input type="hidden" name="action" value="templates:create" /> … … 56 61 </p> 57 62 58 </form>63 </form> 59 64 60 65 END; 61 66 62 $run_result .= $panel; 67 } 68 69 $run_result .= $panel; 63 70 64 71 ?>
