Moderating by MANAGER

Phoca Guestbook - creating guestbooks in Joomla! CMS
MooMoo
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 21 Aug 2008, 23:41

Moderating by MANAGER

Post by MooMoo »

Hello!
How can MANAGER (not Superadministrator)
moderate phoca guestbook in frontend?

P.S. It's very good component? but I need this function.

Thank you.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Moderating by MANAGER

Post by Jan »

Hi, only administrator or super administrator can delete or unpublish messages in the front... for moderator the php code must me changed...

Jan
If you find Phoca extensions useful, please support the project
MooMoo
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 21 Aug 2008, 23:41

Re: Moderating by MANAGER

Post by MooMoo »

Hello!
I try to do this.
I made new user (administrator (not superadministrator))
but he can't moderating in frontend.

Sorry for my bad English ))
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Moderating by MANAGER

Post by Jan »

both, admin and super admin should be able to delete or unpublish files in the front ???

Code: Select all

if (strtolower($user->usertype) == strtolower('super administrator') || $user->usertype == strtolower('administrator')) {
			...
}
If you find Phoca extensions useful, please support the project
MooMoo
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 21 Aug 2008, 23:41

Re: Moderating by MANAGER

Post by MooMoo »

Sorry? but can You tell me? in what file can I find these rows?
MooMoo
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 21 Aug 2008, 23:41

Re: Moderating by MANAGER

Post by MooMoo »

I found these strings in folder controllers/phocaguestbook.php? but I also can't moderatig by ADMINISTRATOR (((

Code: Select all

{
		global $mainframe;
		$user 		=& JFactory::getUser();
		$cid 		= JRequest::getVar( 'mid', null, '', 'int' );
		$id 		= JRequest::getVar( 'id', null, '', 'int' );
		$itemid 	= JRequest::getVar( 'Itemid', null, '', 'int' );
		$limitstart = JRequest::getVar( 'limitstart', null, '', 'int' );
		$model 		= $this->getModel('phocaguestbook');
	
		if (strtolower($user->usertype) == strtolower('super administrator') || $user->usertype == strtolower('administrator')) {

			if (count( $cid ) < 1) {
				JError::raiseError(500, JText::_( 'Select an item to delete' ) );
			}
			if(!$model->delete($cid))
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Moderating by MANAGER

Post by Jan »

???
If you find Phoca extensions useful, please support the project
Post Reply