Welcome to Geeklog, Anonymous Monday, December 23 2024 @ 11:13 am EST
Geeklog Forums
Editing User Functions
Status: offline
kilerb
Forum User
Regular Poster
Registered: 03/19/08
Posts: 119
How can I remove something from the user functions area? I was reading past posts about this and it said to go to lib-common.php but I think it might've changed since I don't see anything. I'm using the latest GL.
Thanks!
Thanks!
10
15
Quote
Status: offline
kilerb
Forum User
Regular Poster
Registered: 03/19/08
Posts: 119
On my site i have a newsletter plugin, and it says "unsubscribe from newsletter" in that area. I want that gone. Reason being is the newsletter plugin is supposed to add new members to the list, however it only does it about successfully 60% of the time. So, I constantly have to click "import current users" into the newsletter subscription area. So, when I do that, it just re-imports anyone that has unsubscribed in the past and it will just annoy them anyway to be back on the list. In this particular scenario, I'd rather have them leave the site than unsubscribe from the newsletter anyway.
Thanks...
Thanks...
13
18
Quote
Status: offline
kilerb
Forum User
Regular Poster
Registered: 03/19/08
Posts: 119
Thanks Dirk, I found this in there...
* returns the user option for this plugin
*
*/
function plugin_getuseroption_newsletter() {
global $_USER, $LANG_NL;
list($whitelist) = NL_fetchWhitelist();
if (!in_array($_USER['email'], $whitelist)) {
return array($LANG_NL['user_menu_subscribe'], $_CONF['site_url'].'/newsletter/index.php?view=add&email='.$_USER['email'].'&disp_mode=success', 0);
} else{
return array($LANG_NL['user_menu_unsubscribe'], $_CONF['site_url'].'/newsletter/index.php?view=delete&email='.$_USER['email'], 0);
}
}
Removed it, and the option "Unsubscribe from Newsletter" remains. Is there something else I have to do? Or did I remove the wrong thing?
Thanks
Text Formatted Code
/*** returns the user option for this plugin
*
*/
function plugin_getuseroption_newsletter() {
global $_USER, $LANG_NL;
list($whitelist) = NL_fetchWhitelist();
if (!in_array($_USER['email'], $whitelist)) {
return array($LANG_NL['user_menu_subscribe'], $_CONF['site_url'].'/newsletter/index.php?view=add&email='.$_USER['email'].'&disp_mode=success', 0);
} else{
return array($LANG_NL['user_menu_unsubscribe'], $_CONF['site_url'].'/newsletter/index.php?view=delete&email='.$_USER['email'], 0);
}
}
Removed it, and the option "Unsubscribe from Newsletter" remains. Is there something else I have to do? Or did I remove the wrong thing?
Thanks
17
14
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Hmm. Removing (or commenting out) that function should do the trick. That's the only official API that plugins have to get something into the User Functions block.
Or do you see the unsubscribe option somewhere else now?
bye, Dirk
Or do you see the unsubscribe option somewhere else now?
bye, Dirk
11
11
Quote
All times are EST. The time is now 11:13 am.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content