I want to force users to use album categories. Does anyone know how to remove the "Personal Gallery of..." option in the dropdown box on the upload pic page (album_upload.php) and move pic page(album_modcp.php)?? I haven't been able to figure this part out.
So far I've disabled the upload button unless the user is in a category.....in includes/album_mod/album_personal.php replaced
--------------------------------------------------
if(((album_check_permission($auth_data, ALBUM_AUTH_UPLOAD) == true) && ($enable_picture_upload_switch == false)) || ($no_personal_gallery = false))
{
$template->assign_block_vars('enable_picture_upload_pg', array());
}
---------------------------------------------------
with this.....
---------------------------------------------------
if(((album_check_permission($auth_data, ALBUM_AUTH_UPLOAD) == true) && ($enable_picture_upload_switch == false)) || ($no_personal_gallery = false))
{
if(isset($_POST['cat_id']))
{
$template->assign_block_vars('enable_picture_upload_pg', array());
}
}
-----------------------------------------------------------
:::edit::
to remove the "Personal Gallery of" option from the move and upload pages.... edit includes/album_mod/album_hierarchy_functions.php
and in functions album_get_tree_option AND album_get_simple_tree_option change....
if ($cat_id != ALBUM_ROOT_CATEGORY)
to.....
if (($cat_id != ALBUM_ROOT_CATEGORY) && (strstr((strtoupper(album_get_object_lang($cat_id, 'name'))),'PERSONAL GALLERY OF') != true))
-----------------------------
::edit:::
-----------------------------
found a problem. the code works but users can't create categories in the main folder or move categories to the main folder since the "Personal gallery of" option is not listed. the following changes will put this option back on the category create/edit page......
-----------------------------------------------------------------
create a new function in includes/album_mod/album_hierarchy_functions.php called album_get_tree_option_main .... with the original album_get_tree_option function code (just copy album_get_tree_option function from an original album_hierarchy_functions.php file and rename the function name)
-----------------------------------------------------------------
edit .......... album_personal_cat_admin.php to point to the function by replacing.....
album_get_tree_option with album_get_tree_option_main
------------------------------------------
Ok.....so this post is a mess but maybe someone will benefit from it
SOLVED Force Users To Upload Photos To Categories
Subject: Re: [SOLVED] Force Users To Upload Photos To Categories
Thanks for explaining how to do...
:mrgreen: :mrgreen:
:mrgreen: :mrgreen:
Subject: Re: Force Users To Upload Photos To Categories
should also mention to get the "new folder" button to appear in the root of the gallery.....
in includes/album_mod/album_personal.php find
if( (album_check_permission($auth_data, ALBUM_AUTH_MANAGE_PERSONAL_CATEGORIES) == true) && ((($is_root_cat) && ($row['count'] > 0)) || (!$is_root_cat)))
..................AND REPLACE THE LINE WITH...............
if( (album_check_permission($auth_data, ALBUM_AUTH_MANAGE_PERSONAL_CATEGORIES) == true) && ((($is_root_cat) && ($row['count'] >= 0)) || (!$is_root_cat)))
info from ... http://www.icyphoenix.com/viewtopic...ghlight=#p17863
in includes/album_mod/album_personal.php find
if( (album_check_permission($auth_data, ALBUM_AUTH_MANAGE_PERSONAL_CATEGORIES) == true) && ((($is_root_cat) && ($row['count'] > 0)) || (!$is_root_cat)))
..................AND REPLACE THE LINE WITH...............
if( (album_check_permission($auth_data, ALBUM_AUTH_MANAGE_PERSONAL_CATEGORIES) == true) && ((($is_root_cat) && ($row['count'] >= 0)) || (!$is_root_cat)))
info from ... http://www.icyphoenix.com/viewtopic...ghlight=#p17863
Subject: Re: [SOLVED] Force Users To Upload Photos To Categories
Thanks for sharing, I should have fixed the last thing you posted.
Page 1 of 1
You cannot post new topicsYou cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events
This is a "Lo-Fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by Icy Phoenix based on phpBB
Generation Time: 0.2078s (PHP: 9% SQL: 91%)
SQL queries: 13 - Debug Off - GZIP Enabled