Try making a plugin it can get variable from the config an you shouldn't have to modify functions.js
Hi, I want to customize functions.js. I need a value from Roundcube configuration file (main.inc.php). How to access that value from javascript?
Try making a plugin it can get variable from the config an you shouldn't have to modify functions.js
It's a great idea, but i just need a little change in js. So, can I access Roundcube configuration via javascript?
to access a config from the js it first needs to be added to the env, in a plugin you can do something like
and then in the js you can access it atCode:$rcmail->output->set_env('myconfig', 'value');
Code:this.env.myconfig
Roundcube Patches: Sieverules, SpamAssassin Prefs, and more…
... or by rcmail.env.myconfig ...
Regards,
Rosali
__________________
MyRoundcube Project http://myroundcube.googlecode.com
MyRoundcube Online Demo - Free Email Address http://mail4us.net
MyRoundcube Plugins Generic Installation Guide http://mail4us.net/myroundcube/index.php
Mailing List http://mail4us.net/?_action=plugin.nabble
There are currently 1 users browsing this thread. (0 members and 1 guests)