[CS-Project-svn_notify] SF.net SVN: cs-project: [802] trunk/1.2
Brought to you by:
crazedsanity
From: <cra...@us...> - 2008-02-07 07:56:56
|
Revision: 802 http://cs-project.svn.sourceforge.net/cs-project/?rev=802&view=rev Author: crazedsanity Date: 2008-02-06 23:56:52 -0800 (Wed, 06 Feb 2008) Log Message: ----------- Parses the sample config, and there's a warning about incorrect settings. Modified Paths: -------------- trunk/1.2/includes/content/settings.inc trunk/1.2/templates/content/settings/admin.content.tmpl Modified: trunk/1.2/includes/content/settings.inc =================================================================== --- trunk/1.2/includes/content/settings.inc 2008-02-07 07:36:05 UTC (rev 801) +++ trunk/1.2/includes/content/settings.inc 2008-02-07 07:56:52 UTC (rev 802) @@ -131,9 +131,14 @@ if(count($page->ftsSections) == 3 && $page->ftsSections[2] == 'admin') { if($user->is_admin() == 1) { - //add the template to show various admin stuff. - $page->add_template_var("admin_section", $page->templateRows['admin_section']); + //read the sample config. + $xmlObj = new XMLParser(file_get_contents(dirname(__FILE__) .'/../../docs/samples/sample_config.xml')); + $myData = $xmlObj->get_path('/CONFIG'); + $mainAttributes = $myData['attributes']; + unset($myData['type'], $myData['attributes']); + debug_print($myData); + //create an object with administrative capabilities. $adminUserClass = new adminUserClass($page->db); Modified: trunk/1.2/templates/content/settings/admin.content.tmpl =================================================================== --- trunk/1.2/templates/content/settings/admin.content.tmpl 2008-02-07 07:36:05 UTC (rev 801) +++ trunk/1.2/templates/content/settings/admin.content.tmpl 2008-02-07 07:56:52 UTC (rev 802) @@ -8,10 +8,18 @@ <th colspan="2">Config Settings</th> </tr> <tr> + <td colspan="2" align="center"> + <div class="note" style="width:60em"><b>NOTE:</b> You should be <font color="red"><b>absolutely certain</b></font> of the + effects of the changes you make here. Changing an item to an incorrect value make render the + installation useless. To rectify a broken configuration, you would need to modify the + <b>/lib/config.xml</b> file manually.</div> + </td> +</tr> +<tr> <th>Name/Description</th> <th>Value/Select Option</th> </tr> -<!-- BEGIN xsetting_text --> +<!-- BEGIN setting_text --> <tr> <td> <b>%%title%%</b><hr> @@ -21,7 +29,7 @@ <td><input name="%%index%%" type="text" value="%%value%%" %%disabled%%></td> </tr> <!-- END setting_text --> -<!-- BEGIN xsetting_select --> +<!-- BEGIN setting_select --> <tr> <td> <b>%%title%%</b><hr> @@ -40,7 +48,7 @@ </td> </tr> <!-- END setting_select --> -<!-- BEGIN xsetting_hidden --> +<!-- BEGIN setting_hidden --> <tr> <td> <!-- NOTE: should we even have hidden elements in the form? --> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |