Remove login menu option when bridged to Joomla! Remove login menu option when bridged to Joomla!
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Remove login menu option when bridged to Joomla!

Started by Necula, January 08, 2006, 10:16:36 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Necula

I've got Coppermine bridged with Joomla! using the mabo bridging component and it all seems to be working correctly.  Howevere since it's bridged I'm trying to eliminate the amount of login / logout options.  Since my users login from the main Joomla front page, I want to remove the login / logout option that is part of cpg, as the user details are passed from joomla.

I'm using the Water Drop theme and when I look at theme.php or template.html I can't see anything to comment out.

Is this easy or possible to do?

Many thanks.

Necula

I've just tried using the plugin that was supplied in a previous post but that doesn't seem to work for me..

Necula

Tried copying certain sections from sample.php and keep getting:

Fatal error: Call to undefined function: addbutton() in /home/sites/hemelwargaming.com/public_html/cpg143/themes/water_drop/theme.php on line 54

ecto

Copy the function addbutton() from the sample theme.php to your theme.php.

I guess you were referring to this thread when you mentioned the plugin. If you had read the whole thread you would have gotten your answer, or if you had searched the forum. Please do so next time.

Necula

I had read the whole thread AND searched the forum but did not quite understand the solutions proposed.  One minute the solution was editing files, next it was a plugin.  I was hoping someone helpful could give a definitive answer and say which bits you need to copy, comment out or whether the plugin can be used as in or needs modifying.

ecto

I'm sorry to say that I don't know why the plugin doesn't work for you. You should post about it in the thread dealing with the plugin to see if it can be solved, as using a plugin is a lot better than modifying the PHP files.

The query I replied to was about the call to an undefined function. A vary straight-forward answer to that specific question is right there in the thread - "It means you need to copy the function over, too." I guess maybe you missed that part.

Anyhow, I haven't done this myself, but from reading what it says in that thread you should

1) Copy over the "if (!defined('THEME_HAS_NO_SYS_MENU_BUTTONS')) {" section, the addbutton() function and the assemble_template_buttons() function from themes/sample/theme.php to themes/your_theme/theme.php
2) Comment out the lines dealing with the buttons you don't want to show, e.g. these:


    addbutton($sys_menu_buttons,'{LOGIN_LNK}','{LOGIN_TITLE}','{LOGIN_TGT}','login','');
    addbutton($sys_menu_buttons,'{LOGOUT_LNK}','{LOGOUT_TITLE}','{LOGOUT_TGT}','logout','');


Let us know if it works.

Necula

Thanks for your help.  Looks like I have the plugin working now.  I'll know for the future never to try installing this stuff at 1am in the morning!  ;D

Cheers