Hello,
I'm new to RoundCube, just tried it today, liked it very much, so I decided to modify the code a little to suit my needs, but I'm not a php expert, that's why I need some help. I wanted to disable the e-mail and reply-to modifying options in the identities menu.
In the main.inc.php config file I added a new entry:
rcmail_config['can_change_fromaddr'] = TRUE;
but it seems like that $CONFIG['can_change_fromaddr'] is empty when I try to use it in the edit_identity.inc file.
What am I doing wrong?
Patch attached.
thanks, Kamm
--- 8< --- detachments --- 8< --- The following attachments have been detached and are available for viewing. http://detached.gigo.com/mm/wc/9GX2nH6F/roundcube_fromaddr.patch Only click these links if you trust the sender, as well as this message. --- 8< --- detachments --- 8< ---
List info: http://lists.roundcube.net/dev/
On 7/25/07, roundcube@kamm.hu roundcube@kamm.hu wrote:
Hello,
I'm new to RoundCube, just tried it today, liked it very much, so I decided to modify the code a little to suit my needs, but I'm not a php expert, that's why I need some help. I wanted to disable the e-mail and reply-to modifying options in the identities menu.
In the main.inc.php config file I added a new entry:
rcmail_config['can_change_fromaddr'] = TRUE;
but it seems like that $CONFIG['can_change_fromaddr'] is empty when I try to use it in the edit_identity.inc file.
What am I doing wrong?
In theory - nothing. Have you double checked that "$CONFIG" itself is set? If not, it might not be in your scope. I am assuming you patched against the "regular" release or the regular branch - $CONFIG has to be global then.
Hope that helps, Till _______________________________________________ List info: http://lists.roundcube.net/dev/
roundcube@kamm.hu wrote:
I'm new to RoundCube, just tried it today, liked it very much, so I decided to modify the code a little to suit my needs, but I'm not a php expert, that's why I need some help. I wanted to disable the e-mail and reply-to modifying options in the identities menu.
In the main.inc.php config file I added a new entry:
rcmail_config['can_change_fromaddr'] = TRUE;
but it seems like that $CONFIG['can_change_fromaddr'] is empty when I try to use it in the edit_identity.inc file.
What am I doing wrong?
I posted a patch before that used a config variable, and it worked just fine, but I was in a different file than you are working in.
See: http://trac.roundcube.net/trac.cgi/attachment/ticket/1291605/edit_identity_o...
I don't have much time to get into your patch to see what might be wrong, but I figured it might help to see another example.
I don't see any other references to $CONFIG in edit_identity.inc, so you may (as till said) have to access it via global. You may also need to load the config ( $CONFIG = rcmail_load_config(); ) if it isn't accessible from your current scope.
Reloading the config wouldn't necessarily be a good thing performance and style-wise, but it would get the job done...
Jim _______________________________________________ List info: http://lists.roundcube.net/dev/