//settings\r
'tidypics:settings' => 'Settings',\r
'tidypics:admin:instructions' => 'These are the core Tidypics settings. Change them for your setup and then click save.',\r
- 'tidypics:settings:image_lib' => "Image Library: ",\r
+ 'tidypics:settings:image_lib' => "Image Library",\r
'tidypics:settings:download_link' => "Show download link",\r
'tidypics:settings:tagging' => "Enable photo tagging",\r
'tidypics:settings:photo_ratings' => "Enable photo ratings (requires rate plugin of Miguel Montes or compatible)",\r
--- /dev/null
+<?php\r
+\r
+ $img_type = get_subtype_id('object', 'image');\r
+ $query = "SELECT count(guid) as total from {$CONFIG->dbprefix}entities where subtype={$img_type}";\r
+ $total = get_data_row($query);\r
+ $num_images = $total->total;\r
+ \r
+ $img_type = get_subtype_id('object', 'album');\r
+ $query = "SELECT count(guid) as total from {$CONFIG->dbprefix}entities where subtype={$img_type}";\r
+ $total = get_data_row($query);\r
+ $num_albums = $total->total;\r
+\r
+ $num_comments_photos = count_annotations(0, 'object', 'image', 'generic_comment');\r
+ $num_comments_albums = count_annotations(0, 'object', 'album', 'generic_comment');\r
+ \r
+ $num_views = count_annotations(0, 'object', 'image', 'tp_view');\r
+ \r
+ if (get_plugin_setting('tagging', 'tidypics') != "disabled")\r
+ $num_tags = count_annotations(0, 'object', 'image', 'phototag');\r
+?>\r
+<p>\r
+<br />\r
+An image library is required by Tidypics to perform various manipulations: resizing on upload, watermarking, rotation, and cropping.\r
+There are three image library options with Tidypics: PHP extension <a href="http://www.php.net/manual/en/book.image.php">GD</a>, \r
+<a href="http://www.imagemagick.org/">ImageMagick</a> called via a system call, and the PHP extension \r
+<a href="http://pecl.php.net/package/imagick/">imagick</a>. GD is the most common of the three on hosted servers but suffers \r
+from serious memory usage problems when resizing photos. If you have access to ImageMagick (whether through system calls or the\r
+PHP extension), we recommend that you use that.\r
+</p><p>\r
+<h3>Testing ImageMagick Commandline</h3>\r
+To use the ImageMagick executables, PHP must be configured to allow calls to exec(). You can check our \r
+<a href="<?php echo $CONFIG->wwwroot . 'mod/tidypics/pages/server_analysis.php'; ?>">server analysis page</a> to find out the \r
+configuration of your server. Next, you need to determine the path to ImageMagick on your server. Your hosting service should \r
+be able to provide this to you. You can test if the location is correct below. If successful, it should display the version of \r
+ImageMagick installed on your server. \r
+</p>\r
+<p>\r
+<br />\r
+<?php echo elgg_echo('tidypics:settings:im_path'); ?><br />\r
+<input name="im_location" type="text" />\r
+<input type="submit" value="Submit" onclick="TestImageMagickLocation();" />\r
+</p>\r
+<div id="im_results"></div>\r
+\r
+<script type="text/javascript">\r
+function TestImageMagickLocation()\r
+{\r
+ var loc = $('input[name=im_location]').val();\r
+ $("#im_results").html("");\r
+ $.ajax({\r
+ type: "GET",\r
+ url: "<?php echo $CONFIG->wwwroot . 'mod/tidypics/actions/imtest.php'; ?>",\r
+ data: {location: loc},\r
+ cache: false,\r
+ success: function(html){\r
+ $("#im_results").html(html);\r
+ }\r
+ });\r
+}\r
+</script>
\ No newline at end of file