diff options
author | Cash Costello <cash.costello@gmail.com> | 2009-06-03 12:08:45 +0000 |
---|---|---|
committer | Cash Costello <cash.costello@gmail.com> | 2009-06-03 12:08:45 +0000 |
commit | a60e2065b9b943e91a38751694fabae1a3873b3a (patch) | |
tree | b67ed805046232e518e4b65b80620548d3317339 /views/default | |
parent | 99a5db94c8e91913e42331bd73d37cb93f3cc2d8 (diff) | |
download | elgg-a60e2065b9b943e91a38751694fabae1a3873b3a.tar.gz elgg-a60e2065b9b943e91a38751694fabae1a3873b3a.tar.bz2 |
completed new admin settings - no longer uses default Elgg plugin settings in Tools Administration
Diffstat (limited to 'views/default')
-rw-r--r-- | views/default/admin/tidypics.php | 7 | ||||
-rw-r--r-- | views/default/object/image.php | 16 | ||||
-rw-r--r-- | views/default/settings/tidypics/edit.php | 85 | ||||
-rw-r--r-- | views/default/tidypics/image_menu.php | 8 |
4 files changed, 23 insertions, 93 deletions
diff --git a/views/default/admin/tidypics.php b/views/default/admin/tidypics.php index 561f3965a..cecf5409f 100644 --- a/views/default/admin/tidypics.php +++ b/views/default/admin/tidypics.php @@ -7,6 +7,13 @@ echo elgg_view('output/longtext', array('value' => elgg_echo("tidypics:admin:instructions"))); + global $CONFIG; + $system_url = $CONFIG->wwwroot . 'mod/tidypics/system.php'; +?> +<p> +<a href="<?php echo $system_url; ?>">Run Server Analysis</a> +</p> +<?php echo elgg_view("tidypics/forms/admin"); echo "</div>"; diff --git a/views/default/object/image.php b/views/default/object/image.php index d9204377f..5787bb39f 100644 --- a/views/default/object/image.php +++ b/views/default/object/image.php @@ -178,13 +178,15 @@ if ($photo_tags) { echo '</ul></div>'; // tagging code - echo elgg_view('tidypics/tagging', array( 'photo_tags' => $photo_tags, - 'links' => $photo_tag_links, - 'photo_tags_json' => $photo_tags_json, - 'file_guid' => $file_guid, - 'viewer' => $viewer, - 'owner' => $owner, ) ); - + if (get_plugin_setting('tagging', 'tidypics') != "disabled") { + echo elgg_view('tidypics/tagging', array( 'photo_tags' => $photo_tags, + 'links' => $photo_tag_links, + 'photo_tags_json' => $photo_tags_json, + 'file_guid' => $file_guid, + 'viewer' => $viewer, + 'owner' => $owner, ) ); + } + ?> <div id="tidypics_breadcrumbs"> <?php diff --git a/views/default/settings/tidypics/edit.php b/views/default/settings/tidypics/edit.php index 59ed912d1..ca388cd0e 100644 --- a/views/default/settings/tidypics/edit.php +++ b/views/default/settings/tidypics/edit.php @@ -1,93 +1,12 @@ <? global $CONFIG; $system_url = $CONFIG->wwwroot . 'mod/tidypics/system.php'; + $settings_url = $CONFIG->wwwroot . 'mod/tidypics/admin.php'; ?> <p> <a href="<?php echo $system_url; ?>">Run Server Analysis</a> </p> - -<?php - $image_lib = $vars['entity']->image_lib; - if (!$image_lib) $image_lib = 'GD'; -?> -<p> - <?php echo elgg_echo('tidypics:image_lib'); ?> - - <?php - echo elgg_view('input/pulldown', array( - 'internalname' => 'params[image_lib]', - 'options_values' => array( - 'GD' => 'GD', - 'ImageMagick' => 'ImageMagick', - ), - 'value' => $image_lib - )); - ?> - <br /> - <?php - $im_path = $vars['entity']->im_path; - if(!$im_path) $im_path = "/usr/bin/"; - ?> - <?php echo elgg_echo('tidypics:settings:im_path'); ?> - <?php echo elgg_view('input/text', array('internalname' => 'params[im_path]', 'value' => $im_path)); ?> -</p> - -<?php - $maxfilesize = $vars['entity']->maxfilesize; - if (!$maxfilesize) $maxfilesize = (int) 5; //set the default maximum file size to 5MB - -?> -<p> - <?php echo elgg_echo('tidypics:settings:maxfilesize'); ?> - - <?php echo elgg_view('input/text', array('internalname' => 'params[maxfilesize]', 'value' => $maxfilesize)); ?> -</p> -<?php - $image_lib = $vars['entity']->image_lib; - if (!$image_lib) $image_lib = 'GD'; -?> -<p> - <?php - echo elgg_echo('tidypics:settings:download_link'); - $download_link = $vars['entity']->download_link; - if (!$download_link) $download_link = 'yes'; - ?> - - <?php - echo elgg_view('input/pulldown', array( - 'internalname' => 'params[download_link]', - 'options_values' => array( - 'yes' => 'yes', - 'no' => 'no', - ), - 'value' => $download_link)); - ?> -</p> -<p> - <?php - echo elgg_echo('tidypics:settings:river_view'); - $river_view = $vars['entity']->river_view; - if (!$river_view) $river_view = 'all'; - ?> - - <?php - echo elgg_view('input/pulldown', array( - 'internalname' => 'params[river_view]', - 'options_values' => array( - 'all' => 'all', - '1' => '1', - 'none' => 'none' - ), - 'value' => $river_view)); - ?> -</p> - -<?php - $watermark_text = $vars['entity']->watermark_text; - if(!$watermark_text) $watermark_text = ""; -?> <p> - <?php echo elgg_echo('tidypics:settings:watermark'); ?> - <?php echo elgg_view('input/text', array('internalname' => 'params[watermark_text]', 'value' => $watermark_text)); ?> +<a href="<?php echo $settings_url; ?>">Change Tidypics Settings</a> </p>
\ No newline at end of file diff --git a/views/default/tidypics/image_menu.php b/views/default/tidypics/image_menu.php index dcec9b35a..9257d780a 100644 --- a/views/default/tidypics/image_menu.php +++ b/views/default/tidypics/image_menu.php @@ -14,13 +14,15 @@ $viewer = $vars['viewer'];
$owner = $vars['owner'];
- // only owner and friends of owner can tag
- if ($viewer && $viewer->guid == $owner->guid || user_is_friend($owner->guid, $viewer->guid)) {
+ if (get_plugin_setting('tagging', 'tidypics') != "disabled") {
+ // only owner and friends of owner can tag
+ if ($viewer && $viewer->guid == $owner->guid || user_is_friend($owner->guid, $viewer->guid)) {
?>
<li id="start_tagging"><a id="tag_control" href="javascript:void(0)" onclick="startTagging()"><?= elgg_echo('tidypics:tagthisphoto') ?></a></li>
<?php
+ }
}
- if (get_plugin_setting('download_link', 'tidypics') != "no") {
+ if (get_plugin_setting('download_link', 'tidypics') != "disabled") {
?>
<li id="download_image"><a href="<?php echo $vars['url']; ?>action/tidypics/download?file_guid=<?php echo $file_guid; ?>"><?php echo elgg_echo("image:download"); ?></a></li>
<?php
|