Roxen.git
/
server
/
config_interface
/
sites
/
add_module.pike
version
»
Context lines:
10
20
40
80
file
none
3
Roxen.git/server/config_interface/sites/add_module.pike:1:
-
// $Id: add_module.pike,v 1.
82
2006/01/
19
13
:
26
:
21
jonasw
Exp $
+
// $Id: add_module.pike,v 1.
83
2006/01/
25
10
:
22
:
30
anders
Exp $
#include <config_interface.h> #include <module.h> #include <module_constants.h> #include <roxen.h> int no_reload() { if( sizeof( already_added ) ) return 1; // Reloading this script now would destroy state.
Roxen.git/server/config_interface/sites/add_module.pike:139:
"<gbutton href='add_module.pike?config=&form.config:http;" "&reload_module_list=yes&method=%s' " "> %s </gbutton>" "</td><td>" "<gbutton href='site.html/&form.config;/' " "> %s </gbutton>" "</td></tr></table>" "<p>\n</if>%s\n</p>\n" "</st-page></subtablist></td></tr></table>" "</cv-split></content></tmpl>",
-
LOCALE(
258
,"Add Module"),
+
LOCALE(
251
,"Add Module"),
noform?" noform='noform'":"",
-
LOCALE(
0
, "List Type"),
+
LOCALE(
421
, "List Type"),
method,
-
LOCALE(
0
, "Normal"),
+
LOCALE(
280
, "Normal"),
// LOCALE(0, "Fast"),
-
LOCALE(
0
, "Faster"),
-
LOCALE(
0
, "Compact"),
-
LOCALE(
0
, "Really Compact"),
+
LOCALE(
284
, "Faster"),
+
LOCALE(
286
, "Compact"),
+
LOCALE(
531
, "Really Compact"),
(show_search_form && search_form) || "", method, LOCALE(272,"Reload Module List"), LOCALE(202,"Cancel"), content); } string module_name_from_file( string file )
Roxen.git/server/config_interface/sites/add_module.pike:572:
{ int x; string method = get_method(id); string header = ("<tr><td colspan='2'><table width='100%' cellspacing='0' " "border='0' cellpadding='3' bgcolor='&usr.content-titlebg;'>" "<tr><td nowrap='nowrap' valign='top'>"); if (id->variables->mod_query) { header+=("<gbutton hspace='5' vspace='5' dim='1'> "+LOCALE(267, "View")+ " </gbutton><br>"
-
"<submit-gbutton hspace='5' vspace='2'> "+LOCALE(
0
, "Add Modules")+
+
"<submit-gbutton hspace='5' vspace='2'> "+LOCALE(
200
, "Add Modules")+
" </submit-gbutton>"); x = 1; } else if( id->variables->unfolded == c ) { header+=("<a name='"+Roxen.html_encode_string(c)+ "'></a><gbutton hspace='5' vspace='5' dim='1'> "+LOCALE(267, "View")+ " </gbutton><br>"
-
"<submit-gbutton hspace='5' vspace='2'> "+LOCALE(
0
, "Add Modules")+
+
"<submit-gbutton hspace='5' vspace='2'> "+LOCALE(
200
, "Add Modules")+
" </submit-gbutton>"); x=1; } else header+=("<a name='"+Roxen.html_encode_string(c)+ "'></a><gbutton hspace='5' vspace='5' " "href='add_module.pike?config=&form.config;" "&method=" + method + "&unfolded="+Roxen.http_encode_url(c)+ "#"+Roxen.http_encode_url(c)+"' > "+
Roxen.git/server/config_interface/sites/add_module.pike:642:
} int first; array(int|string) class_visible_compact( string c, string d, int size, RequestID id ) { string res=""; if(first++) res = "</select><br /><submit-gbutton vspace='3'> "+
-
LOCALE(
0
, "Add Modules")+ " </submit-gbutton> ";
+
LOCALE(
200
, "Add Modules")+ " </submit-gbutton> ";
res += "<p><a name='"+Roxen.html_encode_string(c)+ "'></a><font size='+2'>"+c+"</font><br />"+d+"<p>" "<select size='"+size+"' multiple name='module_to_add' class='add-module-select'>"; return ({ 1, res }); } string describe_module_compact( object module, object block ) { if(!block) { //string modname = strip_leading (module->get_name());
Roxen.git/server/config_interface/sites/add_module.pike:673:
string page_compact( RequestID id ) { first=0; string desc, err; [desc,err] = get_module_list( describe_module_compact, class_visible_compact, id ); return page_base(id, "<form action='add_module.pike' method='POST'>" "<input type='hidden' name='config' value='&form.config;'>"+ desc+"</select><br /><submit-gbutton vspace='3'> "
-
+LOCALE(
0
, "Add Modules")+" </submit-gbutton><p>"
+
+LOCALE(
200
, "Add Modules")+" </submit-gbutton><p>"
+err+"</form>", ); } string page_really_compact( RequestID id ) { first=0; object conf = roxen.find_configuration( id->variables->config ); object ec = roxenloader.LowErrorContainer();
Roxen.git/server/config_interface/sites/add_module.pike:714:
in = lower_case((string)in); //sscanf(in, "%*s: %s", in); return in; }), mods); string res = ""; mixed r; License.Key license_key = conf->getvar("license")->get_key(); array(RoxenModule) locked_modules = ({});
-
if( (r = class_visible_compact( LOCALE(
0
,"Add Modules"),
+
if( (r = class_visible_compact( LOCALE(
200
,"Add Modules"),
LOCALE(273,"Select one or several modules to add."), sizeof(mods), id )) && r[0] ) { res += r[1]; foreach(mods, object q) { if( (!q->get_description() || (q->get_description() == "Undocumented")) && q->type == 0 ) continue; object b = module_nomore(q->sname, q, conf); if( !b && q->locked && (!license_key || !q->unlocked(license_key)) )
Roxen.git/server/config_interface/sites/add_module.pike:741:
} else { res += r[1]; } master()->set_inhibit_compile_errors( 0 ); return page_base(id, "<form action=\"add_module.pike\" method=\"post\">" "<input type=\"hidden\" name=\"config\" value=\"&form.config;\" />"+ res+"</select><br /><submit-gbutton> "
-
+LOCALE(
0
, "Add Modules")+" </submit-gbutton><br />"
+
+LOCALE(
200
, "Add Modules")+" </submit-gbutton><br />"
+pafeaw(ec->get(),ec->get_warnings(), locked_modules)+"</form>", ); } string decode_site_name( string what ) { if( (int)what ) return (string)((array(int))(what/","-({""}))); return what;