diff --git a/interface/ispconfig/interface/client/templates/client_edit_address.htm b/interface/ispconfig/interface/client/templates/client_edit_address.htm
new file mode 100644
index 0000000000000000000000000000000000000000..6d2625028c6ab088819d3b96a3d4ad088aeebb26
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/client_edit_address.htm
@@ -0,0 +1,101 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/interface/ispconfig/interface/client/templates/client_edit_limits.htm b/interface/ispconfig/interface/client/templates/client_edit_limits.htm
new file mode 100644
index 0000000000000000000000000000000000000000..200629eb35047c4f6bae5d7f1fa94369f82b256a
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/client_edit_limits.htm
@@ -0,0 +1,190 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/interface/ispconfig/interface/client/templates/client_template_edit_limits.htm b/interface/ispconfig/interface/client/templates/client_template_edit_limits.htm
new file mode 100644
index 0000000000000000000000000000000000000000..390f1f5b02297bed68e8ac549cd6e5f5941cb0cc
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/client_template_edit_limits.htm
@@ -0,0 +1,124 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/interface/ispconfig/interface/client/templates/client_template_edit_template.htm b/interface/ispconfig/interface/client/templates/client_template_edit_template.htm
new file mode 100644
index 0000000000000000000000000000000000000000..6c9d905340c747b10454ae98010cc0f732e336eb
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/client_template_edit_template.htm
@@ -0,0 +1,28 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/interface/ispconfig/interface/client/templates/client_template_list.htm b/interface/ispconfig/interface/client/templates/client_template_list.htm
new file mode 100644
index 0000000000000000000000000000000000000000..5892a9614701c0e86ff3b7a7afd3e8b87faacc90
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/client_template_list.htm
@@ -0,0 +1,53 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/client/templates/clients_list.htm b/interface/ispconfig/interface/client/templates/clients_list.htm
new file mode 100644
index 0000000000000000000000000000000000000000..f8447712d4231b636f62e4882962fea1b80b96a9
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/clients_list.htm
@@ -0,0 +1,63 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/interface/ispconfig/interface/client/templates/reseller_edit_address.htm b/interface/ispconfig/interface/client/templates/reseller_edit_address.htm
new file mode 100644
index 0000000000000000000000000000000000000000..798fdf98ad7357f365099807fcf2f832897b1254
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/reseller_edit_address.htm
@@ -0,0 +1,101 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/interface/ispconfig/interface/client/templates/reseller_edit_limits.htm b/interface/ispconfig/interface/client/templates/reseller_edit_limits.htm
new file mode 100644
index 0000000000000000000000000000000000000000..8acaf4bd78e7c8a7cce00dbc27215e13fc18e7db
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/reseller_edit_limits.htm
@@ -0,0 +1,179 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/interface/ispconfig/interface/client/templates/resellers_list.htm b/interface/ispconfig/interface/client/templates/resellers_list.htm
new file mode 100644
index 0000000000000000000000000000000000000000..fbe90a6f99ef79edd40febbb03b1f4e7f67f05db
--- /dev/null
+++ b/interface/ispconfig/interface/client/templates/resellers_list.htm
@@ -0,0 +1,63 @@
+
";
+ $n1++;
+}
+}
+
+$record["nav"] = $content;
+
+
+$app->tpl->setVar($record);
+
+
+$app->tpl->setLoop('records',$modules_list);
+
+$app->tpl_defaults();
+$app->tpl->pparse();
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/index.php b/interface/ispconfig/interface/designer/index.php
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git a/interface/ispconfig/interface/designer/lib/admin.conf.php b/interface/ispconfig/interface/designer/lib/admin.conf.php
new file mode 100644
index 0000000000000000000000000000000000000000..8dce5a57346d86280d73e7590a26388958388195
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/admin.conf.php
@@ -0,0 +1,4 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg.lng b/interface/ispconfig/interface/designer/lib/lang/bg.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/bg_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2138e041640dc2dca30f7f24d18b782349498756
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/bg_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4a053a3c58fb4186b039aa8b0219b4a2061ec222
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/bg_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..78cf0edda16df8e16b0ae80eb399eddfd1426afb
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/bg_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..50f0309f7017595c06a65df18d9fc4dbbdc8e5b6
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_module_edit.lng
@@ -0,0 +1,12 @@
+Description
Modulename: Name of the module directory. Only numbers, chars and underscore allowed. Moduletitle: Will be shown in the (upper) main navigation. Template file: Template file of the module. Currently';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/bg_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..31209a0757cdbb09e8a213b71fbdbcab16dc3429
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/bg_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7698aac73814678727fddac0e435001e8742b7f8
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/bg_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9a928f5cb6dd41dbed0557a6a0073fcf21a8d0c6
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/bg_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/bg_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3cbe96358f0947c9e8d6d13e19e78bbfabc8c2f9
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/bg_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br.lng b/interface/ispconfig/interface/designer/lib/lang/br.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/br_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7d7534a4ee77f45f46e75296cee1e1fa55f9faa7
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/br_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b16ce554b0e6240d22d41c107cbd05f3e3fd47b3
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/br_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..5b68a316518de6c4000cfa6ca6d6ad0fdc83d588
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/br_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..34471acd297184a4db31fb68e219adfda91a919e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_module_edit.lng
@@ -0,0 +1,22 @@
+Descrição
+
+Nome do Módulo: Nome do diretório do módulo. Somente números, letras e underscores são permitidos.
+Título do Módulo: Será exibido em caixa alta no menu de navegação.
+Arquivo de Gabarito: Arquivo de Gabarito do Módulo Disponível: modulo.tpl.htm e modulo_tree.tpl.htm. O padrão é modulo.tpl.htm.
+Frame de Navegação: Se modulo_tree.tpl.htm foi selecionado como arquivo de gabarito, insira aqui o caminho do script para o frame a esquerda.
+Página Padrão: Esta página será exibida quando o módulo for aberto.
+Tamanho da Aba: Tamanho das abas na navegação principal. Este campo fica em branco por padrão. Você pode informar valores absolutos em pixels (ex.: 20) ou valores relativos (ex.: 20%).
+Dica: Todos os caminhos são relativos ao diretório web.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/br_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..822263a4ad64f7cc82fee8ab785b132726a3045d
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/br_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c5e3266a7b91b685168d1c7593f56a33db9f4dad
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/br_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..5eafa775af58b0bce4215ef02c8a5e4e7ef8a076
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/br_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/br_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1fb18007143161558febd71f4e727bf99aa17f07
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/br_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de.lng b/interface/ispconfig/interface/designer/lib/lang/de.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/de_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..74bf458d90993f4879d2fe10e8696e1d5d8adf5e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/de_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..998a64f702453ede0420223dfbd5a47550b8025a
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/de_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b19fd34457ed9ca267e19a01ad9605368536d752
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/de_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..6eacd64b1de87cab59ed74c470cc351f9f20e243
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_module_edit.lng
@@ -0,0 +1,12 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/de_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..60406302030a4d1572afa43eae185ba4878643b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/de_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d5142f03cb3f38a0864004394226834bb7f396c1
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/de_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8c0c33c1a6d71681c20266f550f18a4eff17e86d
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/de_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/de_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f4b2ad11f8a610372f2c5f502abf2d1d41279150
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/de_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/en.lng b/interface/ispconfig/interface/designer/lib/lang/en.lng
new file mode 100644
index 0000000000000000000000000000000000000000..15c5adc7fae9b7dab7ba2410a6cabc4361f76852
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en.lng
@@ -0,0 +1,3 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/en_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f55e0f4caf455adc002e966b538c23dd87779b90
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_form_edit.lng
@@ -0,0 +1,26 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/en_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..21a76877d7af2bdfebce90c3a11edbd160c838e9
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_form_list.lng
@@ -0,0 +1,7 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/en_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..54b14f6e180ccc50c4a64ac91eddf4620a8f7f89
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_form_show.lng
@@ -0,0 +1,18 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/en_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..285a363df3b47940024ed92de554dbda1edad777
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_module_edit.lng
@@ -0,0 +1,23 @@
+Description
+
+Modulename: Name of the module directory. Only numbers, chars and underscore allowed.
+Moduletitle: Will be shown in the (upper) main navigation.
+Template file: Template file of the module. Currently available: module.tpl.htm and module_tree.tpl.htm. Default is module.tpl.htm.
+NaviFrame: If module_tree.tpl.htm selected as template file, enter here the path to the script file for the left frame.
+Default page: These page will be shown when the module is opened.
+Tab width: Width of the Tabs in the main navigation. The field is empty by default. You can enter values absolute in pixel (e.g 20) or relative (e.g 20%).
+Hint: All paths are relative to the directory "web".
+';
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/en_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..45260fd9a84a91187ce8688af1a2c4ea6de6ca6a
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_module_list.lng
@@ -0,0 +1,5 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/en_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3600238f74cfd416275c0647fbfe48b436d3feb8
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/en_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..56eee32deb6c5a708dc7e5961e6cb13c6d01839c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/en_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/en_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e76f5f332af1ad2447b741ee96c3cd3f173f3ad7
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/en_module_show.lng
@@ -0,0 +1,17 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/lib/lang/es.lng b/interface/ispconfig/interface/designer/lib/lang/es.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/es_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c5312559bbf511191f1bbac03d6ac8a03d5df969
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/es_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3334d0b29448a633561a4dacac33ac7dc1432c85
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/es_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4cac14529bc76429b369fd4432915064162b0895
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/es_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c126365a5457445f04ed17799675944926f71a12
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_module_edit.lng
@@ -0,0 +1,12 @@
+Descripción
Nombre del módulo: Nombre del directorio del módulo. Sólo se permiten números, carácteres y subrayados. Título del módulo: Se mostrará en la barra de navegación principal. Fichero de plantilla: Fichero de la plantilla del módulo. Disponibles actualmente: module.tpl.htm y module_tree.tpl.htm. Por defecto: module.tpl.htm. Marco de navegación: Si el fichero de plantilla module_tree.tpl.htm está seleccionado, introduzca aquí la ruta al fichero del script del marco de la izquierda. Página por defecto: Esta página se mostrará cuando el módulo se abra. Ancho de pestaña: Ancho de las pestañas en la barra de navegación. El campo está vacío por defecto. Puede introducir valores absolutos en píxeles (p.ej. 20) o relativos (p.ej. 20%). Pista: Todas las rutas son relativas al directorio.';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/es_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2805a07bc9c3b0c8897fe4f4708455f7f5f83f85
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/es_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..22688b6e1783197683eedd97c9be333488b12c59
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/es_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ec39e5f8994f04a5e862126ce8f4135f33f6138d
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/es_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/es_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1f1199de532466f36f200fb917072aab4a394e28
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/es_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi.lng b/interface/ispconfig/interface/designer/lib/lang/fi.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fi_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c9a13038a4823d3ab77e498fcd30b8b8c207a289
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/fi_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9052c8f0c9df08704dbe523cb814417fde52e72f
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/fi_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..247a95be59142ae9fb6b753a051489050dbe072e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fi_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8bb4a5c09e01eee3acf7929732d100d337b121d8
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_module_edit.lng
@@ -0,0 +1,22 @@
+Kuvaus
+
+Modulename: Ohjelmaosion kansion nimi. Vain numerot,kirjaimet ja alaviiva on sallittu.
+Moduletitle: Tulee näkymään ylemmässä päävalikossa.
+Template file: Ohjelmaosion mallitiedosto. Käytettävissä tällä hetkellä: module.tpl.htm ja module_tree.tpl.htm. Oletus on module.tpl.htm.
+NaviFrame: Jos module_tree.tpl.htm valittiin mallitiedostoksi, kirjoita tähän vasemman kehyksen skriptitiedoston polku.
+Default page: Tämä sivu näytetetään kun ohjelmaosio avataan.
+Tab width: Päälikon painikkeiden leveys. Kenttä on oletuksenä tyhjä. Voit antaa arvon pikseleinää tai prosentteina. (esim. 20 tai 20%).
+Vihje: Kaikki polut ovat suhteellisia web-kansioon, eivät absoluuttisia.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/fi_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f07c9a377bd2fc6807478f1579497f43fdf6c789
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fi_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b7c03eafb0c89d8e12b9a5cda7a611ec155c7c5d
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fi_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..5f32d5848145dbb98e8f4dbdf0e07d9cac896b37
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fi_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/fi_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..066d92f583925a1c0c59aea57ae91e1014b22992
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fi_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr.lng b/interface/ispconfig/interface/designer/lib/lang/fr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fr_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4ef20b0b296449f1bdda8bd02e1f87804c378407
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/fr_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b20b8472799f446db3bb35e09a0fae0c9cea27ef
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/fr_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9c9580ce16718645f51c44b40d6d411ff2804a9c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fr_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c2eab9481b31d6f05126d90bcea77286fbe63276
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_module_edit.lng
@@ -0,0 +1,14 @@
+Description
Nom du Module: Nom du rpertoire du module. Seulement nombres, lettres et underscore sont autoriss. Titre du Module: Seras affich dans le menu de navigation (suprieur). Fichier Template: Fichier Template du module. Disponible actuellement: module.tpl.htm et module_tree.tpl.htm. Par dfaut module.tpl.htm. Frame de Navigation: Si module_tree.tpl.htm est choisi comme fichier template, entrer ici le chemin vers le script de la frame de gauche. Page par Dfaut: Cette page seras affiche quand le module seras ouvert. Largeur tableau: Largeur des tableau dans la frame principale. Le champ est vide par defaut. Vous pouvez entrer une valeur absolue en pixel (e.g 20) ou relative (e.g 20%). Note: Tous les paths sont relatifs par rapport au dossier web.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/fr_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..5389ac9453155705e8c72a8238ee19c8d2b0fede
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fr_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..423588c935baf01c002281310d29b8e5d7cd6657
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/fr_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ada5f4ee8113811c4a6a469869de42e9790d4f00
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/fr_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/fr_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..da09511d759c1f4d4e922f0de764ff007e6b2153
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/fr_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu.lng b/interface/ispconfig/interface/designer/lib/lang/hu.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/hu_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..54fe173ecad0aa36c916cdf2c7c8c3611c43c45c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/hu_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..47432257fd972592d3b506b64e970910d9d0517b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/hu_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..12be609a1fb4de4e463b2bc5d8bc9be2b9c12267
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/hu_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..592ccd76bc803ce0a50ce438001b92ec68000a2e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_module_edit.lng
@@ -0,0 +1,22 @@
+Description
+
+Modulename: Name of the module directory. Only numbers, chars and underscore allowed.
+Moduletitle: Will be shown in the (upper) main navigation.
+Template file: Template file of the module. Currently available: module.tpl.htm and module_tree.tpl.htm. Default is module.tpl.htm.
+NaviFrame: If module_tree.tpl.htm selected as template file, enter here the path to the script file for the left frame.
+Default page: These page will be shown when the module is opened.
+Tab width: Width of the Tabs in the main navigation. The field is empty by default. You can enter values absolute in pixel (e.g 20) or relative (e.g 20%).
+Hint: All paths are relative to the directory web.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/hu_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..bc9ebed5807f2dc7a411c9102c9c55dca2e4acec
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/hu_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..fa5f15aa9e6072a077de378f309bf9e44010ceaa
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/hu_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..23f7d1592ab86b82a3d29ee7e895fca1f46b26b6
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/hu_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/hu_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..357fca1498a00dfd67879c21985a49d08400fee6
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/hu_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it.lng b/interface/ispconfig/interface/designer/lib/lang/it.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/it_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..54fe173ecad0aa36c916cdf2c7c8c3611c43c45c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/it_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..47432257fd972592d3b506b64e970910d9d0517b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/it_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..12be609a1fb4de4e463b2bc5d8bc9be2b9c12267
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/it_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..592ccd76bc803ce0a50ce438001b92ec68000a2e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_module_edit.lng
@@ -0,0 +1,22 @@
+Description
+
+Modulename: Name of the module directory. Only numbers, chars and underscore allowed.
+Moduletitle: Will be shown in the (upper) main navigation.
+Template file: Template file of the module. Currently available: module.tpl.htm and module_tree.tpl.htm. Default is module.tpl.htm.
+NaviFrame: If module_tree.tpl.htm selected as template file, enter here the path to the script file for the left frame.
+Default page: These page will be shown when the module is opened.
+Tab width: Width of the Tabs in the main navigation. The field is empty by default. You can enter values absolute in pixel (e.g 20) or relative (e.g 20%).
+Hint: All paths are relative to the directory web.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/it_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..bc9ebed5807f2dc7a411c9102c9c55dca2e4acec
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/it_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..fa5f15aa9e6072a077de378f309bf9e44010ceaa
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/it_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..23f7d1592ab86b82a3d29ee7e895fca1f46b26b6
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/it_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/it_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e295047b0e651aefabd81fa644d9467520b900fb
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/it_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja.lng b/interface/ispconfig/interface/designer/lib/lang/ja.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ja_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..130ca07889506eebba2a4a2d21aa405071b2b3fc
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/ja_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..47432257fd972592d3b506b64e970910d9d0517b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/ja_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..37017fa4a895bcf318bb11deaeb51473ebec49a0
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ja_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..592ccd76bc803ce0a50ce438001b92ec68000a2e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_module_edit.lng
@@ -0,0 +1,22 @@
+Description
+
+Modulename: Name of the module directory. Only numbers, chars and underscore allowed.
+Moduletitle: Will be shown in the (upper) main navigation.
+Template file: Template file of the module. Currently available: module.tpl.htm and module_tree.tpl.htm. Default is module.tpl.htm.
+NaviFrame: If module_tree.tpl.htm selected as template file, enter here the path to the script file for the left frame.
+Default page: These page will be shown when the module is opened.
+Tab width: Width of the Tabs in the main navigation. The field is empty by default. You can enter values absolute in pixel (e.g 20) or relative (e.g 20%).
+Hint: All paths are relative to the directory web.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/ja_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..bc9ebed5807f2dc7a411c9102c9c55dca2e4acec
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ja_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..fa5f15aa9e6072a077de378f309bf9e44010ceaa
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ja_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..23f7d1592ab86b82a3d29ee7e895fca1f46b26b6
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ja_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/ja_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..6fe8d45bee9a92a0eca4ba03bcd353b60eec50dc
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ja_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl.lng b/interface/ispconfig/interface/designer/lib/lang/nl.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/nl_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..bdc7642379edf376f4ccb94b7e687ee0ad3e0f68
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/nl_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2da97250464f17f7f6a30d7942704569bd7b494c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/nl_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1c82ea156116f2d479e4476e467a3d2b02bb820e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/nl_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f4234dc28b098c405053f8eb65a2aa67e89534c0
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_module_edit.lng
@@ -0,0 +1,22 @@
+Description
+
+Modulename: Naam van de module directory. Alleen cijfers, letters en underscore zijn toegestaan.
+Moduletitle: Zal worden getoond in de hoofdnavigatie (bovenaan).
+Template file: Template bestand van de module. Momenteel beschikbaar: module.tpl.htm en module_tree.tpl.htm. Standaard is de module.tpl.htm.
+NaviFrame: Als de module_tree.tpl.htm geselecteerd is als template bestand, geef het pad op dat verwijst naar het scriptbestand voor het linker frame.
+Default page: Deze pagina wordt getoont wanneer de module is geopend.
+Tab width: Tabbreedte in de hoofdnavigatie. Het veld is standaard leeg. U kunt absolute waarden opgeven in pixels (bijv. 20) of relatieve (bijv. 20%).
+Hint: Alle paden zijn relatief aan de directorie web.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/nl_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..19ea5e94412eda34aca475d8a7b2a88ab34e7c83
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/nl_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..504b7f754b7cb0e436093c54c837174719c03f7b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/nl_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4c2bddd617c493b2e8f118ad6d132a17903b58d8
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/nl_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/nl_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8f605e40fd526a318dbddd4fd75f7d92b6524e02
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/nl_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl.lng b/interface/ispconfig/interface/designer/lib/lang/pl.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pl_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ee4f4c4100e9e738dc9b2f5c7f5594484ee56437
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/pl_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ac8572277cb0fbbd23843e783026585f5e1f2007
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/pl_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..db62af16b9cf666744f2013b0e99fb698e1f62d2
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pl_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..691e55052ff0394ab589f7f1ed28743d83deb1aa
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_module_edit.lng
@@ -0,0 +1,22 @@
+Opis
+
+Nazwa modułu: Nazwa katalogu z modułem. Tylko liczby, litery (bez polskich) i podkreślenie są dozwolone.
+Tytuł modułu: Będzie wyświetlaby w głównym menu nawigacyjnym.
+Plik szablonu: Plik szablonu modułu. Aktualnie dostępne: module.tpl.htm oraz module_tree.tpl.htm. Domyślnie jest module.tpl.htm.
+Ramka nawigacyjna: Jeśli module_tree.tpl.htm wybrano jako plik szablonu, wpisz tutaj ścieżkę do pliku ze skryptem dla lewej ramki.
+Strona domyślna: Ta strona będzie otwierana na początku podczas otwarcia modułu.
+Szerokość zakładki: Szerokość zakładek w głownym menu nawigacyjnym. To pole jest domyślnie puste. Możesz podać wartość w pikselach (np.: 20) lub procentach (np.: 20%).
+Podpowiedź: Wszystkie ścieżki są względne według strony www..
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/pl_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..308d1c688bc14a1cf611cb4c876126a5c2e4a43c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pl_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..5ace229a908caaabf6496cf3b0e31abf7e5a8a6d
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pl_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..779b3b4b3b418efa60072e2a7d9480b68a80606c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pl_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/pl_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9b98c4948239a2b8d5717ade5e90a2d8e2ca10ec
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pl_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt.lng b/interface/ispconfig/interface/designer/lib/lang/pt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..29f4a51efebb370aeb04c5144a604ca2c04e02be
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt.lng
@@ -0,0 +1,3 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pt_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..75869ca5c525bd217640d67c0fc70ef1a68e442f
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_form_edit.lng
@@ -0,0 +1,25 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/pt_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..01d0f28e9b96c9b1adfe751eb4fb4ebf04584083
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_form_list.lng
@@ -0,0 +1,8 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/pt_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..76e7487900d8503763704af40e087b5d9defbdce
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_form_show.lng
@@ -0,0 +1,19 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pt_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b04975d26a12d1c86e7ac73a9f66483d5e288ebf
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_module_edit.lng
@@ -0,0 +1,23 @@
+Descrição
+
+Nome do Módulo: Nome da pasta do módulo. Apenas números, letras e underscores são permitidos.
+Título do Módulo: Será exibido em caixa alta no menu de navegação.
+Ficheiro de Template: Ficheiros de Template do Módulo Disponível: modulo.tpl.htm e modulo_tree.tpl.htm. O padrão é modulo.tpl.htm.
+Frame de Navegação: Se modulo_tree.tpl.htm foi seleccionado como ficheiro de template, insira aqui a pasta do script para o frame a esquerda.
+Página Padrão: Esta página será exibida quando o módulo for aberto.
+Tamanho da Aba: Tamanho das abas na navegação principal. Este campo fica em branco por padrão. Pode fornecer valores absolutos em pixels (ex.: 20) ou valores relativos (ex.: 20%).
+Dica: Todos as pastas são relativas à pasta web.
+';
+?>
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/pt_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8b8f24775510746de6338d2a6587fa52eadde7a7
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_module_list.lng
@@ -0,0 +1,6 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pt_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3a98235985cd8b28306582e23ddc4889fd2b1118
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_module_nav_edit.lng
@@ -0,0 +1,7 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/pt_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4cb7df1afc9e803fb0708dc3c61c7c2f04e7d155
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_module_nav_item_edit.lng
@@ -0,0 +1,9 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/pt_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/pt_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..606181de601f0bf1950e00d96050d027654da8e0
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/pt_module_show.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro.lng b/interface/ispconfig/interface/designer/lib/lang/ro.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ro_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a99b975f03f43ad743b1e21c52e96884b22a30f3
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/ro_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..49b9d5eaf0994ed10e6f4a1011ed462d9e8e4278
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/ro_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9cc5e71d9239c5b13292f73b495d023f3aa85f7d
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ro_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..327550f2039adc3c2ad1c62aaa95c8d169a5f196
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_module_edit.lng
@@ -0,0 +1,12 @@
+Description
Modulename: Name of the module directory. Only numbers, chars and underscore allowed. Moduletitle: Will be shown in the (upper) main navigation. Template file: Template file of the module. Currently available: module.tpl.htm and module_tree.tpl.htm. Default is module.tpl.htm. NaviFrame: If module_tree.tpl.htm selected as template file, enter here the path to the script file for the left frame. Default page: These page will be shown when the module is opened. Tab width: Width of the Tabs in the main navigation. The field is empty by default. You can enter values absolute in pixel (e.g 20) or relative (e.g 20%). Hint: All paths are relative to the directory ';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/ro_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c53b556a4f0d9ad534fe6b1d5444a99ba3d72d1c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ro_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ee6bf54268bca384e45cf593711745ec060a8504
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ro_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9b7d60df91b0c00ab79eb21a17c48a9230c7fb62
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ro_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/ro_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2fb748c3d463c5bdf3a0d834f2634c32e1ec6004
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ro_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru.lng b/interface/ispconfig/interface/designer/lib/lang/ru.lng
new file mode 100644
index 0000000000000000000000000000000000000000..29f4a51efebb370aeb04c5144a604ca2c04e02be
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru.lng
@@ -0,0 +1,3 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ru_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f1f67688b1f452169d65b80e8e31d71d8774a6fe
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_form_edit.lng
@@ -0,0 +1,25 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/ru_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d29fdbe86501d77253c826797e8a5e32c47f695f
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_form_list.lng
@@ -0,0 +1,8 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/ru_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..204f86635c9ac2d313f723f0f163f5e27c562f92
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_form_show.lng
@@ -0,0 +1,19 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ru_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0b6078410ce63edcf9551a6c0b4e2f25cdb6f569
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_module_edit.lng
@@ -0,0 +1,23 @@
+Описание
+
+Имя модуля: Имя директории модуля. Допустимо использовать латинские символы, числа и подчеркивание.
+Заголовок модуля: Будет отображаться вверху радом с навигацией.
+Файл шаблона: Файл шаблона для модуля. Сейчас доступны: module.tpl.htm и module_tree.tpl.htm. По-умолчанию стоит module.tpl.htm.
+Навигационный фрейм: Если module_tree.tpl.htm выбран как шаблон, введите здесь путь до скрипта для левого фрейма.
+Страница по-умолчанию: Эта страница будет показана, когда открывается модуль.
+Ширина таба: Ширина таба в главной навигации. По-умолчанию поле пустое. Вы можете ввести значение в пикселях или в процентах.
+Подсказка: Все пути в директории web относительные.
+';
+?>
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/ru_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e305b40149302e013b433cf9c8facb9e38df12d2
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_module_list.lng
@@ -0,0 +1,6 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ru_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ad02af8e7f579f97a7f8022c27eaef3f0298ef2b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_module_nav_edit.lng
@@ -0,0 +1,7 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/ru_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f42aafdb821ca16872961d387d1b90f5d426d43e
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_module_nav_item_edit.lng
@@ -0,0 +1,9 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/ru_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/ru_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ddb1a5f84508bcadf787c5817d575f6e85f5d0b7
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/ru_module_show.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se.lng b/interface/ispconfig/interface/designer/lib/lang/se.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/se_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d047ad393d50387a80f3e399229f5b83785d8b20
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/se_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e9268e4af986c39f288c6fd3fbc4df7733f4e25
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/se_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ebd3dd9cf6bd2121289ef35e2a1bfc572da68a1b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/se_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ee8361d13bc77cc585108a81f0d39a1c817903ed
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_module_edit.lng
@@ -0,0 +1,22 @@
+Description
+
+Modulename: Namn p modul mappen. Endast siffror, bokstver och understreck r tilltna.
+Moduletitle: Kommer att visas i (vre) huvud navigerigsramen.
+Template file: Mall fil fr modulen. Just nu finns: module.tpl.htm och module_tree.tpl.htm. Standard r module.tpl.htm.
+NaviFrame: Om module module_tree.tpl.htm vljs som mall file, skriv hr skvgen till skriptfilen fr den vnstra ramen.
+Default page: Dessa sidor kommer att visas nr modulen ppnas.
+Tab width: Bredd p Flikarna i huvud navigerings ramen. Detta flt r tomt som standard. Du kan skriva in ett absolutvrde i pixlar (ex. 20) eller relativt vrde (ex. 20%).
+Hint: Alla skvgar r relativa till mappen web.
+';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/se_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0fe0187b76286b1a994374265a504f76b24388b8
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/se_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..17e1563ef931f553188f8d9c09c4e9170911488d
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/se_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3bbbfbd1a82357404a709969632a61d828f5241c
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/se_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/se_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c58df7ac449c44ed5fd795ecf2c43570c7b2c325
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/se_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk.lng b/interface/ispconfig/interface/designer/lib/lang/sk.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/sk_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3c72e8819b50c5cfec1331284884ed43bde20807
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/sk_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0e0c2cb278b9e0d531b8ce4d4cbac63810b17a24
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/sk_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..042e106001a4088d51dd29e51b56912e51520102
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/sk_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..320bd142911be25dc031757d4aa0b5715140b909
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_module_edit.lng
@@ -0,0 +1,12 @@
+ Popis b>
Modulename: b> Nzov modulu adresr. Len ?sla, znaky a podtrtko povolen. Moduletitle: b> sa objav v (hornej) navigciu. ablna sboru: b> ablna sboru modulu. V s?asnej dobe s k dispozcii';
+?>
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_module_list.lng b/interface/ispconfig/interface/designer/lib/lang/sk_module_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4d9cd1e2ccfeb983a274d4cd4b55290fb89f4222
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_module_list.lng
@@ -0,0 +1,5 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_module_nav_edit.lng b/interface/ispconfig/interface/designer/lib/lang/sk_module_nav_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..69d4d161c18e09ef48ed0c85ff7a6fa8220ab1d9
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_module_nav_edit.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_module_nav_item_edit.lng b/interface/ispconfig/interface/designer/lib/lang/sk_module_nav_item_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..23f7d1592ab86b82a3d29ee7e895fca1f46b26b6
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_module_nav_item_edit.lng
@@ -0,0 +1,8 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/sk_module_show.lng b/interface/ispconfig/interface/designer/lib/lang/sk_module_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3d62509ea8355f5307ab8d3a0817ce2c196bb6e7
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/sk_module_show.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/tr.lng b/interface/ispconfig/interface/designer/lib/lang/tr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acb6c3546c6150b4edbafb782d3ed85c499210b5
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/tr.lng
@@ -0,0 +1,2 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/tr_form_edit.lng b/interface/ispconfig/interface/designer/lib/lang/tr_form_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8288ce84b895b6469fd87a121788a79ed0eab58b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/tr_form_edit.lng
@@ -0,0 +1,24 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/tr_form_list.lng b/interface/ispconfig/interface/designer/lib/lang/tr_form_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..54aa1f45340982eec7bd51825236c02d72c19ffb
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/tr_form_list.lng
@@ -0,0 +1,7 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/tr_form_show.lng b/interface/ispconfig/interface/designer/lib/lang/tr_form_show.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8efa1df5a5c60689daea01090b60683e92218217
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/tr_form_show.lng
@@ -0,0 +1,18 @@
+
diff --git a/interface/ispconfig/interface/designer/lib/lang/tr_module_edit.lng b/interface/ispconfig/interface/designer/lib/lang/tr_module_edit.lng
new file mode 100644
index 0000000000000000000000000000000000000000..92bf93d2cac9f3cd7001e20f0a2e314a27c314b3
--- /dev/null
+++ b/interface/ispconfig/interface/designer/lib/lang/tr_module_edit.lng
@@ -0,0 +1,22 @@
+Açıklama
+
";
+ $n1++;
+}
+}
+
+$record["nav"] = $content;
+
+
+$app->tpl->setVar($record);
+
+
+$app->tpl->setLoop('records',$modules_list);
+
+$app->tpl_defaults();
+$app->tpl->pparse();
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/form_edit.htm b/interface/ispconfig/interface/designer/templates/form_edit.htm
new file mode 100644
index 0000000000000000000000000000000000000000..4d1c991ab19f7a33b3a25d941f1af414a4c1017f
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/form_edit.htm
@@ -0,0 +1,79 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/form_list.htm b/interface/ispconfig/interface/designer/templates/form_list.htm
new file mode 100644
index 0000000000000000000000000000000000000000..57506e8d4613cc3e8f0d37f657f84d0040a0dedb
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/form_list.htm
@@ -0,0 +1,24 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/form_show.htm b/interface/ispconfig/interface/designer/templates/form_show.htm
new file mode 100644
index 0000000000000000000000000000000000000000..b10407018c0f4d5d7d513116105a969871b5d42a
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/form_show.htm
@@ -0,0 +1,61 @@
+
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/module_edit.htm b/interface/ispconfig/interface/designer/templates/module_edit.htm
new file mode 100644
index 0000000000000000000000000000000000000000..2464f5f7e32aa198963b024cfa2985b2e00d7d18
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/module_edit.htm
@@ -0,0 +1,43 @@
+
+
+
+
:
+
+
+
+
:
+
+
+
+
:
+
+
+
+
:
+
+
+
+
:
+
+
+
+
:
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/module_list.htm b/interface/ispconfig/interface/designer/templates/module_list.htm
new file mode 100644
index 0000000000000000000000000000000000000000..1198d1c8c5693f83674443673fc31eae47ba8f63
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/module_list.htm
@@ -0,0 +1,18 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/module_nav_edit.htm b/interface/ispconfig/interface/designer/templates/module_nav_edit.htm
new file mode 100644
index 0000000000000000000000000000000000000000..5c46350b317517d6ad13566c114c0ea47673e7b3
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/module_nav_edit.htm
@@ -0,0 +1,24 @@
+
+
+
+
:
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/module_nav_item_edit.htm b/interface/ispconfig/interface/designer/templates/module_nav_item_edit.htm
new file mode 100644
index 0000000000000000000000000000000000000000..7ddcd19c0fbe6710c2bc044b0e528263c5e47b3b
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/module_nav_item_edit.htm
@@ -0,0 +1,33 @@
+
+
+
+
:
+
+
+
+
:
+
+
+
+
:
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/module_show.htm b/interface/ispconfig/interface/designer/templates/module_show.htm
new file mode 100644
index 0000000000000000000000000000000000000000..8b261720feed3666c32b1d474007fc8973c89119
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/module_show.htm
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/designer/templates/paging.tpl.htm b/interface/ispconfig/interface/designer/templates/paging.tpl.htm
new file mode 100644
index 0000000000000000000000000000000000000000..cb8270404709c841e85e8ddbdf5dd725a98b4e08
--- /dev/null
+++ b/interface/ispconfig/interface/designer/templates/paging.tpl.htm
@@ -0,0 +1,9 @@
+[ |<< ]
+
+ [<< Zurck]
+
+ Seite {tmpl_var name="next_page"} von {tmpl_var name="max_pages"}
+
+ [Weiter >>]
+
+ [ >>| ]
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_a_edit.php b/interface/ispconfig/interface/dns/dns_a_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..3bd8dec2043ecb58bbb96a31e20d57f7c4b4eeee
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_a_edit.php
@@ -0,0 +1,144 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+ //* Check for duplicates where IP and hostname are the same
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE type = 'A' AND name = '".$this->dataRecord["name"]."' AND zone = '".$this->dataRecord["zone"]."' and data = '".$this->dataRecord["data"]."' and id != ".$this->id);
+ if($tmp['number'] > 0) $app->tform->errorMessage .= $app->tform->lng("data_error_duplicate")." ";
+ unset($tmp);
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_a_list.php b/interface/ispconfig/interface/dns/dns_a_list.php
new file mode 100644
index 0000000000000000000000000000000000000000..681e1583955d5673b856489075c5d2ddb5db7e88
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_a_list.php
@@ -0,0 +1,24 @@
+auth->check_module_permissions('dns');
+
+$app->uses('listform_actions');
+$app->listform_actions->SQLExtWhere = "type = 'A'";
+
+$app->listform_actions->onLoad();
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_aaaa_edit.php b/interface/ispconfig/interface/dns/dns_aaaa_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..97a3565ebbc7ea6f00b81a0b4374cdee9d746ec5
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_aaaa_edit.php
@@ -0,0 +1,139 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_alias_edit.php b/interface/ispconfig/interface/dns/dns_alias_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..676d439a6664ea88de2bae27b45bae953de3cdeb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_alias_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_cname_edit.php b/interface/ispconfig/interface/dns/dns_cname_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..96e645348309e026b3ef30147f58d85259e4b855
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_cname_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_hinfo_edit.php b/interface/ispconfig/interface/dns/dns_hinfo_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..cafbedef918e2c3a3bd4ccb60945a783b101fa39
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_hinfo_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_mx_edit.php b/interface/ispconfig/interface/dns/dns_mx_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..889d795e1b2225b17c8d5a72b865d77bb425b84c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_mx_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_ns_edit.php b/interface/ispconfig/interface/dns/dns_ns_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..5fa65c9d00066cef40cae83363af7f7ca85bcbfc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_ns_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_ptr_edit.php b/interface/ispconfig/interface/dns/dns_ptr_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..04f1b2ef4163e5f537ac8f9422c01ba82143f4dc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_ptr_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_rp_edit.php b/interface/ispconfig/interface/dns/dns_rp_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..10c61122f45de4f08eff8aee5ec1a8cf08a9a493
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_rp_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_rr_del.php b/interface/ispconfig/interface/dns/dns_rr_del.php
new file mode 100644
index 0000000000000000000000000000000000000000..7a0b92d14514d7b9ef1e158cf027da0b5e51eb48
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_rr_del.php
@@ -0,0 +1,51 @@
+auth->check_module_permissions('dns');
+
+$app->uses("tform_actions");
+$app->tform_actions->onDelete();
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_soa_del.php b/interface/ispconfig/interface/dns/dns_soa_del.php
new file mode 100644
index 0000000000000000000000000000000000000000..38e35bd67c2e2b91b07ac1d9dad9381947a5c63f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_soa_del.php
@@ -0,0 +1,69 @@
+auth->check_module_permissions('dns');
+
+$app->uses('tpl,tform,tform_actions');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onBeforeDelete() {
+ global $app; $conf;
+
+ if($app->tform->checkPerm($this->id,'d') == false) $app->error($app->lng('error_no_delete_permission'));
+
+ // Delete all records that belog to this zone.
+ $records = $app->db->queryAllRecords("SELECT id FROM dns_rr WHERE zone = '".intval($this->id)."'");
+ foreach($records as $rec) {
+ $app->db->datalogDelete('dns_rr','id',$rec['id']);
+ }
+ }
+}
+
+$page = new page_action;
+$page->onDelete();
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_soa_edit.php b/interface/ispconfig/interface/dns/dns_soa_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..6bfad69124663f3b22b4c6edb4ce4587002adaf3
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_soa_edit.php
@@ -0,0 +1,222 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+ if(!$app->tform->checkClientLimit('limit_dns_zone')) {
+ $app->error($app->tform->wordbook["limit_dns_zone_txt"]);
+ }
+ if(!$app->tform->checkResellerLimit('limit_dns_zone')) {
+ $app->error('Reseller: '.$app->tform->wordbook["limit_dns_zone_txt"]);
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onShowEnd() {
+ global $app, $conf;
+
+ // If user is admin, we will allow him to select to whom this record belongs
+ if($_SESSION["s"]["user"]["typ"] == 'admin') {
+ // Getting Domains of the user
+ $sql = "SELECT groupid, name FROM sys_group WHERE client_id > 0 ORDER by name";
+ $clients = $app->db->queryAllRecords($sql);
+ $client_select = '';
+ if($_SESSION["s"]["user"]["typ"] == 'admin') $client_select .= "";
+ $tmp_data_record = $app->tform->getDataRecord($this->id);
+ if(is_array($clients)) {
+ foreach( $clients as $client) {
+ $selected = ($client["groupid"] == @$tmp_data_record["sys_groupid"])?'SELECTED':'';
+ $client_select .= "\r\n";
+ }
+ }
+ $app->tpl->setVar("client_group_id",$client_select);
+ } else if($app->auth->has_clients($_SESSION['s']['user']['userid'])) {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT client.client_id, client.contact_name FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Fill the client select field
+ $sql = "SELECT groupid, name FROM sys_group, client WHERE sys_group.client_id = client.client_id AND client.parent_client_id = ".$client['client_id']." ORDER BY name";
+ $clients = $app->db->queryAllRecords($sql);
+ $tmp = $app->db->queryOneRecord("SELECT groupid FROM sys_group WHERE client_id = ".$client['client_id']);
+ $client_select = '';
+ $tmp_data_record = $app->tform->getDataRecord($this->id);
+ if(is_array($clients)) {
+ foreach( $clients as $client) {
+ $selected = @($client["groupid"] == $tmp_data_record["sys_groupid"])?'SELECTED':'';
+ $client_select .= "\r\n";
+ }
+ }
+ $app->tpl->setVar("client_group_id",$client_select);
+
+ }
+
+ parent::onShowEnd();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ if($_SESSION["s"]["user"]["typ"] != 'admin') {
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_zone, default_dnsserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // When the record is updated
+ if($this->id > 0) {
+ // restore the server ID if the user is not admin and record is edited
+ $tmp = $app->db->queryOneRecord("SELECT server_id FROM dns_soa WHERE id = ".intval($this->id));
+ $this->dataRecord["server_id"] = $tmp["server_id"];
+ unset($tmp);
+ // When the record is inserted
+ } else {
+ // set the server ID to the default dnsserver of the client
+ $this->dataRecord["server_id"] = $client["default_dnsserver"];
+
+ // Check if the user may add another maildomain.
+ if($client["limit_dns_zone"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_soa WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_zone"]) {
+ $app->error($app->tform->wordbook["limit_dns_zone_txt"]);
+ }
+ }
+ }
+ }
+
+ /*
+ // Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ */
+
+
+ //* Check if soa, ns and mbox have a dot at the end
+ if(strlen($this->dataRecord["origin"]) > 0 && substr($this->dataRecord["origin"],-1,1) != '.') $this->dataRecord["origin"] .= '.';
+ if(strlen($this->dataRecord["ns"]) > 0 && substr($this->dataRecord["ns"],-1,1) != '.') $this->dataRecord["ns"] .= '.';
+ if(strlen($this->dataRecord["mbox"]) > 0 && substr($this->dataRecord["mbox"],-1,1) != '.') $this->dataRecord["mbox"] .= '.';
+
+ //* Replace @ in mbox
+ if(stristr($this->dataRecord["mbox"],'@')) {
+ $this->dataRecord["mbox"] = str_replace('@','.',$this->dataRecord["mbox"]);
+ }
+
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ // make sure that the record belongs to the client group and not the admin group when a dmin inserts it
+ if($_SESSION["s"]["user"]["typ"] == 'admin' && isset($this->dataRecord["client_group_id"])) {
+ $client_group_id = intval($this->dataRecord["client_group_id"]);
+ $app->db->query("UPDATE dns_soa SET sys_groupid = $client_group_id WHERE id = ".$this->id);
+ // And we want to update all rr records too, that belong to this record
+ $app->db->query("UPDATE dns_rr SET sys_groupid = $client_group_id WHERE zone = ".$this->id);
+ }
+ if($app->auth->has_clients($_SESSION['s']['user']['userid']) && isset($this->dataRecord["client_group_id"])) {
+ $client_group_id = intval($this->dataRecord["client_group_id"]);
+ $app->db->query("UPDATE dns_soa SET sys_groupid = $client_group_id WHERE id = ".$this->id);
+ // And we want to update all rr records too, that belong to this record
+ $app->db->query("UPDATE dns_rr SET sys_groupid = $client_group_id WHERE zone = ".$this->id);
+ }
+
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ $tmp = $app->db->diffrec($this->oldDataRecord,$app->tform->getDataRecord($this->id));
+ if($tmp['diff_num'] > 0) {
+ // Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = ".$this->id);
+ $app->db->query("UPDATE dns_soa SET serial = '".$app->validate_dns->increase_serial($soa["serial"])."' WHERE id = ".$this->id);
+ }
+
+ // make sure that the record belongs to the client group and not the admin group when a dmin inserts it
+ if($_SESSION["s"]["user"]["typ"] == 'admin' && isset($this->dataRecord["client_group_id"])) {
+ $client_group_id = intval($this->dataRecord["client_group_id"]);
+ $app->db->query("UPDATE dns_soa SET sys_groupid = $client_group_id WHERE id = ".$this->id);
+ // And we want to update all rr records too, that belong to this record
+ $app->db->query("UPDATE dns_rr SET sys_groupid = $client_group_id WHERE zone = ".$this->id);
+ }
+ if($app->auth->has_clients($_SESSION['s']['user']['userid']) && isset($this->dataRecord["client_group_id"])) {
+ $client_group_id = intval($this->dataRecord["client_group_id"]);
+ $app->db->query("UPDATE dns_soa SET sys_groupid = $client_group_id WHERE id = ".$this->id);
+ // And we want to update all rr records too, that belong to this record
+ $app->db->query("UPDATE dns_rr SET sys_groupid = $client_group_id WHERE zone = ".$this->id);
+ }
+
+ //** When the client group has changed, change also the owner of the record if the owner is not the admin user
+ if($this->oldDataRecord["client_group_id"] != $this->dataRecord["client_group_id"] && $this->dataRecord["sys_userid"] != 1) {
+ $client_group_id = intval($this->dataRecord["client_group_id"]);
+ $tmp = $app->db->queryOneREcord("SELECT userid FROM sys_user WHERE default_group = ".$client_group_id);
+ if($tmp["userid"] > 0) {
+ $app->db->query("UPDATE dns_soa SET sys_userid = ".$tmp["userid"]." WHERE id = ".$this->id);
+ $app->db->query("UPDATE dns_rr SET sys_userid = ".$tmp["userid"]." WHERE zone = ".$this->id);
+ }
+ }
+
+ }
+
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_soa_list.php b/interface/ispconfig/interface/dns/dns_soa_list.php
new file mode 100644
index 0000000000000000000000000000000000000000..7b2981a5b23f021a6a50f297078867e71ff02593
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_soa_list.php
@@ -0,0 +1,25 @@
+auth->check_module_permissions('dns');
+
+$app->uses('listform_actions');
+// $app->listform_actions->SQLExtWhere = "access = 'REJECT'";
+
+$app->listform_actions->SQLOrderBy = 'ORDER BY origin';
+$app->listform_actions->onLoad();
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_srv_edit.php b/interface/ispconfig/interface/dns/dns_srv_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..15af1e207b73d000d7eec62bfc57cbaa0891b7d5
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_srv_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_template_del.php b/interface/ispconfig/interface/dns/dns_template_del.php
new file mode 100644
index 0000000000000000000000000000000000000000..5aa1ff748f9ad52f48e5017da17c1accd309920e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_template_del.php
@@ -0,0 +1,58 @@
+auth->check_module_permissions('dns');
+
+$app->uses('tpl,tform,tform_actions');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+}
+
+$page = new page_action;
+$page->onDelete();
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_template_edit.php b/interface/ispconfig/interface/dns/dns_template_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..7d84d5ca8ea6736139e1b0ebf06eda97aed9bca6
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_template_edit.php
@@ -0,0 +1,60 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions');
+$app->load('tform_actions');
+
+if($_SESSION["s"]["user"]["typ"] != 'admin') die('Access denied for non admin users.');
+
+class page_action extends tform_actions {
+
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_template_list.php b/interface/ispconfig/interface/dns/dns_template_list.php
new file mode 100644
index 0000000000000000000000000000000000000000..4cde9a01330b2008f37c1b897f5ca05567ed02f2
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_template_list.php
@@ -0,0 +1,24 @@
+auth->check_module_permissions('dns');
+
+$app->uses('listform_actions');
+// $app->listform_actions->SQLExtWhere = "access = 'REJECT'";
+
+$app->listform_actions->onLoad();
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/dns_txt_edit.php b/interface/ispconfig/interface/dns/dns_txt_edit.php
new file mode 100644
index 0000000000000000000000000000000000000000..2d5cecdc98784173ee31a9ac5d0eabd267bc99eb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_txt_edit.php
@@ -0,0 +1,138 @@
+auth->check_module_permissions('dns');
+
+// Loading classes
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+ function onShowNew() {
+ global $app, $conf;
+
+ // we will check only users, not admins
+ if($_SESSION["s"]["user"]["typ"] == 'user') {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ }
+
+ parent::onShowNew();
+ }
+
+ function onSubmit() {
+ global $app, $conf;
+
+ // Get the parent soa record of the domain
+ $soa = $app->db->queryOneRecord("SELECT * FROM dns_soa WHERE id = '".intval($_POST["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+
+ // Check if Domain belongs to user
+ if($soa["id"] != $_POST["zone"]) $app->tform->errorMessage .= $app->tform->wordbook["no_zone_perm"];
+
+ // Check the client limits, if user is not the admin
+ if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT limit_dns_record FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+ // Check if the user may add another mailbox.
+ if($this->id == 0 && $client["limit_dns_record"] >= 0) {
+ $tmp = $app->db->queryOneRecord("SELECT count(id) as number FROM dns_rr WHERE sys_groupid = $client_group_id");
+ if($tmp["number"] >= $client["limit_dns_record"]) {
+ $app->error($app->tform->wordbook["limit_dns_record_txt"]);
+ }
+ }
+ } // end if user is not admin
+
+
+ // Set the server ID of the rr record to the same server ID as the parent record.
+ $this->dataRecord["server_id"] = $soa["server_id"];
+
+ // Update the serial number and timestamp of the RR record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_rr WHERE id = ".$this->id);
+ $this->dataRecord["serial"] = $app->validate_dns->increase_serial($soa["serial"]);
+ $this->dataRecord["stamp"] = date('Y-m-d H:i:s');
+
+ parent::onSubmit();
+ }
+
+ function onAfterInsert() {
+ global $app, $conf;
+
+ //* Set the sys_groupid of the rr record to be the same then the sys_groupid of the soa record
+ $soa = $app->db->queryOneRecord("SELECT sys_groupid,serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $app->db->datalogUpdate('dns_rr', "sys_groupid = ".$soa['sys_groupid'], 'id', $this->id);
+
+ //* Update the serial number of the SOA record
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+
+ function onAfterUpdate() {
+ global $app, $conf;
+
+ //* Update the serial number of the SOA record
+ $soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+ $soa_id = intval($_POST["zone"]);
+ $serial = $app->validate_dns->increase_serial($soa["serial"]);
+ $app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+ }
+}
+
+$page = new page_action;
+$page->onLoad();
+
+?>
diff --git a/interface/ispconfig/interface/dns/dns_wizard.php b/interface/ispconfig/interface/dns/dns_wizard.php
new file mode 100644
index 0000000000000000000000000000000000000000..2c985eb94132f7d604ccd12ac94fe29f710fe42b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/dns_wizard.php
@@ -0,0 +1,274 @@
+auth->check_module_permissions('dns');
+
+
+// Loading the template
+$app->uses('tpl,validate_dns');
+$app->tpl->newTemplate("form.tpl.htm");
+$app->tpl->setInclude('content_tpl','templates/dns_wizard.htm');
+$app->load_language_file('/web/dns/lib/lang/'.$_SESSION['s']['language'].'_dns_wizard.lng');
+
+// import variables
+$template_id = (isset($_POST['template_id']))?intval($_POST['template_id']):0;
+$sys_groupid = (isset($_POST['client_group_id']))?intval($_POST['client_group_id']):0;
+
+// get the correct server_id
+if($_SESSION['s']['user']['typ'] == 'admin') {
+ $server_id = (isset($_POST['server_id']))?intval($_POST['server_id']):1;
+} else {
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT default_dnsserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+ $server_id = $client["default_dnsserver"];
+}
+
+
+// Load the templates
+$records = $app->db->queryAllRecords("SELECT * FROM dns_template WHERE visible = 'Y'");
+$template_id_option = '';
+$n = 0;
+foreach($records as $rec){
+ $checked = ($rec['template_id'] == $template_id)?' SELECTED':'';
+ $template_id_option .= '';
+ if($n == 0 && $template_id == 0) $template_id = $rec['template_id'];
+ $n++;
+}
+unset($n);
+$app->tpl->setVar("template_id_option",$template_id_option);
+
+// If the user is administrator
+if($_SESSION['s']['user']['typ'] == 'admin') {
+
+ // Load the list of servers
+ $records = $app->db->queryAllRecords("SELECT server_id, server_name FROM server WHERE dns_server = 1 ORDER BY server_name");
+ $server_id_option = '';
+ foreach($records as $rec){
+ $checked = ($rec['server_id'] == $server_id)?' SELECTED':'';
+ $server_id_option .= '';
+ }
+ $app->tpl->setVar("server_id",$server_id_option);
+
+ // load the list of clients
+ $sql = "SELECT groupid, name FROM sys_group WHERE client_id > 0 ORDER BY name";
+ $clients = $app->db->queryAllRecords($sql);
+ $client_select = '';
+ if($_SESSION["s"]["user"]["typ"] == 'admin') $client_select .= "";
+ if(is_array($clients)) {
+ foreach( $clients as $client) {
+ $selected = ($client["groupid"] == $sys_groupid)?'SELECTED':'';
+ $client_select .= "\r\n";
+ }
+ }
+
+ $app->tpl->setVar("client_group_id",$client_select);
+}
+
+if ($_SESSION["s"]["user"]["typ"] != 'admin' && $app->auth->has_clients($_SESSION['s']['user']['userid'])) {
+
+ // Get the limits of the client
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $client = $app->db->queryOneRecord("SELECT client.client_id, contact_name FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
+
+
+ // load the list of clients
+ $sql = "SELECT groupid, name FROM sys_group, client WHERE sys_group.client_id = client.client_id AND client.parent_client_id = ".$client['client_id'];
+ $clients = $app->db->queryAllRecords($sql);
+ $tmp = $app->db->queryOneRecord("SELECT groupid FROM sys_group WHERE client_id = ".$client['client_id']);
+ $client_select = '';
+ if(is_array($clients)) {
+ foreach( $clients as $client) {
+ $selected = ($client["groupid"] == $sys_groupid)?'SELECTED':'';
+ $client_select .= "\r\n";
+ }
+ }
+
+ $app->tpl->setVar("client_group_id",$client_select);
+}
+
+
+$template_record = $app->db->queryOneRecord("SELECT * FROM dns_template WHERE template_id = '$template_id'");
+$fields = explode(',',$template_record['fields']);
+if(is_array($fields)) {
+ foreach($fields as $field) {
+ $app->tpl->setVar($field."_VISIBLE",1);
+ $field = strtolower($field);
+ $app->tpl->setVar($field,$_POST[$field]);
+ }
+}
+
+if($_POST['create'] == 1) {
+
+ $error = '';
+
+ if(isset($_POST['domain']) && $_POST['domain'] == '') $error .= $app->lng('error_domain_empty').' ';
+ if(isset($_POST['ip']) && $_POST['ip'] == '') $error .= $app->lng('error_ip_empty').' ';
+ if(isset($_POST['ns1']) && $_POST['ns1'] == '') $error .= $app->lng('error_ns1_empty').' ';
+ if(isset($_POST['ns2']) && $_POST['ns2'] == '') $error .= $app->lng('error_ns2_empty').' ';
+ if(isset($_POST['email']) && $_POST['email'] == '') $error .= $app->lng('error_email_empty').' ';
+
+ if(isset($_POST['domain']) && !preg_match('/^[\w\.\-]{2,64}\.[a-zA-Z]{2,10}[\.]{0,1}$/',$_POST['domain'])) $error .= $app->lng('error_domain_regex').' ';
+ if(isset($_POST['ns1']) && !preg_match('/^[\w\.\-]{2,64}\.[a-zA-Z]{2,10}[\.]{0,1}$/',$_POST['ns1'])) $error .= $app->lng('error_ns1_regex').' ';
+ if(isset($_POST['ns2']) && !preg_match('/^[\w\.\-]{2,64}\.[a-zA-Z]{2,10}[\.]{0,1}$/',$_POST['ns2'])) $error .= $app->lng('error_ns2_regex').' ';
+ if(isset($_POST['email']) && !preg_match('/^\w+[\w.-]*\w+@\w+[\w.-]*\w+\.[a-z]{2,10}$/i',$_POST['email'])) $error .= $app->lng('error_email_regex').' ';
+
+ // make sure that the record belongs to the clinet group and not the admin group when a dmin inserts it
+ if($_SESSION["s"]["user"]["typ"] == 'admin' && isset($_POST['client_group_id'])) {
+ $sys_groupid = intval($_POST['client_group_id']);
+ } elseif($app->auth->has_clients($_SESSION['s']['user']['userid']) && isset($_POST['client_group_id'])) {
+ $sys_groupid = intval($_POST['client_group_id']);
+ } else {
+ $sys_groupid = $_SESSION["s"]["user"]["default_group"];
+ }
+
+ $tform_def_file = "form/dns_soa.tform.php";
+ $app->uses('tform');
+ $app->tform->loadFormDef($tform_def_file);
+
+ if($_SESSION['s']['user']['typ'] != 'admin') {
+ if(!$app->tform->checkClientLimit('limit_dns_zone')) {
+ $error .= $app->tform->wordbook["limit_dns_zone_txt"];
+ }
+ if(!$app->tform->checkResellerLimit('limit_dns_zone')) {
+ $error .= $app->tform->wordbook["limit_dns_zone_txt"];
+ }
+ }
+
+
+ // replace template placeholders
+ $tpl_content = $template_record['template'];
+ if($_POST['domain'] != '') $tpl_content = str_replace('{DOMAIN}',$_POST['domain'],$tpl_content);
+ if($_POST['ip'] != '') $tpl_content = str_replace('{IP}',$_POST['ip'],$tpl_content);
+ if($_POST['ns1'] != '') $tpl_content = str_replace('{NS1}',$_POST['ns1'],$tpl_content);
+ if($_POST['ns2'] != '') $tpl_content = str_replace('{NS2}',$_POST['ns2'],$tpl_content);
+ if($_POST['email'] != '') $tpl_content = str_replace('{EMAIL}',$_POST['email'],$tpl_content);
+
+ // Parse the template
+ $tpl_rows = explode("\n",$tpl_content);
+ $section = '';
+ $vars = array();
+ $dns_rr = array();
+ foreach($tpl_rows as $row) {
+ $row = trim($row);
+ if(substr($row,0,1) == '[') {
+ if($row == '[ZONE]') {
+ $section = 'zone';
+ } elseif($row == '[DNS_RECORDS]') {
+ $section = 'dns_records';
+ } else {
+ die('Unknown section type');
+ }
+ } else {
+ if($row != '') {
+ // Handle zone section
+ if($section == 'zone') {
+ $parts = explode('=',$row);
+ $key = trim($parts[0]);
+ $val = trim($parts[1]);
+ if($key != '') $vars[$key] = $val;
+ }
+ // Handle DNS Record rows
+ if($section == 'dns_records') {
+ $parts = explode('|',$row);
+ $dns_rr[] = array(
+ 'name' => $app->db->quote($parts[1]),
+ 'type' => $app->db->quote($parts[0]),
+ 'data' => $app->db->quote($parts[2]),
+ 'aux' => $app->db->quote($parts[3]),
+ 'ttl' => $app->db->quote($parts[4])
+ );
+ }
+ }
+ }
+
+ } // end foreach
+
+ if($vars['origin'] == '') $error .= $app->lng('error_origin_empty').' ';
+ if($vars['ns'] == '') $error .= $app->lng('error_ns_empty').' ';
+ if($vars['mbox'] == '') $error .= $app->lng('error_mbox_empty').' ';
+ if($vars['refresh'] == '') $error .= $app->lng('error_refresh_empty').' ';
+ if($vars['retry'] == '') $error .= $app->lng('error_retry_empty').' ';
+ if($vars['expire'] == '') $error .= $app->lng('error_expire_empty').' ';
+ if($vars['minimum'] == '') $error .= $app->lng('error_minimum_empty').' ';
+ if($vars['ttl'] == '') $error .= $app->lng('error_ttl_empty').' ';
+
+ if($error == '') {
+ // Insert the soa record
+ $sys_userid = $_SESSION['s']['user']['userid'];
+ $origin = $app->db->quote($vars['origin']);
+ $ns = $app->db->quote($vars['ns']);
+ $mbox = $app->db->quote(str_replace('@','.',$vars['mbox']));
+ $refresh = $app->db->quote($vars['refresh']);
+ $retry = $app->db->quote($vars['retry']);
+ $expire = $app->db->quote($vars['expire']);
+ $minimum = $app->db->quote($vars['minimum']);
+ $ttl = $app->db->quote($vars['ttl']);
+ $xfer = $app->db->quote($vars['xfer']);
+ $serial = $app->validate_dns->increase_serial(0);
+
+ $insert_data = "(`sys_userid`, `sys_groupid`, `sys_perm_user`, `sys_perm_group`, `sys_perm_other`, `server_id`, `origin`, `ns`, `mbox`, `serial`, `refresh`, `retry`, `expire`, `minimum`, `ttl`, `active`, `xfer`) VALUES
+ ('$sys_userid', '$sys_groupid', 'riud', 'riud', '', '$server_id', '$origin', '$ns', '$mbox', '$serial', '$refresh', '$retry', '$expire', '$minimum', '$ttl', 'Y', '$xfer')";
+ $dns_soa_id = $app->db->datalogInsert('dns_soa', $insert_data, 'id');
+
+ // Insert the dns_rr records
+ if(is_array($dns_rr) && $dns_soa_id > 0) {
+ foreach($dns_rr as $rr) {
+ $insert_data = "(`sys_userid`, `sys_groupid`, `sys_perm_user`, `sys_perm_group`, `sys_perm_other`, `server_id`, `zone`, `name`, `type`, `data`, `aux`, `ttl`, `active`) VALUES
+ ('$sys_userid', '$sys_groupid', 'riud', 'riud', '', '$server_id', '$dns_soa_id', '$rr[name]', '$rr[type]', '$rr[data]', '$rr[aux]', '$rr[ttl]', 'Y')";
+ $dns_rr_id = $app->db->datalogInsert('dns_rr', $insert_data, 'id');
+ }
+ }
+
+ header("Location: dns_soa_list.php");
+ exit;
+
+ } else {
+ $app->tpl->setVar("error",$error);
+ }
+
+}
+
+
+
+$app->tpl->setVar("title",'DNS Wizard');
+
+$lng_file = 'lib/lang/'.$_SESSION['s']['language'].'_dns_wizard.lng';
+include($lng_file);
+$app->tpl->setVar($wb);
+
+$app->tpl_defaults();
+$app->tpl->pparse();
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_a.tform.php b/interface/ispconfig/interface/dns/form/dns_a.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..5cb7475709e94177588d0cad5afcd58f2bfdd0fc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_a.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS A",
+ 'width' => 100,
+ 'template' => "templates/dns_a_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-\*]{0,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'A',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^([1-9]{1}|[1-9]\d|[1]\d\d|2[0-4]\d|25[0-5])\.(\d{1}|[1-9]\d|[1]\d\d|2[0-4]\d|25[0-5])\.(\d{1}|[1-9]\d|[1]\d\d|2[0-4]\d|25[0-5])\.(\d{1}|[1-9]\d|[1]\d\d|2[0-4]\d|25[0-5])$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_aaaa.tform.php b/interface/ispconfig/interface/dns/form/dns_aaaa.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..0a9e02123a73612d14d867a011ed1a5c49994a13
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_aaaa.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS AAAA",
+ 'width' => 100,
+ 'template' => "templates/dns_aaaa_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-\*]{0,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'AAAA',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^\s*((([0-9A-Fa-f]{1,4}:){7}(([0-9A-Fa-f]{1,4})|:))|(([0-9A-Fa-f]{1,4}:){6}(:|((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})|(:[0-9A-Fa-f]{1,4})))|(([0-9A-Fa-f]{1,4}:){5}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){0,1}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){0,2}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){0,3}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:)(:[0-9A-Fa-f]{1,4}){0,4}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(:(:[0-9A-Fa-f]{1,4}){0,5}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})))(%.+)?\s*$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_alias.tform.php b/interface/ispconfig/interface/dns/form/dns_alias.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..37ebc7793c52bd1ed5b2c8d944fafa89ee57e6cf
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_alias.tform.php
@@ -0,0 +1,161 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS ALIAS",
+ 'width' => 100,
+ 'template' => "templates/dns_alias_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'name_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'ALIAS',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_cname.tform.php b/interface/ispconfig/interface/dns/form/dns_cname.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..6409b975070006a29c9a9f4b37eac3b77b7724aa
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_cname.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS CNAME",
+ 'width' => 100,
+ 'template' => "templates/dns_cname_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-\*]{0,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'CNAME',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_hinfo.tform.php b/interface/ispconfig/interface/dns/form/dns_hinfo.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..fd8facf2c8ec2323c24d197f3c58d037bd3c3ebe
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_hinfo.tform.php
@@ -0,0 +1,158 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS HINFO",
+ 'width' => 100,
+ 'template' => "templates/dns_hinfo_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'name_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'HINFO',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_mx.tform.php b/interface/ispconfig/interface/dns/form/dns_mx.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..7a30d4e418543559c9b14af96f99fd96093a99fd
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_mx.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS mx",
+ 'width' => 100,
+ 'template' => "templates/dns_mx_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{0,255}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'MX',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,255}$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '10',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_ns.tform.php b/interface/ispconfig/interface/dns/form/dns_ns.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..2229bac377a49a1b698dfad986fb4e1a1c2d7fc7
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_ns.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS ns",
+ 'width' => 100,
+ 'template' => "templates/dns_ns_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{0,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'NS',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_ptr.tform.php b/interface/ispconfig/interface/dns/form/dns_ptr.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..c7521e7f841aaffb0d24f37f4c918594ac959d83
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_ptr.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS ptr",
+ 'width' => 100,
+ 'template' => "templates/dns_ptr_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'PTR',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_rp.tform.php b/interface/ispconfig/interface/dns/form/dns_rp.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..02a43196f8fd015a89099959a864a3d6c76dacf5
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_rp.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS RP",
+ 'width' => 100,
+ 'template' => "templates/dns_rp_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{0,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'RP',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-\s]{1,128}$/',
+ 'errmsg'=> 'data_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_soa.tform.php b/interface/ispconfig/interface/dns/form/dns_soa.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..605679f16054dcbafe700287062686759b305dc7
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_soa.tform.php
@@ -0,0 +1,230 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns_soa'] = array (
+ 'title' => "DNS Zone",
+ 'width' => 100,
+ 'template' => "templates/dns_soa_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'datasource' => array ( 'type' => 'SQL',
+ 'querystring' => 'SELECT server_id,server_name FROM server WHERE mirror_server_id = 0 AND dns_server = 1 AND {AUTHSQL} ORDER BY server_name',
+ 'keyfield'=> 'server_id',
+ 'valuefield'=> 'server_name'
+ ),
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'server_id_error_empty'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'origin' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'origin_error_empty'),
+ 1 => array ( 'type' => 'UNIQUE',
+ 'errmsg'=> 'origin_error_unique'),
+ 2 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-\/]{2,255}\.[a-zA-Z]{2,10}[\.]{0,1}$/',
+ 'errmsg'=> 'origin_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'ns' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{1,64}$/',
+ 'errmsg'=> 'ns_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'mbox' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'mbox_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[[a-zA-Z0-9\.\-]{0,64}\.$/',
+ 'errmsg'=> 'mbox_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'refresh' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '28800',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'retry' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '7200',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'expire' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '604800',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'minimum' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'xfer' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'also_notify' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'update_acl' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+$form["tabs"]['dns_records'] = array (
+ 'title' => "Records",
+ 'width' => 100,
+ 'template' => "templates/dns_records_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ ),
+ 'plugins' => array (
+ 'dns_records' => array (
+ 'class' => 'plugin_listview',
+ 'options' => array(
+ 'listdef' => 'list/dns_a.list.php',
+ 'sqlextwhere' => "zone = ".@intval(@$_REQUEST['id']),
+ 'sql_order_by' => "ORDER BY type, name"
+ )
+ )
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_srv.tform.php b/interface/ispconfig/interface/dns/form/dns_srv.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..4cc2f55c2a01559f53c3f18787a67c0ec8e3a9ab
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_srv.tform.php
@@ -0,0 +1,159 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS SRV",
+ 'width' => 100,
+ 'template' => "templates/dns_srv_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{0,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'SRV',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ 1 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{0,64}\s[\w\.\-]{0,64}\s[\w\.\-]{0,64}$/',
+ 'errmsg'=> 'srv_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_template.tform.php b/interface/ispconfig/interface/dns/form/dns_template.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..a648fd43c705b5699f046d6baae1537abdb4ce77
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_template.tform.php
@@ -0,0 +1,101 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['template'] = array (
+ 'title' => "DNS Template",
+ 'width' => 100,
+ 'template' => "templates/dns_template_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'name_error_empty'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '40',
+ 'maxlength' => '255'
+ ),
+ 'fields' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOXARRAY',
+ 'default' => '',
+ 'separator' => ',',
+ 'value' => array('DOMAIN' => 'Domain','IP' => 'IP Address','NS1' => 'NS 1','NS2' => 'NS 2','EMAIL' => 'Email')
+ ),
+ 'template' => array (
+ 'datatype' => 'TEXT',
+ 'formtype' => 'TEXTAREA',
+ 'default' => '',
+ 'value' => '',
+ 'cols' => '40',
+ 'rows' => '15'
+ ),
+ 'visible' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/form/dns_txt.tform.php b/interface/ispconfig/interface/dns/form/dns_txt.tform.php
new file mode 100644
index 0000000000000000000000000000000000000000..153bcc8eaabc0a0e149ea3ea4a13482ff52ee19b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/form/dns_txt.tform.php
@@ -0,0 +1,156 @@
+ 0 id must match with id of current user
+$form["auth_preset"]["groupid"] = 0; // 0 = default groupid of the user, > 0 id must match with groupid of current user
+$form["auth_preset"]["perm_user"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_group"] = 'riud'; //r = read, i = insert, u = update, d = delete
+$form["auth_preset"]["perm_other"] = ''; //r = read, i = insert, u = update, d = delete
+
+$form["tabs"]['dns'] = array (
+ 'title' => "DNS TXT",
+ 'width' => 100,
+ 'template' => "templates/dns_txt_edit.htm",
+ 'fields' => array (
+ ##################################
+ # Begin Datatable fields
+ ##################################
+ 'server_id' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'SELECT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'zone' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => @intval($_REQUEST["zone"]),
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'name' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'REGEX',
+ 'regex' => '/^[\w\.\-]{0,64}$/',
+ 'errmsg'=> 'name_error_regex'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'type' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => 'TXT',
+ 'value' => '',
+ 'width' => '5',
+ 'maxlength' => '5'
+ ),
+ 'data' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'validators' => array ( 0 => array ( 'type' => 'NOTEMPTY',
+ 'errmsg'=> 'data_error_empty'),
+ ),
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ /*
+ 'aux' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '0',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ */
+ 'ttl' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '86400',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ 'active' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'CHECKBOX',
+ 'default' => 'Y',
+ 'value' => array(0 => 'N',1 => 'Y')
+ ),
+ 'stamp' => array (
+ 'datatype' => 'VARCHAR',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '30',
+ 'maxlength' => '255'
+ ),
+ 'serial' => array (
+ 'datatype' => 'INTEGER',
+ 'formtype' => 'TEXT',
+ 'default' => '',
+ 'value' => '',
+ 'width' => '10',
+ 'maxlength' => '10'
+ ),
+ ##################################
+ # ENDE Datatable fields
+ ##################################
+ )
+);
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/admin.conf.php b/interface/ispconfig/interface/dns/lib/admin.conf.php
new file mode 100644
index 0000000000000000000000000000000000000000..a45d4403455c5c46f438046f088398e241cbc3d9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/admin.conf.php
@@ -0,0 +1,2 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg.lng b/interface/ispconfig/interface/dns/lib/lang/bg.lng
new file mode 100644
index 0000000000000000000000000000000000000000..36def8e93d3ba7fdd8be805098f12a23eda90593
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..88021395116d1d0cf878a58514d3314492c9b9a8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..87c9cd8185000323da69e78800acdb0f8ac85413
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..31ef0da1509439e879fecc0fb721370eab8e0d12
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0d90bcf40b582b1a534b157d4108f9dfad48da8e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..648827f04e34cb5e980ef95e06fbc29c9c39593e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..713ec28581af3acffceb7942d73834512d4e0d98
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c02638406828e181872e78791dba25ff7bed4dad
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d38efd1633fda6ca92aeb34765f765dba1e3f1fc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e63ffb70f668497a316be0e77dd408874502ca93
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_soa.lng
@@ -0,0 +1,26 @@
+these IPs (comma separated list)';
+$wb['active_txt'] = 'Active';
+$wb['limit_dns_zone_txt'] = 'The max. number of DNS zones for your account is reached.';
+$wb['client_txt'] = 'Client';
+$wb['no_zone_perm'] = 'You do not have the permission to add a record to this DNS zone.';
+$wb['server_id_error_empty'] = 'No server selected';
+$wb['origin_error_empty'] = 'Zone empty.';
+$wb['origin_error_unique'] = 'There is already a record for this zone.';
+$wb['origin_error_regex'] = 'Zone has a invalid format.';
+$wb['ns_error_regex'] = 'NS has a invalid format.';
+$wb['mbox_error_empty'] = 'Email is empty.';
+$wb['mbox_error_regex'] = 'Email format invalid.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..42bb32920ccbd370c1ffb932dbd0178b84637d73
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d4ea60be9760c7a5764ac69fef6cb9b51ff5d339
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3a09e3bb71b6fc2ba62aa40fce668fc2dd86ffe8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8d9d730e5031ef939eff8da85b9f426b82d13b88
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e6c417d0d8474bc698d2a0e920334732e979d0e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/bg_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/bg_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ffceabb53acd2e84b2339c325707ce5dbbd2022d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/bg_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br.lng b/interface/ispconfig/interface/dns/lib/lang/br.lng
new file mode 100644
index 0000000000000000000000000000000000000000..de70fdb275219ee4a5607617e23e45805b7cd22c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..137af7c18757624a9cb18b379f753dd116e8688e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b231c8342df6f00104dadaec3146cecef35f92fe
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..17e77b215a3e6d814c4ee934cd4a0b82aea11ace
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d026ddfaa5e261ebb109cd0de9b46b91a5f675cc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..881cb637614470cf087978914938fcbd2e17b35d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ac6e13b0650499ca7762b5feb40303b99ea0bd11
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0dfd536a2781e485bc32d1e2e24f8bc6901d72bb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ef9966fca174c1dfeef3477bfe43512ae48c78bd
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..728ea0731a63dfd6789806b184846c66c5352057
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d1854700f5c522ac0c3b14f2120f848f1cb67679
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..486d05afb32edc5bd50740952999799b53e84a79
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_soa.lng
@@ -0,0 +1,26 @@
+estes IPs (lista separada por ponto e vírgula)';
+$wb['active_txt'] = 'Ativo';
+$wb['limit_dns_zone_txt'] = 'O número máximo de zonas DNS para sua conta foi atingido.';
+$wb['client_txt'] = 'Cliente';
+$wb['no_zone_perm'] = 'Você não tem permição para adcionar registros a está zona DNS.';
+$wb['server_id_error_empty'] = 'Servidor não selecionado';
+$wb['origin_error_empty'] = 'Zona vazia.';
+$wb['origin_error_unique'] = 'Este registro já existe nesta zona.';
+$wb['origin_error_regex'] = 'Formato de zona inválido.';
+$wb['ns_error_regex'] = 'NS tem um formato inválido.';
+$wb['mbox_error_empty'] = 'Correio está em branco.';
+$wb['mbox_error_regex'] = 'Correio com formato inválido.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Atualizar ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ef0c93fa2f42652c625ff2243b0948613e728ad1
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8a389f58d95e7430f857e1ffbb97196f8dbb203f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9d7331b79551cb30afbda2c99e1ae9bc49dec0b7
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a4602aec97ad3ed69a3731e5ae6e9650433bb4a2
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f73ada31df537a20663441a841661e76b3095012
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/br_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/br_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..6a94ec29dbb194bac049071ec292478b63cca5cc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/br_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de.lng b/interface/ispconfig/interface/dns/lib/lang/de.lng
new file mode 100644
index 0000000000000000000000000000000000000000..319b221fba94cb03abdb71153ef3e2bfb2e4f06b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ea6d021781d13c1fa2a27606b0f2c2732451fa15
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0481c2b67a73d0c63d315ac96d502bb7a454ce52
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..768e67056890533fbcfcdff59ee103a9eb7f2715
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9475644b21a5b18958b40ff1265e6b31277405f9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4c3d5a0a5c190b98b9894eac61bd827ec11ad27b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..245480f3b7c2447868c3ff70169be0a1a180a08a
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ab21cc49874a707f46afc4b9d1ae1a98babe1112
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..845da9dc1eb8747f55cd15b92cd7337b0b56b5cd
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..aee4155968595be066ce9d726e3c6504e36d1e98
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..86f3fc02bf4ad796f21a66b94b5d5ee70479c90b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d619a3ccedfa97969b2e71f0de9658027af6d1bb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_soa.lng
@@ -0,0 +1,26 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..92f098c844f1be78e9341e0ee81300edcd2bc34f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..352e9598c48a12c723135348de8c421ef6d9e390
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..33d1090cbaa7f556a9caf3f8e8225c9c6807a80c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..45f0c5c5af3656864fb82c40de07cf1f682f19f4
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..182e9945ab0856cba07138558fd4b8e79d21a98c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/de_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/de_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..6f1bfbe3a615a077fcf3fd5f189b5bc1ccac8336
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/de_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/en.lng b/interface/ispconfig/interface/dns/lib/lang/en.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c4a5beaada1950d996766bda0196ed0e55f89bea
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en.lng
@@ -0,0 +1,22 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..599de5cf9361157efaf7fec8e2b5268514e37bce
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_a.lng
@@ -0,0 +1,16 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..88a2366a53d8b9f7e8f241d3c7d0d7b5d32a055c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_a_list.lng
@@ -0,0 +1,14 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c56d55863bee2496b2fefa05a229e4893d732b39
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..46f73a38784509f309184d8392ffc255b99468a1
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_alias.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..46f73a38784509f309184d8392ffc255b99468a1
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_cname.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0fb7f4597ce132a1b20e6b759b06759171a15481
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d0bee5eba35ea8ad8d90153ee0552d647ebeee43
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_mx.lng
@@ -0,0 +1,16 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9e0e1e149efe6c2012d3dceb8709eda045dd5ac8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_ns.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1219a96e1f57be52bff5cb5c6442e73cca6e2583
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_ptr.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e705d9fff07b4f9ef5748d3cc324febba48cf4ba
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_rp.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3c9a5b0a525441d5de91bc8820eecd0106ddd303
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_soa.lng
@@ -0,0 +1,26 @@
+these IPs (comma separated list)';
+$wb["active_txt"] = 'Active';
+$wb["limit_dns_zone_txt"] = 'The max. number of DNS zones for your account is reached.';
+$wb["client_txt"] = 'Client';
+$wb["no_zone_perm"] = 'You do not have the permission to add a record to this DNS zone.';
+$wb["server_id_error_empty"] = 'No server selected';
+$wb["origin_error_empty"] = 'Zone empty.';
+$wb["origin_error_unique"] = 'There is already a record for this zone.';
+$wb["origin_error_regex"] = 'Zone has a invalid format.';
+$wb["ns_error_regex"] = 'NS has a invalid format.';
+$wb["mbox_error_empty"] = 'Email is empty.';
+$wb["mbox_error_regex"] = 'Email format invalid.';
+$wb["also_notify_txt"] = 'Also Notify';
+$wb["update_acl_txt"] = 'Update ACL';
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..6213bdb1dc5b7c77750682be0664245c216c0db0
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d0dcd1eb2636b365110f855be3c28ebaab2c2f2b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_srv.lng
@@ -0,0 +1,16 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..37643e11926ee198f77d9ab54f79468dcb72ec83
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_template.lng
@@ -0,0 +1,6 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..33460a20ac5f93c02d6fc4baeb677f5c9c708809
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_template_list.lng
@@ -0,0 +1,6 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..af43605901f4851ea84455037cedcca175a3794b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_txt.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/en_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/en_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2f9f91421f1ff171ad0050f41f9427e5305ec305
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/en_dns_wizard.lng
@@ -0,0 +1,30 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/es.lng b/interface/ispconfig/interface/dns/lib/lang/es.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4fd59f49dde8a5d4b4548b583385fc6181187b7f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..36f318c8682b086535fc195e1a30bbb6eb206b9c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1cbe6d305a225d084f32bcd6d757dbc6d89eaa88
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..15ee1d2f352841c6cac74574ed4b06d993041488
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..705b5cf0d90b2074a51de922b62fb44cea26d73b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7c3f7b7f12c12b555408f593f908395035897061
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d5412cac47ecb1fdf9c46d2c6e52f6890fcd77c8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e7c377d66591ab9d7cc4261f79a99dfcc8719a90
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..568700987301aebe51c353e88a72d5d9a838b377
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f8ef426e4a81b2772a005e3d67c260e526d0d561
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..fece32a2bad9d34c945d9747c5df4b120bbabc81
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c4143bc6331148752b7e5998f7cd0a1284b20dcd
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_soa.lng
@@ -0,0 +1,26 @@
+estas IPs (lista separada por comas)';
+$wb['active_txt'] = 'Activar';
+$wb['limit_dns_zone_txt'] = 'Se ha alcanzado el número máximo de zonas DNS para esta cuenta.';
+$wb['client_txt'] = 'Cliente';
+$wb['no_zone_perm'] = 'No tiene permisos para añadir registros a esta zona DNS.';
+$wb['server_id_error_empty'] = 'No se ha seleccionado el servidor.';
+$wb['origin_error_empty'] = 'Zona vacía.';
+$wb['origin_error_unique'] = 'Ya hay un registro para esta zona.';
+$wb['origin_error_regex'] = 'Formato de zona no válido.';
+$wb['ns_error_regex'] = 'Formato de NS no válido.';
+$wb['mbox_error_empty'] = 'Correo vacío.';
+$wb['mbox_error_regex'] = 'Formato de correo no válido.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ab942dd50fe1c9c6f1cdd75356bf4d1a8f6e2c70
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e524ee4d689aa34a2d09a05c2587c097483a2c0
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..79ac234a0fa7a029ce6512be305ebfeef5f2e858
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..388a4c156b8b839af2a17d07457e8a64c2730b5f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..55bde142d09b2c2cfaec7204078819ca5f69cafb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/es_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/es_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0713bcc0a8c64f1fefe48c923a36917a708a913c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/es_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi.lng b/interface/ispconfig/interface/dns/lib/lang/fi.lng
new file mode 100644
index 0000000000000000000000000000000000000000..bdca8cd965ca51cf3c7cb2f25c9d7b5a3fc40494
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3a4af610e5c96fd09455aa8f1fcee2e919327848
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0cc82874bab543ed5fab1a4ad671561aad3d0874
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b87d7ac296ec5fc9c5c5070115bae730f7df16db
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..20da599c72e46cc81013cab4fa9f24611c7542b4
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a58f0d2f2cf1ef58839ec6dc57b83007f194f9c8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ea2fb93a39c6aad638f6af52d593d32220d71f4e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e4b4a60d56741f7b40c09f324705df47944cb1e8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8f97c53cb27dfcd9306e6b4b776b09dd57d82520
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9885c2be9d8619af40ed6c4bcd2844448f7f5f4e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d47cdcfbdd063ea29c11a0ddd0fa76cf34f01c74
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7e70915d723d88aabcab0676f7535036971b9a94
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_soa.lng
@@ -0,0 +1,26 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..95d104443ad6411eef09abe2340ad9a1adf56d12
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..68f4c859eb84aee0f9d31f29970ad2ded2c72edf
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b34a92d6a9e45fc952fadedf5defae9602e60b1f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..47c8924237e420d826acb1600abc66f2a68921c8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d1235ba07a181fdc1617572b1616fdde9154a7a9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fi_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/fi_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..dba630674f9e6184bf7e28a0b432662d1d6b8abc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fi_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr.lng b/interface/ispconfig/interface/dns/lib/lang/fr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..fe6ece558f5387fe054cddbb2ec294be92c2264e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..731c3e4fa8bfcef8b1ba977924d76f25011dac9b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0817826152d3fe599ee0002dbfc93f401d26bb01
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..503795f0e414be4e09b700e1a0c65ea0c6b3fd18
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1ae97aecdf48494a5e01b4aab71ea11ab07aae3e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..87fc49ea0e6f7fadba52233cf0f3c1c97f5c324b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f26ed7dd5bda9db2a90ac3e07fb46c698cff16bb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e3904207a9254ea2db6312f3d0a5b78ba6b60fdf
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a6edc6eaa56342357d7f727ead19130d2e42da76
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4318e000ebf4268f16ad2102aa232bbf52b64836
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..fe37f3e79db3cff21432bac4c303a8d2df4fea22
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..28c81c41c8d4c565c5cb4e3a6f6c9eecb9545920
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_soa.lng
@@ -0,0 +1,26 @@
+ces IP (liste séparée par des virgules)';
+$wb['active_txt'] = 'Actif';
+$wb['client_txt'] = 'Client';
+$wb['no_zone_perm'] = 'Vous navez pas la permissions dajouter un enregistrement dans cette zone DNS.';
+$wb['server_id_error_empty'] = 'Pas de serveur sélectionné';
+$wb['origin_error_empty'] = 'Zone vide.';
+$wb['origin_error_unique'] = 'Il y a déja un enregistrement pour cette zone.';
+$wb['origin_error_regex'] = 'La zone est dun format invalide.';
+$wb['ns_error_regex'] = 'Le serveur de nom est dun format invalide.';
+$wb['mbox_error_empty'] = 'Ladresse e-mail est vide.';
+$wb['mbox_error_regex'] = 'Ladresse e-mail est dun format invalide.';
+$wb['limit_dns_zone_txt'] = 'The max. number of DNS zones for your account is reached.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a828044a045725068cdc164588c53c87763347f7
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..de8776354d5e1647023e6d22a29e9ef5ba87e628
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1202cfd76840adc991a7ebd7148c396b30395c3a
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..52455b2ca428f449fdb9131dd724d376f1d89a34
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2126a3f247078899d01dab3138ca3a0de4f22e7e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/fr_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/fr_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b828acd2cc6bae20fc653aedc06fcf75568eef32
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/fr_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu.lng b/interface/ispconfig/interface/dns/lib/lang/hu.lng
new file mode 100644
index 0000000000000000000000000000000000000000..36def8e93d3ba7fdd8be805098f12a23eda90593
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..88021395116d1d0cf878a58514d3314492c9b9a8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..acab15029778695ffc34a07e2a290080a0cb77cb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..31ef0da1509439e879fecc0fb721370eab8e0d12
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0d90bcf40b582b1a534b157d4108f9dfad48da8e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..648827f04e34cb5e980ef95e06fbc29c9c39593e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..713ec28581af3acffceb7942d73834512d4e0d98
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c02638406828e181872e78791dba25ff7bed4dad
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d38efd1633fda6ca92aeb34765f765dba1e3f1fc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e63ffb70f668497a316be0e77dd408874502ca93
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_soa.lng
@@ -0,0 +1,26 @@
+these IPs (comma separated list)';
+$wb['active_txt'] = 'Active';
+$wb['limit_dns_zone_txt'] = 'The max. number of DNS zones for your account is reached.';
+$wb['client_txt'] = 'Client';
+$wb['no_zone_perm'] = 'You do not have the permission to add a record to this DNS zone.';
+$wb['server_id_error_empty'] = 'No server selected';
+$wb['origin_error_empty'] = 'Zone empty.';
+$wb['origin_error_unique'] = 'There is already a record for this zone.';
+$wb['origin_error_regex'] = 'Zone has a invalid format.';
+$wb['ns_error_regex'] = 'NS has a invalid format.';
+$wb['mbox_error_empty'] = 'Email is empty.';
+$wb['mbox_error_regex'] = 'Email format invalid.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..42bb32920ccbd370c1ffb932dbd0178b84637d73
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d4ea60be9760c7a5764ac69fef6cb9b51ff5d339
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3a09e3bb71b6fc2ba62aa40fce668fc2dd86ffe8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8d9d730e5031ef939eff8da85b9f426b82d13b88
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e6c417d0d8474bc698d2a0e920334732e979d0e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/hu_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/hu_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ffceabb53acd2e84b2339c325707ce5dbbd2022d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/hu_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it.lng b/interface/ispconfig/interface/dns/lib/lang/it.lng
new file mode 100644
index 0000000000000000000000000000000000000000..36def8e93d3ba7fdd8be805098f12a23eda90593
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..88021395116d1d0cf878a58514d3314492c9b9a8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..87c9cd8185000323da69e78800acdb0f8ac85413
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..31ef0da1509439e879fecc0fb721370eab8e0d12
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0d90bcf40b582b1a534b157d4108f9dfad48da8e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..648827f04e34cb5e980ef95e06fbc29c9c39593e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..713ec28581af3acffceb7942d73834512d4e0d98
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c02638406828e181872e78791dba25ff7bed4dad
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d38efd1633fda6ca92aeb34765f765dba1e3f1fc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e63ffb70f668497a316be0e77dd408874502ca93
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_soa.lng
@@ -0,0 +1,26 @@
+these IPs (comma separated list)';
+$wb['active_txt'] = 'Active';
+$wb['limit_dns_zone_txt'] = 'The max. number of DNS zones for your account is reached.';
+$wb['client_txt'] = 'Client';
+$wb['no_zone_perm'] = 'You do not have the permission to add a record to this DNS zone.';
+$wb['server_id_error_empty'] = 'No server selected';
+$wb['origin_error_empty'] = 'Zone empty.';
+$wb['origin_error_unique'] = 'There is already a record for this zone.';
+$wb['origin_error_regex'] = 'Zone has a invalid format.';
+$wb['ns_error_regex'] = 'NS has a invalid format.';
+$wb['mbox_error_empty'] = 'Email is empty.';
+$wb['mbox_error_regex'] = 'Email format invalid.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..42bb32920ccbd370c1ffb932dbd0178b84637d73
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d4ea60be9760c7a5764ac69fef6cb9b51ff5d339
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3a09e3bb71b6fc2ba62aa40fce668fc2dd86ffe8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8d9d730e5031ef939eff8da85b9f426b82d13b88
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e6c417d0d8474bc698d2a0e920334732e979d0e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/it_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/it_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ffceabb53acd2e84b2339c325707ce5dbbd2022d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/it_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja.lng b/interface/ispconfig/interface/dns/lib/lang/ja.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f96696bc841a285acc3ef5aff56984c212418b52
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..50f551627c7a0b15bb906d9c197e2e513de41633
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e2297bbbb0eb61a44bc9c82369092102e849e52f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2ca0650fe5c0de84bce1154dcd324df7bca888b9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4e469a104fad52c53745dda25d38c9ffaf65270d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4e469a104fad52c53745dda25d38c9ffaf65270d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a0df197ca301bfd4be00b059daafbfb99b261b46
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..648827f04e34cb5e980ef95e06fbc29c9c39593e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b9070d8318fe251ce288666632548f1d94e53c8d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8f5f3da20677d75e552da0308380a2888951bf62
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c43a721e6062137bd2a2610bc2c25c05cf8a9bcd
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d00e8afb65129b07d7da35c29679c696b579abf7
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_soa.lng
@@ -0,0 +1,26 @@
+(, で区切ってください)';
+$wb['active_txt'] = '有効';
+$wb['limit_dns_zone_txt'] = 'DNSゾーンが最大数に達しました。';
+$wb['client_txt'] = 'クライアント';
+$wb['no_zone_perm'] = 'このDNSゾーンにレコードを追加する権限がありません。';
+$wb['server_id_error_empty'] = 'サーバーを選択してください。';
+$wb['origin_error_empty'] = 'Zone を指定してください。';
+$wb['origin_error_unique'] = '同名の Zone が既に存在します。';
+$wb['origin_error_regex'] = 'Zone名が不正な文字を含んでいます。';
+$wb['ns_error_regex'] = 'NS が不正な文字を含んでいます。';
+$wb['mbox_error_empty'] = 'メールアドレスを指定してください';
+$wb['mbox_error_regex'] = 'メールアドレスの形式が不正です。';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d6660d9e00d6d1ff3e2cdc98774c31f5474144c7
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..94a7f37865ef223ae03237d220c84944182d0f1b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7c05ae1cc4fc62dac1fb6d48124a9690212854fb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2ed5746fa455600e6fb401aa14cf9a4bbb93e693
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3af17ab2553fd34f5db626f239dc1cfa60434ebc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ja_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/ja_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..508911da644035ad6f87d254c96fd4e6090524ea
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ja_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl.lng b/interface/ispconfig/interface/dns/lib/lang/nl.lng
new file mode 100644
index 0000000000000000000000000000000000000000..56e5386c5347d7cb68b087aa59624513fb2be46d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..32bab7464b27bd1c04e214eee07bededb7413b2d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9ffacd242cc258da36334e0c36e4bef2432d0348
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c40ae84d93ff60bccdc74e24cf5e4be2d8bc1300
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2f9cccf72da697aadf0c4196edd657fc829a2574
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c5891e427e108eb8dff1157ed70447e120f5c741
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a7287c4236e0bb512076d2b50f946c80219feadb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f93195c1b997f4bcc606008df44471675448270d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..75a91b41d654faf3dc6231c6a185ae5d2323bb54
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4bd156388de5c0b04f47213646ee554d6cdcbef5
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1195406a1e6eb6f38f1703b725e6a79f3204bd7d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e1d149aec9985385fb3919fb02d789751bcd5813
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_soa.lng
@@ -0,0 +1,26 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e6474cb1b53caf3073b6201e4ac58c2fc07181ea
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..202d62d4804dd8000173c33eddb9049457074c77
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a6f8e0e9b15450ff5ce9e789b995d8e52fd3680b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_template.lng
@@ -0,0 +1,6 @@
+ Voorbeeld (in nieuw venster)';
+$wb['visible_txt'] = 'Geactiveerd voor DNS wizard?';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..6ca214c55dcf6a7fe59cd2ab1676de4df12ce735
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..94dbb3f474a89000daa3ed1db183eede633ca004
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/nl_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/nl_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e7093f01e9a6ae6bf8c2ffea458998cf95c8e41f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/nl_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl.lng b/interface/ispconfig/interface/dns/lib/lang/pl.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0a3f1a9fbe22fd7fc42ab2879016ebf2c2598e8f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4ad0a7c41a003c124a7db4c2bb7f45acc309a1e1
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3d0db059b0f9945f7270daad3661ec34f0fce134
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..983fae1a8c68172cd0126fad52d69ae066b0e1f3
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a950805e3b4378caa7b4d4162242f4580ace4909
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..92cb4ac97dc20f604080d52cd632c8e7bf00b415
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..53b6da2265ca00e50f987b646e556435b8de04a5
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4a3936a1b4a03a728d9d5fa2a37ad49cea18ba80
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..18d7efd6cd3d6310b129234e6e2152d24b540602
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..eae39817a0b36242ea5805da88414b963054eb7d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ece9346e32e6d704726fc4c9d528a73cd40bee19
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..868615e081ee625e332c7e7123ac2a371f0bc42b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_soa.lng
@@ -0,0 +1,26 @@
+tych adresów IP (adresy rozdzielaj przecinkiem)';
+$wb['active_txt'] = 'Aktywny';
+$wb['limit_dns_zone_txt'] = 'Maksymalna ilość stref DNS dla Twojego konta została przekroczona.';
+$wb['client_txt'] = 'Klient';
+$wb['no_zone_perm'] = 'Nie masz uprawnień, aby dodać nowy wpis dla tej strefy DNS.';
+$wb['server_id_error_empty'] = 'Nie wybrano serwera';
+$wb['origin_error_empty'] = 'Strefa jest pusta.';
+$wb['origin_error_unique'] = 'Istnieje już wpis dla tej strefy.';
+$wb['origin_error_regex'] = 'Strefa ma niepoprawny format.';
+$wb['ns_error_regex'] = 'NS ma niepoprawny format.';
+$wb['mbox_error_empty'] = 'E-mail jest pusty.';
+$wb['mbox_error_regex'] = 'E-mail ma niepoprawny format.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..126209edaeb45f3a59e8b0ef93af6900a6919ad4
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..633962132a342e27a8a467f614d0553f56735079
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f3e756357728ab5538d7c01600bc25c23439c1bc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7deac3b2fa01cc7f62d7b9865abe0b969912a5d0
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..628d5c047edd2cf74335530a1704eeca49b3936f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pl_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/pl_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a5d6a90997b9b3b30433bff90dcbfc75e35fc056
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pl_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt.lng b/interface/ispconfig/interface/dns/lib/lang/pt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9f1ccffb47923267eb1b3b9af44ac83bbfeb736f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt.lng
@@ -0,0 +1,21 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3774b1a74291f2359a166cc26e073596f86ef609
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_a.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d7d55f21a224b89f4b3ed68cc082e0b14e09d896
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_a_list.lng
@@ -0,0 +1,15 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4b4524b6055a785bc1a16484b63e65f43a860eea
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_aaaa.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d7e91e6857a869c209f1b4528ebd666aed99cc58
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_alias.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..bb75bcc21d20c31da64add144dbbba7acbb5bf5a
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_cname.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..66829172781bd952145a0edffe2601e00c863451
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_hinfo.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d8b59a7659cda9718f578e2f4de65af853fac1f0
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_mx.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2e16d94de9de995bcd0c7e173fbd4c382fd29dec
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_ns.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..298872ad1f20c916ff739dd9b8cc9867ef0d21fc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_ptr.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ba45e858ce74c6a387b9d5527870815fb796822f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_rp.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..5d10de28d60359a9be993c78830749a84e2f44fe
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_soa.lng
@@ -0,0 +1,27 @@
+estes IPs (lista separada por ponto e vírgula)';
+$wb['active_txt'] = 'Activo';
+$wb['limit_dns_zone_txt'] = 'O número máximo de zonas DNS para a conta foi atingido.';
+$wb['client_txt'] = 'Cliente';
+$wb['no_zone_perm'] = 'Não tem permissão para adicionar registos a está zona DNS.';
+$wb['server_id_error_empty'] = 'Servidor não seleccionado';
+$wb['origin_error_empty'] = 'Zona vazia.';
+$wb['origin_error_unique'] = 'Este registo já existe nesta zona.';
+$wb['origin_error_regex'] = 'Formato de zona inválido.';
+$wb['ns_error_regex'] = 'NS tem um formato inválido.';
+$wb['mbox_error_empty'] = 'Correio está em branco.';
+$wb['mbox_error_regex'] = 'Correio com formato inválido.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Actualizar ACL';
+?>
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1345fafe3c724cdb52b2a2173c0a6934957cc0c4
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_soa_list.lng
@@ -0,0 +1,10 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..853bcf5aabf0a3bc26bdfb15d102b25b9d1b3518
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_srv.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9ee4e72228d1fd2572cb1947cb2a87297d8ce831
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_template.lng
@@ -0,0 +1,7 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1c89fd5156b89795c437d85cd76cd31b92cf6ea9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_template_list.lng
@@ -0,0 +1,7 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e731078ac92bce2939eb048a3fb57a652e5a03e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_txt.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/pt_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/pt_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e1663c1e2828c1801319c7f08e8d0c9a7f69fba
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/pt_dns_wizard.lng
@@ -0,0 +1,30 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro.lng b/interface/ispconfig/interface/dns/lib/lang/ro.lng
new file mode 100644
index 0000000000000000000000000000000000000000..908f2aa49873f71728520fc0773ac63d430728b6
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..617c9d6ba49ac511cf74deb9ff0c592be8c59e7f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a17f698eaea4dccbb0a47f0c6a61d02fe645abe0
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c56d55863bee2496b2fefa05a229e4893d732b39
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..defa63ac0ad356f2cfe93ec34b90b6dae5d85009
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..199d1f4310bc77eb919778399a538628027f26b0
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..598f7ab1a0c7e2c184a13468ffb2d6e5b7b6f72c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3c5b54892718fb30487dd43410e1e2e7f10041c3
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0bf8e7ed3f864c1b8e1920b39f23fef8c2ca049d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..cda046dd9d508c82adb30532e595ceadae39a7b4
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b77bab2e2f4111916b0df8fbbea434d501f0bfc3
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a70d730b32354d0fc13f6135cf608b9082195e00
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_soa.lng
@@ -0,0 +1,26 @@
+aceste IP-uri (comma separated list)';
+$wb['active_txt'] = 'Active';
+$wb['limit_dns_zone_txt'] = 'numar max DNS zone pentru contul dumnevoastra a fost atins.';
+$wb['client_txt'] = 'Client';
+$wb['no_zone_perm'] = 'Nu aveti permisiunea de a adauga aceasta inregistrare in zona DNS .';
+$wb['server_id_error_empty'] = 'Nu a fost ales serverul';
+$wb['origin_error_empty'] = 'Zone goale';
+$wb['origin_error_unique'] = 'Exista deja o inregistrare pentru aceasta zona';
+$wb['origin_error_regex'] = 'Zona are un format invalid';
+$wb['ns_error_regex'] = 'NS are un format invalid';
+$wb['mbox_error_empty'] = 'Email-ul este gol';
+$wb['mbox_error_regex'] = 'Format email invalid.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e17045622f7dec74a00de9137b58ff77603f5cd3
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a8b501156f3a72a3b30237affa80b4ab2e915932
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f097bb3a0085359889aa24e5e5c23f996370e1d7
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0a14156d2eadf800b3578da81baef21a67861101
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b3f781da0823ad88484d5f90920f226d2047bad4
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ro_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/ro_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..71d3497c6fd1078c0d6f8f69c7e13cb4082f0235
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ro_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru.lng b/interface/ispconfig/interface/dns/lib/lang/ru.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b47936efb4a9a40845d1aaa1d30a395acc34582d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru.lng
@@ -0,0 +1,21 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..81647b9a1717495867a278410a7e69d173472d9e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_a.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..803d4d685f804ac3352891b2e7934bf6643bdc29
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_a_list.lng
@@ -0,0 +1,15 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..869206924cfb11b29dce6e96fb7518c45b3e13b8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_aaaa.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..784f99ea3721d4124476c6abf139119f6f48a6b4
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_alias.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..6089373fe750d5d84483c98105200559541c502d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_cname.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..986891e8097622c5e4e2d931f490aba0faa72a45
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_hinfo.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d1bcbb2d13bf7a03e647a795a8c1712e10d52783
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_mx.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e9f7d611a1a0beb3a61469b6ddfbf4ab4960270
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_ns.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..2e5e0007c953c13eeb18868cd78cf048fe006ab9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_ptr.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..22015068f77117962b9863e659b998054535cb19
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_rp.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..03dfdeb4c4fd5a4837f9af949b5e7ad45cad007b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_soa.lng
@@ -0,0 +1,27 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..250f49a9931c08aa053c20599327e09e3d2f6d5d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_soa_list.lng
@@ -0,0 +1,10 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..dece24af952917e7cfc16e03adf8ea034d27d316
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_srv.lng
@@ -0,0 +1,17 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9b9b0c177905deb7111d37c2465ef8e41d73099b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_template.lng
@@ -0,0 +1,7 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b9c4fc38e49b7b75899868917dfbb43005020362
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_template_list.lng
@@ -0,0 +1,7 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..98e342f9a5f1d1c0777c0f3a550bfe551e18338d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_txt.lng
@@ -0,0 +1,16 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/ru_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/ru_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..62f27590943ce6320da8802272e20b1e82e3f087
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/ru_dns_wizard.lng
@@ -0,0 +1,30 @@
+
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se.lng b/interface/ispconfig/interface/dns/lib/lang/se.lng
new file mode 100644
index 0000000000000000000000000000000000000000..36def8e93d3ba7fdd8be805098f12a23eda90593
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..88021395116d1d0cf878a58514d3314492c9b9a8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..87c9cd8185000323da69e78800acdb0f8ac85413
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..31ef0da1509439e879fecc0fb721370eab8e0d12
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..827e5a89e86e078da9cb97ecb2bc4f5f9fd05272
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0d90bcf40b582b1a534b157d4108f9dfad48da8e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..648827f04e34cb5e980ef95e06fbc29c9c39593e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..713ec28581af3acffceb7942d73834512d4e0d98
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c02638406828e181872e78791dba25ff7bed4dad
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d38efd1633fda6ca92aeb34765f765dba1e3f1fc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e63ffb70f668497a316be0e77dd408874502ca93
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_soa.lng
@@ -0,0 +1,26 @@
+these IPs (comma separated list)';
+$wb['active_txt'] = 'Active';
+$wb['limit_dns_zone_txt'] = 'The max. number of DNS zones for your account is reached.';
+$wb['client_txt'] = 'Client';
+$wb['no_zone_perm'] = 'You do not have the permission to add a record to this DNS zone.';
+$wb['server_id_error_empty'] = 'No server selected';
+$wb['origin_error_empty'] = 'Zone empty.';
+$wb['origin_error_unique'] = 'There is already a record for this zone.';
+$wb['origin_error_regex'] = 'Zone has a invalid format.';
+$wb['ns_error_regex'] = 'NS has a invalid format.';
+$wb['mbox_error_empty'] = 'Email is empty.';
+$wb['mbox_error_regex'] = 'Email format invalid.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..42bb32920ccbd370c1ffb932dbd0178b84637d73
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d4ea60be9760c7a5764ac69fef6cb9b51ff5d339
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3a09e3bb71b6fc2ba62aa40fce668fc2dd86ffe8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8d9d730e5031ef939eff8da85b9f426b82d13b88
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..8e6c417d0d8474bc698d2a0e920334732e979d0e
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/se_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/se_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ffceabb53acd2e84b2339c325707ce5dbbd2022d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/se_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk.lng b/interface/ispconfig/interface/dns/lib/lang/sk.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a7f9836185dfde402d6f82105906d2d7bc41b3c1
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..ce9974d2f9d4fdedc3dc64207d0d4426e1b8dbb9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d1124a9531a3115bddc7c99beff5b10602049e97
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..03dfe3fc66aed3090e06c629f5d25182be918e79
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..a7b4cb228fe1909b4a83cea8b64fa582d8497925
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..dc768706bff7d81789e38c1b7673a4efb06ca8e5
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..33b814fe2cb7c79e7f9c2baadb66b1bf20c3c8f9
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d179568ae191c134e1bd07095be1f1233448c0ed
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..5df4592ebc417dc4310ac77f11631432bdc8000b
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..cac489d0541f1b5e76233fd3cd2fd6dd068bdedf
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..582b61c124b7682405a541fb8ac12864d84d424a
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..98de52e15a5cf04ef97d01ee7a96a0547f2d2a50
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_soa.lng
@@ -0,0 +1,26 @@
+tieto IP (comma separated list)';
+$wb['active_txt'] = 'Actvova?';
+$wb['limit_dns_zone_txt'] = 'Max. po?et zn DNS pre v ?et je dosiahnut.';
+$wb['client_txt'] = 'Klient';
+$wb['no_zone_perm'] = 'Nemte oprvnenie prida? zznam do tejto zny DNS.';
+$wb['server_id_error_empty'] = 'iaden vybran server';
+$wb['origin_error_empty'] = 'Prazdna zna.';
+$wb['origin_error_unique'] = 'V s?asnosti u existuje zznam pre tto znu.';
+$wb['origin_error_regex'] = 'Zna m neplatn formt.';
+$wb['ns_error_regex'] = 'NS m neplatn formt.';
+$wb['mbox_error_empty'] = 'Email je przdny.';
+$wb['mbox_error_regex'] = 'Email m neplatn formt.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..91a9788029c4632bfd9f75537737d33bee76fc57
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7f867d3af6f5ede33ebfc31aca6154042b8abdb8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4dd637f582dcf7537574183f51c78dc0076daedc
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0a7c5d7e9c18fc2cf6c024e20820d33d69cd86b0
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e0137c0dca773e5ccd9b4dd70cc84b063341b92c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/sk_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/sk_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7c845c7e9da12c97ac889de0c8dfd50c3c2b64cf
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/sk_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr.lng b/interface/ispconfig/interface/dns/lib/lang/tr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..36def8e93d3ba7fdd8be805098f12a23eda90593
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr.lng
@@ -0,0 +1,20 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_a.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_a.lng
new file mode 100644
index 0000000000000000000000000000000000000000..097833f028ac58776c3d4470675c9f9335df808d
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_a.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_a_list.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_a_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..77dcb83975f14a10fc5aae8ce3f9f508bed7c28f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_a_list.lng
@@ -0,0 +1,14 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_aaaa.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_aaaa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..3bcf2506184bce80bc634f5374835fb01ed63c2c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_aaaa.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_alias.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_alias.lng
new file mode 100644
index 0000000000000000000000000000000000000000..da1e6e61678d84b64715a8faa55f5d1303402c91
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_alias.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_cname.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_cname.lng
new file mode 100644
index 0000000000000000000000000000000000000000..d74cfebc994400efcb84e1d6dd7860e68592f6b8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_cname.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_hinfo.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_hinfo.lng
new file mode 100644
index 0000000000000000000000000000000000000000..7585d136530fd97318092c917c2724609c749254
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_hinfo.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_mx.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_mx.lng
new file mode 100644
index 0000000000000000000000000000000000000000..201f686ec5df19b0f27e6e99204a580632ce2ed6
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_mx.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_ns.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_ns.lng
new file mode 100644
index 0000000000000000000000000000000000000000..0a5ef933831c1e1ca9022350f28bb251a39fd09f
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_ns.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_ptr.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_ptr.lng
new file mode 100644
index 0000000000000000000000000000000000000000..e34394522f3194b3228e7519c499457c9d2ed1d1
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_ptr.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_rp.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_rp.lng
new file mode 100644
index 0000000000000000000000000000000000000000..f444fb0e17e15d8d262eb3751c4879b395499cf5
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_rp.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_soa.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_soa.lng
new file mode 100644
index 0000000000000000000000000000000000000000..756ea05d2a2a67147be971bac0cd82cc1be55a42
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_soa.lng
@@ -0,0 +1,26 @@
+these IPs (comma separated list)';
+$wb['active_txt'] = 'Aktif';
+$wb['limit_dns_zone_txt'] = 'Hesabınızdaki max. DNS zone kaydına ulaşıldı.';
+$wb['client_txt'] = 'Müşteri';
+$wb['no_zone_perm'] = 'Bu DNS Zone kaydını eklemek için yetkiniz yok.';
+$wb['server_id_error_empty'] = 'Seçili sunucu yok';
+$wb['origin_error_empty'] = 'Zone boş.';
+$wb['origin_error_unique'] = 'Bu zone için bir kayıt zaten var.';
+$wb['origin_error_regex'] = 'Zone geçersiz formatta.';
+$wb['ns_error_regex'] = 'NS geçersiz formatta.';
+$wb['mbox_error_empty'] = 'Email boş.';
+$wb['mbox_error_regex'] = 'Email geçersiz formatta.';
+$wb['also_notify_txt'] = 'Also Notify';
+$wb['update_acl_txt'] = 'Update ACL';
+?>
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_soa_list.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_soa_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..4670b20f56cdf267f128776fac4a969ca6a2ef12
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_soa_list.lng
@@ -0,0 +1,9 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_srv.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_srv.lng
new file mode 100644
index 0000000000000000000000000000000000000000..c56d06edaf3fe4882fff21f69947ea2a6d4c080c
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_srv.lng
@@ -0,0 +1,16 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_template.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_template.lng
new file mode 100644
index 0000000000000000000000000000000000000000..1c973fa6d6f9fe223828a3d0a5765251134df9a1
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_template.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_template_list.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_template_list.lng
new file mode 100644
index 0000000000000000000000000000000000000000..9bc064c76321cae9ed7ea9145501de0e27357f94
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_template_list.lng
@@ -0,0 +1,6 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_txt.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_txt.lng
new file mode 100644
index 0000000000000000000000000000000000000000..b2475219e92715d0fb9cb383b0f0b7e5683aa344
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_txt.lng
@@ -0,0 +1,15 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/lang/tr_dns_wizard.lng b/interface/ispconfig/interface/dns/lib/lang/tr_dns_wizard.lng
new file mode 100644
index 0000000000000000000000000000000000000000..dbd4d5a882b8b29db5f27721d7589adf0e839edb
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/lang/tr_dns_wizard.lng
@@ -0,0 +1,29 @@
+
diff --git a/interface/ispconfig/interface/dns/lib/module.conf.php b/interface/ispconfig/interface/dns/lib/module.conf.php
new file mode 100644
index 0000000000000000000000000000000000000000..ae7e8c456c72320351ed89d1edfdc873bce8a2c8
--- /dev/null
+++ b/interface/ispconfig/interface/dns/lib/module.conf.php
@@ -0,0 +1,57 @@
+ "Add DNS Zone",
+ 'target' => 'content',
+ 'link' => 'dns/dns_wizard.php');
+
+if($_SESSION["s"]["user"]["typ"] == 'admin') {
+
+ $items[] = array( 'title' => "Templates",
+ 'target' => 'content',
+ 'link' => 'dns/dns_template_list.php');
+}
+
+
+$module["nav"][] = array( 'title' => 'DNS Wizard',
+ 'open' => 1,
+ 'items' => $items);
+
+
+unset($items);
+
+/*
+ Email accounts menu
+*/
+
+
+$items[] = array( 'title' => "Zones",
+ 'target' => 'content',
+ 'link' => 'dns/dns_soa_list.php');
+/*
+$items[] = array( 'title' => "A-Records",
+ 'target' => 'content',
+ 'link' => 'dns/dns_a_list.php');
+*/
+
+
+$module["nav"][] = array( 'title' => 'DNS',
+ 'open' => 1,
+ 'items' => $items);
+
+unset($items);
+
+
+
+
+
+
+
+
+?>
\ No newline at end of file
diff --git a/interface/ispconfig/interface/dns/list/dns_a.list.php b/interface/ispconfig/interface/dns/list/dns_a.list.php
new file mode 100644
index 0000000000000000000000000000000000000000..54470cfc1221f9704be013fe6e39bd15814165bf
--- /dev/null
+++ b/interface/ispconfig/interface/dns/list/dns_a.list.php
@@ -0,0 +1,127 @@
+ "active",
+ 'datatype' => "VARCHAR",
+ 'formtype' => "SELECT",
+ 'op' => "=",
+ 'prefix' => "",
+ 'suffix' => "",
+ 'width' => "",
+ 'value' => array('y' => "
Basic push button that can execute a user-specified command when
+* pressed.
+*
link
+*
Navigates to a specified url when pressed.
+*
submit
+*
Submits the parent form when pressed.
+*
reset
+*
Resets the parent form when pressed.
+*
checkbox
+*
Maintains a "checked" state that can be toggled on and off.
+*
radio
+*
Maintains a "checked" state that can be toggled on and off. Use with
+* the ButtonGroup class to create a set of controls that are mutually
+* exclusive; checking one button in the set will uncheck all others in
+* the group.
+*
menubutton
+*
When pressed will show/hide a menu.
+*
splitbutton
+*
Can execute a user-specified command or display a menu when pressed.
+*
+* @title Button
+* @namespace YAHOO.widget
+* @requires yahoo, dom, element, event
+* @optional container, menu
+* @beta
+*/
+
+
+(function() {
+
+// Shorthard for utilities
+
+var Dom = YAHOO.util.Dom,
+ Event = YAHOO.util.Event,
+ Lang = YAHOO.lang,
+
+
+ // Private member variables
+
+ m_oButtons = {},
+ m_oFocusedButton = null;
+
+
+
+// Constructor
+
+
+/**
+* The Button class creates a rich, graphical button.
+* @param {String} p_oElement String specifying the id attribute of the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {HTMLInputElement|HTMLElement} p_oElement Object reference for the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {Object} p_oElement Object literal specifying a set of configuration
+* attributes used to create the button.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button.
+* @namespace YAHOO.widget
+* @class Button
+* @constructor
+* @extends YAHOO.util.Element
+*/
+YAHOO.widget.Button = function(p_oElement, p_oAttributes) {
+
+ var fnSuperClass = YAHOO.widget.Button.superclass.constructor;
+
+ if(
+ arguments.length == 1 &&
+ !Lang.isString(p_oElement) &&
+ !p_oElement.nodeName
+ ) {
+
+ if(!p_oElement.id) {
+
+ p_oElement.id = Dom.generateId();
+
+ YAHOO.log(
+ "No value specified for the button's \"id\" attribute. " +
+ "Setting button id to \"" + p_oElement.id + "\".",
+ "warn"
+ );
+
+ }
+
+ this.logger = new YAHOO.widget.LogWriter("Button " + p_oElement.id);
+
+ this.logger.log(
+ "No source HTML element. " +
+ "Building the button using the set of configuration attributes."
+ );
+
+ fnSuperClass.call(
+ this,
+ (this._createButtonElement(p_oElement.type)),
+ p_oElement
+ );
+
+ }
+ else {
+
+ var oConfig = {
+
+ element: null,
+ attributes: (p_oAttributes || {})
+
+ };
+
+
+ if(Lang.isString(p_oElement)) {
+
+ var me = this;
+
+ Event.onAvailable(p_oElement, function() {
+
+ var sTagName = this.tagName.toUpperCase();
+
+ if(sTagName == me.TAG_NAME) {
+
+ oConfig.attributes.id = this.id;
+
+ }
+ else if(sTagName == "INPUT" && !oConfig.attributes.id) {
+
+ oConfig.attributes.id = Dom.generateId();
+
+ YAHOO.log(
+ "No value specified for the button's \"id\" " +
+ "attribute. Setting button id to \"" +
+ oConfig.attributes.id + "\".",
+ "warn"
+ );
+
+ }
+
+ me.logger = new YAHOO.widget.LogWriter(
+ "Button " + oConfig.attributes.id
+ );
+
+ me.logger.log(
+ "Building the button using an existing HTML " +
+ "element as a source element."
+ );
+
+
+ oConfig.attributes.srcelement = this;
+
+ initConfig.call(me, oConfig);
+
+
+ if(!oConfig.element) {
+
+ me.logger.log(
+ "Source element could not be used as is. " +
+ "Creating a new HTML element for the button."
+ );
+
+ oConfig.element =
+ me._createButtonElement(oConfig.attributes.type);
+
+ }
+
+ fnSuperClass.call(me, oConfig.element, oConfig.attributes);
+
+ });
+
+ }
+ else {
+
+ var sTagName = p_oElement.tagName.toUpperCase();
+
+ if(sTagName == this.TAG_NAME) {
+
+ if(p_oElement.id) {
+
+ oConfig.attributes.id = p_oElement.id;
+
+ }
+ else {
+
+ oConfig.attributes.id = Dom.generateId();
+
+ YAHOO.log(
+ "No value specified for the button's \"id\" " +
+ "attribute. Setting button id to \"" +
+ oConfig.attributes.id + "\".",
+ "warn"
+ );
+
+ }
+
+
+ }
+ else if(sTagName == "INPUT" && !oConfig.attributes.id) {
+
+ oConfig.attributes.id = Dom.generateId();
+
+ YAHOO.log(
+ "No value specified for the button's \"id\" " +
+ "attribute. Setting button id to \"" +
+ oConfig.attributes.id + "\".",
+ "warn"
+ );
+
+ }
+
+ this.logger =
+ new YAHOO.widget.LogWriter("Button " + oConfig.attributes.id);
+
+ this.logger.log(
+ "Building the button using an existing HTML element as " +
+ "a source element."
+ );
+
+
+ oConfig.attributes.srcelement = p_oElement;
+
+ initConfig.call(this, oConfig);
+
+
+ if(!oConfig.element) {
+
+ this.logger.log(
+ "Source element could not be used as is. " +
+ "Creating a new HTML element for the button."
+ );
+
+ oConfig.element =
+ this._createButtonElement(oConfig.attributes.type);
+
+ }
+
+ fnSuperClass.call(this, oConfig.element, oConfig.attributes);
+
+ }
+
+ }
+
+};
+
+
+
+// Private methods
+
+
+/**
+* @method getFirstElement
+* @description Returns an HTML element's first HTML element node.
+* @private
+* @param {HTMLElement} p_oElement Object
+* reference specifying the element to be evaluated.
+* @return {HTMLElement}
+*/
+function getFirstElement(p_oElement) {
+
+ var oFirstChild = p_oElement.firstChild;
+
+ if(oFirstChild) {
+
+ if(oFirstChild.nodeType == 1) {
+
+ return oFirstChild;
+
+ }
+ else {
+
+ var oNextSibling = oFirstChild.nextSibling;
+
+ if(oNextSibling && oNextSibling.nodeType == 1) {
+
+ return oNextSibling;
+
+ }
+
+ }
+
+ }
+
+}
+
+
+/**
+* @method createInputElement
+* @description Creates an <input> element of the
+* specified type.
+* @private
+* @param {String} p_sType String specifying the type of
+* <input> element to create.
+* @param {String} p_sName String specifying the name of
+* <input> element to create.
+* @param {String} p_sValue String specifying the value of
+* <input> element to create.
+* @param {String} p_bChecked Boolean specifying if the
+* <input> element is to be checked.
+* @return {HTMLInputElement}
+*/
+function createInputElement(p_sType, p_sName, p_sValue, p_bChecked) {
+
+ var oInput;
+
+ if(navigator.userAgent.indexOf("MSIE") != -1) {
+
+ /*
+ For IE it is necessary to create the element with the
+ "type," "name," "value," and "checked" properties set all at once.
+ */
+
+ var sInput = "";
+
+ oInput = document.createElement(sInput);
+
+ }
+ else {
+
+ oInput = document.createElement("input");
+ oInput.name = p_sName;
+ oInput.type = p_sType;
+
+ if(p_bChecked) {
+
+ oInput.checked = true;
+
+ }
+
+ }
+
+ oInput.value = p_sValue;
+
+ return oInput;
+
+}
+
+
+/**
+* @method setAttributesFromSrcElement
+* @description Gets the values for all the attributes of the source element
+* (either <input> or <a>) that map to
+* Button configuration attributes and sets them into a collection that is
+* passed to the Button constructor.
+* @private
+* @param {HTMLInputElement|HTMLAnchorElement} p_oElement Object reference to the HTML
+* element (either <input> or <span>)
+* used to create the button.
+* @param {Object} p_oAttributes Object reference for the collection of
+* configuration attributes used to create the button.
+*/
+function setAttributesFromSrcElement(p_oElement, p_oAttributes) {
+
+ var me = this;
+
+ /**
+ * @method setAttributeFromDOMAttribute
+ * @description Gets the value of the specified DOM attribute and sets it
+ * into the collection of configuration attributes used to configure
+ * the button.
+ * @private
+ * @param {String} p_sAttribute String representing the name of the
+ * attribute to retrieve from the DOM element.
+ */
+ function setAttributeFromDOMAttribute(p_sAttribute) {
+
+ if( !(p_sAttribute in p_oAttributes) ) {
+
+ /*
+ Need to use "getAttributeNode" instead of "getAttribute"
+ because using "getAttribute," IE will return the innerText of
+ a <button> for the value attribute rather
+ than the value of the "value" attribute.
+ */
+
+ var oAttribute = p_oElement.getAttributeNode(p_sAttribute);
+
+
+ if(oAttribute && ("value" in oAttribute)) {
+
+ me.logger.log(
+ "Setting attribute \"" + p_sAttribute + "\" using " +
+ "source element's attribute value of \"" +
+ oAttribute.value + "\""
+ );
+
+ p_oAttributes[p_sAttribute] = oAttribute.value;
+
+ }
+
+ }
+
+ }
+
+
+ /**
+ * @method setFormElementProperties
+ * @description Gets the value of the attributes from the form element and
+ * sets them into the collection of configuration attributes used to
+ * configure the button.
+ * @private
+ */
+ function setFormElementProperties() {
+
+ setAttributeFromDOMAttribute("type");
+
+ if( !("disabled" in p_oAttributes) ) {
+
+ p_oAttributes.disabled = p_oElement.disabled;
+
+ }
+
+ setAttributeFromDOMAttribute("name");
+ setAttributeFromDOMAttribute("value");
+ setAttributeFromDOMAttribute("title");
+
+ }
+
+
+ var sSrcElementTagName = p_oElement.tagName.toUpperCase();
+
+
+ if( !("label" in p_oAttributes) ) {
+
+ // Set the "label" property
+
+ var sText = sSrcElementTagName == "INPUT" ?
+ p_oElement.value : p_oElement.innerHTML;
+
+
+ if(sText && sText.length > 0) {
+
+ p_oAttributes.label = sText;
+
+ }
+
+ }
+
+
+ setAttributeFromDOMAttribute("tabindex");
+ setAttributeFromDOMAttribute("accesskey");
+
+
+ switch(sSrcElementTagName) {
+
+ case "A":
+
+ p_oAttributes.type = "link";
+
+ setAttributeFromDOMAttribute("href");
+ setAttributeFromDOMAttribute("target");
+
+ break;
+
+ case "INPUT":
+
+ setFormElementProperties();
+
+ if( !("checked" in p_oAttributes) ) {
+
+ p_oAttributes.checked = p_oElement.checked;
+
+ }
+
+ break;
+
+ case "BUTTON":
+
+ setFormElementProperties();
+
+ var oRootNode = p_oElement.parentNode.parentNode;
+
+ if(Dom.hasClass(oRootNode, "checked")) {
+
+ p_oAttributes.checked = true;
+
+ }
+
+ if(Dom.hasClass(oRootNode, "disabled")) {
+
+ p_oAttributes.disabled = true;
+
+ }
+
+ p_oElement.removeAttribute("name");
+ p_oElement.removeAttribute("value");
+
+ p_oElement.setAttribute("type", "button");
+
+ break;
+
+ }
+
+}
+
+
+/**
+* @method initConfig
+* @description Initializes the set of configuration attributes that are used to
+* instantiate the button.
+* @private
+* @param {Object} Object representing the button's set of
+* configuration attributes.
+*/
+function initConfig(p_oConfig) {
+
+ var oAttributes = p_oConfig.attributes,
+ oSrcElement = oAttributes.srcelement,
+ sSrcElementTagName = oSrcElement.tagName.toUpperCase();
+
+
+ if(sSrcElementTagName == this.TAG_NAME) {
+
+ p_oConfig.element = oSrcElement;
+
+ var oFirstChild = getFirstElement(p_oConfig.element);
+
+ Dom.addClass(oFirstChild, "first-child");
+
+ if(oFirstChild) {
+
+ var oButton = getFirstElement(oFirstChild);
+
+
+ if(oButton) {
+
+ var sButtonTagName = oButton.tagName.toUpperCase();
+
+
+ if(sButtonTagName == "A" || sButtonTagName == "BUTTON") {
+
+ setAttributesFromSrcElement.call(
+ this,
+ oButton,
+ oAttributes
+ );
+
+ }
+
+ }
+
+ }
+
+ }
+ else if(sSrcElementTagName == "INPUT") {
+
+ setAttributesFromSrcElement.call(this, oSrcElement, oAttributes);
+
+ }
+
+}
+
+
+YAHOO.extend(YAHOO.widget.Button, YAHOO.util.Element, {
+
+
+// Protected properties
+
+
+/**
+* @property _button
+* @description Object reference to the button's internal
+* <a> or <button> element.
+* @default null
+* @protected
+* @type HTMLAnchorElement|HTMLButtonElement
+*/
+_button: null,
+
+
+/**
+* @property _menu
+* @description Object reference to the button's menu.
+* @default null
+* @protected
+* @type YAHOO.widget.Menu
+*/
+_menu: null,
+
+
+/**
+* @property _onclickAttributeValue
+* @description Object reference to the button's current value for the "onclick"
+* configuration attribute.
+* @default null
+* @protected
+* @type Object
+*/
+_onclickAttributeValue: null,
+
+
+/**
+* @property _oninitAttributeValue
+* @description Object reference to the button's current value for the "oninit"
+* configuration attribute.
+* @default null
+* @protected
+* @type Object
+*/
+_oninitAttributeValue: null,
+
+
+/**
+* @property _activationKeyPressed
+* @description Boolean indicating if the key(s) that toggle the button's
+* "active" state have been pressed.
+* @default false
+* @protected
+* @type Boolean
+*/
+_activationKeyPressed: false,
+
+
+/**
+* @property _activationButtonPressed
+* @description Boolean indicating if the mouse button that toggles the button's
+* "active" state has been pressed.
+* @default false
+* @protected
+* @type Boolean
+*/
+_activationButtonPressed: false,
+
+
+/**
+* @property _hasKeyEventHandlers
+* @description Boolean indicating if the button's "blur", "keydown" and
+* "keyup" event handlers are assigned
+* @default false
+* @protected
+* @type Boolean
+*/
+_hasKeyEventHandlers: false,
+
+
+/**
+* @property _hasMouseEventHandlers
+* @description Boolean indicating if the button's "mouseout" and "mousedown"
+* and "mouseup" event handlers are assigned
+* @default false
+* @protected
+* @type Boolean
+*/
+_hasMouseEventHandlers: false,
+
+
+
+// Constants
+
+
+/**
+* @property TAG_NAME
+* @description The name of the tag to be used for the button's root element.
+* @default "SPAN"
+* @final
+* @type String
+*/
+TAG_NAME: "SPAN",
+
+
+/**
+* @property CHECK_ACTIVATION_KEYS
+* @description Array of numbers representing keys that (when pressed) toggle
+* the button's "checked" attribute.
+* @default [32]
+* @final
+* @type Array
+*/
+CHECK_ACTIVATION_KEYS: [32],
+
+
+/**
+* @property ACTIVATION_KEYS
+* @description Array of numbers representing keys that (when presed) toggle
+* the button's "active" state.
+* @default [13, 32]
+* @final
+* @type Array
+*/
+ACTIVATION_KEYS: [13, 32],
+
+
+/**
+* @property OPTION_AREA_WIDTH
+* @description Width (in pixels) of the area of a split button that when
+* pressed will display a menu.
+* @default 20
+* @final
+* @type Number
+*/
+OPTION_AREA_WIDTH: 20,
+
+
+/**
+* @property CSS_CLASS_NAME
+* @description String representing the CSS class(es) to be applied to the
+* button's root element.
+* @default "yuibutton"
+* @final
+* @type String
+*/
+CSS_CLASS_NAME: "yuibutton",
+
+
+/**
+* @property RADIO_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "radio."
+* @default "Unchecked. Click to check."
+* @final
+* @type String
+*/
+RADIO_DEFAULT_TITLE: "Unchecked. Click to check.",
+
+
+/**
+* @property RADIO_CHECKED_TITLE
+* @description String representing the title applied to buttons of type "radio"
+* when checked.
+* @default "Checked. Click to uncheck."
+* @final
+* @type String
+*/
+RADIO_CHECKED_TITLE: "Checked. Click to uncheck.",
+
+
+/**
+* @property CHECKBOX_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "checkbox."
+* @default "Unchecked. Click to check."
+* @final
+* @type String
+*/
+CHECKBOX_DEFAULT_TITLE: "Unchecked. Click to check.",
+
+
+/**
+* @property CHECKBOX_CHECKED_TITLE
+* @description String representing the title applied to buttons of type
+* "checkbox" when checked.
+* @default "Checked. Click to uncheck."
+* @final
+* @type String
+*/
+CHECKBOX_CHECKED_TITLE: "Checked. Click to uncheck.",
+
+
+/**
+* @property MENUBUTTON_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "menubutton."
+* @default "Menu collapsed. Click to expand."
+* @final
+* @type String
+*/
+MENUBUTTON_DEFAULT_TITLE: "Menu collapsed. Click to expand.",
+
+
+/**
+* @property MENUBUTTON_MENU_VISIBLE_TITLE
+* @description String representing the title applied to buttons of type
+* "menubutton" when the button's menu is visible.
+* @default "Menu expanded. Click or press Esc to collapse."
+* @final
+* @type String
+*/
+MENUBUTTON_MENU_VISIBLE_TITLE:
+ "Menu expanded. Click or press Esc to collapse.",
+
+
+/**
+* @property SPLITBUTTON_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "splitebutton."
+* @default "Menu collapsed. Click inside option region or press
+* Ctrl + Shift + M to show the menu."
+* @final
+* @type String
+*/
+SPLITBUTTON_DEFAULT_TITLE:
+ "Menu collapsed. Click inside option region or press Ctrl + Shift + M to show the menu.",
+
+
+/**
+* @property SPLITBUTTON_OPTION_VISIBLE_TITLE
+* @description String representing the title applied to buttons of type
+* "splitbutton" when the button's menu is visible.
+* @default "Menu expanded. Press Esc or Ctrl + Shift + M to hide the menu."
+* @final
+* @type String
+*/
+SPLITBUTTON_OPTION_VISIBLE_TITLE:
+ "Menu expanded. Press Esc or Ctrl + Shift + M to hide the menu.",
+
+
+/**
+* @property SUBMIT_TITLE
+* @description String representing the title applied to buttons of
+* type "submit."
+* @default "Click to submit form."
+* @final
+* @type String
+*/
+SUBMIT_TITLE: "Click to submit form.",
+
+
+
+// Protected attribute setter methods
+
+
+/**
+* @method _setType
+* @description Sets the value of the button's "type" attribute.
+* @protected
+* @param {String} p_sType String indicating the value for the button's
+* "type" attribute.
+*/
+_setType: function(p_sType) {
+
+ if(p_sType == "splitbutton") {
+
+ this.on("option", this._onOption);
+
+ }
+
+},
+
+
+/**
+* @method _setLabel
+* @description Sets the value of the button's "label" attribute.
+* @protected
+* @param {String} p_sLabel String indicating the value for the button's
+* "label" attribute.
+*/
+_setLabel: function(p_sLabel) {
+
+ this._button.innerHTML = p_sLabel;
+
+},
+
+
+/**
+* @method _setTabIndex
+* @description Sets the value of the button's "tabindex" attribute.
+* @protected
+* @param {Number} p_nTabIndex Number indicating the value for the button's
+* "tabindex" attribute.
+*/
+_setTabIndex: function(p_nTabIndex) {
+
+ this._button.tabIndex = p_nTabIndex;
+
+},
+
+
+/**
+* @method _setTitle
+* @description Sets the value of the button's "title" attribute.
+* @protected
+* @param {String} p_nTabIndex Number indicating the value for the button's
+* "title" attribute.
+*/
+_setTitle: function(p_sTitle) {
+
+ if(this.get("type") != "link") {
+
+ var sTitle = p_sTitle;
+
+ if(!sTitle) {
+
+
+ var sType = this.get("type");
+
+ switch(sType) {
+
+ case "radio":
+
+ sTitle = this.RADIO_DEFAULT_TITLE;
+
+ break;
+
+ case "checkbox":
+
+ sTitle = this.CHECKBOX_DEFAULT_TITLE;
+
+ break;
+
+ case "menubutton":
+
+ sTitle = this.MENUBUTTON_DEFAULT_TITLE;
+
+ break;
+
+ case "splitbutton":
+
+ sTitle = this.SPLITBUTTON_DEFAULT_TITLE;
+
+ break;
+
+ case "submit":
+
+ sTitle = this.SUBMIT_TITLE;
+
+ break;
+
+ }
+
+ }
+
+ this._button.title = sTitle;
+
+ }
+
+},
+
+
+/**
+* @method _setDisabled
+* @description Sets the value of the button's "disabled" attribute.
+* @protected
+* @param {Boolean} p_bDisabled Boolean indicating the value for the button's
+* "disabled" attribute.
+*/
+_setDisabled: function(p_bDisabled) {
+
+ if(this.get("type") != "link") {
+
+ if(p_bDisabled) {
+
+ if(this.hasFocus()) {
+
+ this.blur();
+
+ }
+
+ this._button.setAttribute("disabled", "disabled");
+
+ this.addClass("disabled");
+
+ }
+ else {
+
+ this._button.removeAttribute("disabled");
+
+ this.removeClass("disabled");
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _setAccessKey
+* @description Sets the value of the button's "accesskey" attribute.
+* @protected
+* @param {String} p_sAccessKey String indicating the value for the button's
+* "accesskey" attribute.
+*/
+_setAccessKey: function(p_sAccessKey) {
+
+ this._button.accessKey = p_sAccessKey;
+
+},
+
+
+/**
+* @method _setHref
+* @description Sets the value of the button's "href" attribute.
+* @protected
+* @param {String} p_sHref String indicating the value for the button's
+* "href" attribute.
+*/
+_setHref: function(p_sHref) {
+
+ if(this.get("type") == "link") {
+
+ this._button.href = p_sHref;
+
+ }
+
+},
+
+
+/**
+* @method _setTarget
+* @description Sets the value of the button's "target" attribute.
+* @protected
+* @param {String} p_sTarget String indicating the value for the button's
+* "target" attribute.
+*/
+_setTarget: function(p_sTarget) {
+
+ if(this.get("type") == "link") {
+
+ this._button.setAttribute("target", p_sTarget);
+
+ }
+
+},
+
+
+/**
+* @method _setChecked
+* @description Sets the value of the button's "target" attribute.
+* @protected
+* @param {Boolean} p_bChecked Boolean indicating the value for the button's
+* "checked" attribute.
+*/
+_setChecked: function(p_bChecked) {
+
+ var sType = this.get("type"),
+ sTitle;
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ if(p_bChecked) {
+
+ this.addClass("checked");
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_CHECKED_TITLE :
+ this.CHECKBOX_CHECKED_TITLE;
+
+ }
+ else {
+
+ this.removeClass("checked");
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_DEFAULT_TITLE :
+ this.CHECKBOX_DEFAULT_TITLE;
+
+ }
+
+ this.set("title", sTitle);
+
+ }
+
+},
+
+
+/**
+* @method _setMenu
+* @description Sets the value of the button's "menu" attribute.
+* @protected
+* @param {Object} p_oMenu Object indicating the value for the button's
+* "menu" attribute.
+*/
+_setMenu: function(p_oMenu) {
+
+ var Menu = YAHOO.widget.Menu,
+ oMenu,
+ me = this;
+
+ if(!Menu) {
+
+ this.logger.log("YAHOO.widget.Menu dependency not met.", "error");
+
+ return false;
+
+ }
+
+
+ function initMenu() {
+
+ if(oMenu) {
+
+ oMenu.showEvent.subscribe(this._onMenuShow, this, true);
+ oMenu.hideEvent.subscribe(this._onMenuHide, this, true);
+ oMenu.keyDownEvent.subscribe(this._onMenuKeyDown, this, true);
+ oMenu.renderEvent.subscribe(this._onMenuRender, this, true);
+ oMenu.clickEvent.subscribe(this._onMenuClick, this, true);
+ oMenu.itemAddedEvent.subscribe(this._onMenuItemAdded, this, true);
+
+ var oSrcElement = oMenu.srcElement;
+
+ if(oSrcElement && oSrcElement.tagName.toUpperCase() == "SELECT") {
+
+ oSrcElement.style.display = "none";
+ oSrcElement.parentNode.removeChild(oSrcElement);
+
+ }
+
+ this._menu = oMenu;
+
+ }
+ else {
+
+ this._menu.destroy();
+ this._menu = null;
+
+ }
+
+ }
+
+
+ if(p_oMenu instanceof Menu) {
+
+ oMenu = p_oMenu;
+
+ var aItems = oMenu.getItems(),
+ nItems = aItems.length,
+ oItem;
+
+ if(nItems > 0) {
+
+ var i = nItems - 1;
+
+ do {
+
+ oItem = aItems[i];
+
+ if(oItem) {
+
+ oItem.cfg.subscribeToConfigEvent(
+ "selected",
+ this._onMenuItemSelected,
+ oItem,
+ this
+ );
+
+ }
+
+ }
+ while(i--);
+
+ }
+
+ initMenu.call(this);
+
+ }
+ else if(Lang.isArray(p_oMenu)) {
+
+ this.on("appendTo", function() {
+
+ oMenu = new Menu(
+ Dom.generateId(),
+ { lazyload: true, itemdata: p_oMenu }
+ );
+
+ initMenu.call(me);
+
+ });
+
+ }
+ else if(Lang.isString(p_oMenu)) {
+
+ Event.onContentReady(p_oMenu, function() {
+
+ oMenu = new Menu(this, { lazyload: true });
+
+ initMenu.call(me);
+
+ });
+
+ }
+ else if(p_oMenu && p_oMenu.nodeName) {
+
+ oMenu = new Menu(p_oMenu, { lazyload: true });
+
+ initMenu.call(this);
+
+ }
+
+},
+
+
+/**
+* @method _setOnClick
+* @description Sets the value of the button's "onclick" attribute.
+* @protected
+* @param {Object} p_oObject Object indicating the value for the button's
+* "onclick" attribute.
+*/
+_setOnClick: function(p_oObject) {
+
+ /*
+ Remove any existing listeners if a "click" event handler has already
+ been specified.
+ */
+
+ if(
+ this._onclickAttributeValue &&
+ (this._onclickAttributeValue != p_oObject)
+ ) {
+
+ this.removeListener("click", this._onclickAttributeValue.fn);
+
+ this._onclickAttributeValue = null;
+
+ }
+
+
+ if(
+ !this._onclickAttributeValue &&
+ Lang.isObject(p_oObject) &&
+ Lang.isFunction(p_oObject.fn)
+ ) {
+
+ this.on("click", p_oObject.fn, p_oObject.obj, p_oObject.scope);
+
+ this._onclickAttributeValue = p_oObject;
+
+ }
+
+},
+
+/**
+* @method _setOnInit
+* @description Sets the value of the button's "init" attribute.
+* @protected
+* @param {Object} p_oObject Object indicating the value for the button's
+* "oninit" attribute.
+*/
+_setOnInit: function(p_oObject) {
+
+ /*
+ Remove any existing listeners if a "init" event handler has already
+ been specified.
+ */
+
+ if(
+ this._oninitAttributeValue &&
+ (this._oninitAttributeValue != p_oObject)
+ ) {
+
+ this.removeListener("init", this._oninitAttributeValue.fn);
+
+ this._oninitAttributeValue = null;
+
+ }
+
+
+ if(
+ !this._oninitAttributeValue &&
+ Lang.isObject(p_oObject) &&
+ Lang.isFunction(p_oObject.fn)
+ ) {
+
+ this.on("init", p_oObject.fn, p_oObject.obj, p_oObject.scope);
+
+ this._oninitAttributeValue = p_oObject;
+
+ }
+
+},
+
+
+
+// Protected methods
+
+
+/**
+* @method _createButtonElement
+* @description Creates the button's element.
+* @protected
+* @param {String} p_sType String indicating the type of element to create.
+* @return {HTMLElement}
+*/
+_createButtonElement: function(p_sType) {
+
+ var sTagName = this.TAG_NAME,
+ oElement = document.createElement(sTagName);
+
+ oElement.innerHTML =
+
+ "<" + sTagName + " class=\"first-child\">" +
+ (p_sType == "link" ? "" : "") +
+ "" + sTagName + ">";
+
+ return oElement;
+
+},
+
+
+/**
+* @method _isActivationKey
+* @description Determines if the specified keycode is one that toggles the
+* button's "active" state.
+* @protected
+* @param {Number} p_nKeyCode Number representing the keycode to be evaluated.
+* @return {Boolean}
+*/
+_isActivationKey: function(p_nKeyCode) {
+
+ var sType = this.get("type"),
+ aKeyCodes = (sType == "checkbox" || sType == "radio") ?
+ this.CHECK_ACTIVATION_KEYS : this.ACTIVATION_KEYS,
+
+ nKeyCodes = aKeyCodes.length;
+
+ if(nKeyCodes > 0) {
+
+ var i = nKeyCodes - 1;
+
+ do {
+
+ if(p_nKeyCode == aKeyCodes[i]) {
+
+ return true;
+
+ }
+
+ }
+ while(i--);
+
+ }
+
+},
+
+
+/**
+* @method _isSplitButtonOptionKey
+* @description Determines if the specified keycode is one that toggles the
+* display of the split button's menu.
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @return {Boolean}
+*/
+_isSplitButtonOptionKey: function(p_oEvent) {
+
+ return (
+ p_oEvent.ctrlKey &&
+ p_oEvent.shiftKey &&
+ Event.getCharCode(p_oEvent) == 77
+ );
+
+},
+
+
+_originalMaxHeight: -1,
+
+
+/**
+* @method _showMenu
+* @description Shows the button's menu.
+* @protected
+*/
+_showMenu: function() {
+
+ var oMenu = this._menu;
+
+ if(oMenu) {
+
+ YAHOO.widget.MenuManager.hideVisible();
+
+ oMenu.cfg.applyConfig({
+ context:[this.get("id"), "tl", "bl"],
+ clicktohide: false,
+ constraintoviewport: false,
+ visible: true
+ });
+
+ oMenu.cfg.fireQueue();
+
+ var nViewportHeight = Dom.getViewportHeight(),
+ nMenuHeight = oMenu.element.offsetHeight;
+
+
+ if((oMenu.cfg.getProperty("y") + nMenuHeight) > nViewportHeight) {
+
+ this.logger.log("Current menu position will place a portion, or " +
+ "the entire menu outside the boundary of the viewport. " +
+ "Repositioning the menu to stay inside the viewport.");
+
+ oMenu.align("bl", "tl");
+
+ var nY = oMenu.cfg.getProperty("y"),
+
+ nScrollTop = (
+ document.documentElement.scrollTop ||
+ document.body.scrollTop
+ );
+
+
+ if(nScrollTop >= nY) {
+
+ if(this._originalMaxHeight == -1) {
+
+ this._originalMaxHeight =
+ oMenu.cfg.getProperty("maxheight");
+
+ }
+
+ oMenu.cfg.setProperty(
+ "maxheight",
+ (nMenuHeight - ((nScrollTop - nY) + 20))
+ );
+
+ oMenu.align("bl", "tl");
+
+ }
+
+ }
+
+ oMenu.cfg.setProperty("constraintoviewport", true);
+
+ }
+
+},
+
+
+/**
+* @method _hideMenu
+* @description Hides the button's menu.
+* @protected
+*/
+_hideMenu: function() {
+
+ var oMenu = this._menu;
+
+ if(oMenu && oMenu.cfg.getProperty("visible")) {
+
+ oMenu.hide();
+
+ }
+
+},
+
+
+/**
+* @method _submitForm
+* @description Submits the form to which the button belongs.
+* @protected
+*/
+_submitForm: function() {
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ YAHOO.widget.Button.addHiddenFieldsToForm(oForm);
+
+ this.createHiddenField();
+
+ oForm.submit();
+
+ }
+
+},
+
+
+
+// Protected event handlers
+
+
+/**
+* @method _onMouseOver
+* @description "mouseover" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseOver: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+ if(!this._hasMouseEventHandlers) {
+
+ this.on("mouseout", this._onMouseOut);
+ this.on("mousedown", this._onMouseDown);
+ this.on("mouseup", this._onMouseUp);
+
+ this._hasMouseEventHandlers = true;
+
+ }
+
+ this.addClass("hover");
+
+ if(this._activationButtonPressed) {
+
+ this.addClass("active");
+
+ }
+
+
+ if(this._bOptionPressed) {
+
+ this.addClass("activeoption");
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onMouseOut
+* @description "mouseout" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseOut: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+ this.removeClass("hover");
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ if(this._activationButtonPressed || this._bOptionPressed) {
+
+ Event.on(document, "mouseup", this._onDocumentMouseUp, this, true);
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onDocumentMouseUp
+* @description "mouseup" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onDocumentMouseUp: function(p_oEvent, p_oButton) {
+
+ this._activationButtonPressed = false;
+ this._bOptionPressed = false;
+
+ var sType = this.get("type");
+
+ if(sType == "menubutton" || sType == "splitbutton") {
+
+ this.removeClass((sType == "menubutton" ? "active" : "activeoption"));
+
+ this._hideMenu();
+
+ }
+
+ Event.removeListener(document, "mouseup", this._onDocumentMouseUp);
+
+},
+
+
+/**
+* @method _onMouseDown
+* @description "mousedown" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseDown: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+ if((p_oEvent.which || p_oEvent.button) == 1) {
+
+ if(!this.hasFocus()) {
+
+ this.focus();
+
+ }
+
+
+ var sType = this.get("type");
+
+
+ if(sType == "splitbutton") {
+
+ var oElement = this.get("element"),
+ nX = Event.getPageX(p_oEvent) - Dom.getX(oElement);
+
+ if((oElement.offsetWidth - this.OPTION_AREA_WIDTH) < nX) {
+
+ this.fireEvent("option", p_oEvent);
+
+ }
+ else {
+
+ this.addClass("active");
+
+ this._activationButtonPressed = true;
+
+ }
+
+ }
+ else if(sType == "menubutton") {
+
+ if(this.hasClass("active")) {
+
+ this._hideMenu();
+
+ this._activationButtonPressed = false;
+
+ }
+ else {
+
+ this._showMenu();
+
+ this._activationButtonPressed = true;
+
+ }
+
+ }
+ else {
+
+ this.addClass("active");
+
+ this._activationButtonPressed = true;
+
+ }
+
+
+
+ if(sType == "splitbutton" || sType == "menubutton") {
+
+ var me = this;
+
+
+ function onMouseUp() {
+
+ me._hideMenu();
+ me.removeListener("mouseup", onMouseUp);
+
+ }
+
+
+ this._hideMenuTimerId = window.setTimeout(function() {
+
+ me.on("mouseup", onMouseUp);
+
+ }, 250);
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onMouseUp
+* @description "mouseup" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseUp: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+
+ if(this._hideMenuTimerId) {
+
+ window.clearTimeout(this._hideMenuTimerId);
+
+ }
+
+ var sType = this.get("type");
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ this.set("checked", !(this.get("checked")));
+
+ }
+
+
+ this._activationButtonPressed = false;
+
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onFocus
+* @description "focus" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button that
+* fired the event.
+*/
+_onFocus: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ this.addClass("focus");
+
+ if(this._activationKeyPressed) {
+
+ this.addClass("active");
+
+ }
+
+ m_oFocusedButton = this;
+
+
+ if(!this._hasKeyEventHandlers) {
+
+ var oElement = this._button;
+
+ Event.on(oElement, "blur", this._onBlur, this, true);
+ Event.on(oElement, "keydown", this._onKeyDown, this, true);
+ Event.on(oElement, "keyup", this._onKeyUp, this, true);
+
+ this._hasKeyEventHandlers = true;
+
+ }
+
+
+ this.fireEvent("focus", p_oEvent);
+
+ }
+
+},
+
+
+/**
+* @method _onBlur
+* @description "blur" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onBlur: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ this.removeClass("focus");
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ if(this._activationKeyPressed) {
+
+ Event.on(document, "keyup", this._onDocumentKeyUp, this, true);
+
+ }
+
+
+ m_oFocusedButton = null;
+
+ this.fireEvent("blur", p_oEvent);
+
+ }
+
+},
+
+
+/**
+* @method _onDocumentKeyUp
+* @description "keyup" event handler for the document.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onDocumentKeyUp: function(p_oEvent, p_oButton) {
+
+ if(this._isActivationKey(Event.getCharCode(p_oEvent))) {
+
+ this._activationKeyPressed = false;
+
+ Event.removeListener(document, "keyup", this._onDocumentKeyUp);
+
+ }
+
+},
+
+
+/**
+* @method _onKeyDown
+* @description "keydown" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onKeyDown: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ if(
+ this.get("type") == "splitbutton" &&
+ this._isSplitButtonOptionKey(p_oEvent)
+ ) {
+
+ this.fireEvent("option", p_oEvent);
+
+ }
+ else if(this._isActivationKey(Event.getCharCode(p_oEvent))) {
+
+ if(this.get("type") == "menubutton") {
+
+ this._showMenu();
+
+ }
+ else {
+
+ this._activationKeyPressed = true;
+
+ this.addClass("active");
+
+ }
+
+ }
+
+
+ var oMenu = this._menu;
+
+ if(
+ oMenu && oMenu.cfg.getProperty("visible") &&
+ Event.getCharCode(p_oEvent) == 27
+ ) {
+
+ oMenu.hide();
+ this.focus();
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onKeyUp
+* @description "keyup" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onKeyUp: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ if(this._isActivationKey(Event.getCharCode(p_oEvent))) {
+
+ var sType = this.get("type");
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ this.set("checked", !(this.get("checked")));
+
+ }
+
+ this._activationKeyPressed = false;
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onClick
+* @description "click" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onClick: function(p_oEvent) {
+
+ var sType = this.get("type"),
+ sTitle;
+
+ switch(sType) {
+
+ case "radio":
+ case "checkbox":
+
+ if(this.get("checked")) {
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_CHECKED_TITLE :
+ this.CHECKBOX_CHECKED_TITLE;
+
+ }
+ else {
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_DEFAULT_TITLE :
+ this.CHECKBOX_DEFAULT_TITLE;
+
+ }
+
+ this.set("title", sTitle);
+
+ break;
+
+ case "submit":
+
+ this._submitForm();
+
+ break;
+
+ case "reset":
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ oForm.reset();
+
+ }
+
+ break;
+
+ case "menubutton":
+
+ sTitle = this._menu.cfg.getProperty("visible") ?
+ this.MENUBUTTON_MENU_VISIBLE_TITLE :
+ this.MENUBUTTON_DEFAULT_TITLE;
+
+ this.set("title", sTitle);
+
+ break;
+
+ case "splitbutton":
+
+ var oElement = this.get("element"),
+ nX = Event.getPageX(p_oEvent) - Dom.getX(oElement);
+
+ if((oElement.offsetWidth - this.OPTION_AREA_WIDTH) < nX) {
+
+ return false;
+
+ }
+ else {
+
+ this._hideMenu();
+
+ var oSrcElement = this.get("srcelement");
+
+ if(oSrcElement && oSrcElement.type == "submit") {
+
+ this._submitForm();
+
+ }
+
+ }
+
+ sTitle = this._menu.cfg.getProperty("visible") ?
+ this.SPLITBUTTON_OPTION_VISIBLE_TITLE :
+ this.SPLITBUTTON_DEFAULT_TITLE;
+
+ this.set("title", sTitle);
+
+ break;
+
+ }
+
+},
+
+
+/**
+* @method _onAppendTo
+* @description "appendTo" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onAppendTo: function(p_oEvent) {
+
+ /*
+ It is necessary to call "getForm" using "setTimeout" to make sure that
+ the button's "form" property returns a node reference. Sometimes, if
+ you try to get the reference immediately after appending the field, it
+ is null.
+ */
+
+ var me = this;
+
+ window.setTimeout(function() {
+
+ var oForm = me.getForm();
+
+ if(oForm) {
+
+ Event.on(oForm, "reset", me._onFormReset, me, true);
+ Event.on(oForm, "submit", me._onFormSubmit, me, true);
+
+ }
+
+ }, 0);
+
+},
+
+
+/**
+* @method _onFormSubmit
+* @description "submit" event handler for the button's form.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onFormSubmit: function(p_oEvent, p_oButton) {
+
+ var sType = this.get("type"),
+ oMenuItem = this.get("selectedMenuItem"),
+ oForm = this.getForm();
+
+
+ if(sType == "radio" || sType == "checkbox") {
+
+ YAHOO.log("Creating hidden field for button: " + this);
+
+ this.createHiddenField();
+
+ }
+ else if(oMenuItem) {
+
+ var oSrcElement = this._menu.srcElement;
+
+ if(oSrcElement && oSrcElement.tagName.toUpperCase() == "SELECT") {
+
+ oForm.appendChild(oSrcElement);
+ oSrcElement.selectedIndex = oMenuItem.index;
+
+ }
+ else {
+
+ var oValue = (oMenuItem.value === null || oMenuItem.value === "") ?
+ oMenuItem.cfg.getProperty("text") :
+ oMenuItem.value;
+
+
+ if(oValue) {
+
+ var oField = createInputElement(
+ "hidden",
+ (this.get("name") + "_options"),
+ oValue
+ );
+
+ oForm.appendChild(oField);
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onFormReset
+* @description "reset" event handler for the button's form.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onFormReset: function(p_oEvent, p_oButton) {
+
+ var sType = this.get("type");
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ this.resetValue("checked");
+
+ }
+
+ if(this._menu) {
+
+ this.resetValue("selectedMenuItem");
+
+ }
+
+},
+
+
+/**
+* @method _onDocumentMouseDown
+* @description "mousedown" event handler for the document.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onDocumentMouseDown: function(p_oEvent, p_oButton) {
+
+ var oTarget = Event.getTarget(p_oEvent),
+ oButtonElement = this.get("element"),
+ oMenuElement = this._menu.element;
+
+ if(
+ oTarget != oButtonElement &&
+ !Dom.isAncestor(oButtonElement, oTarget) &&
+ oTarget != oMenuElement &&
+ !Dom.isAncestor(oMenuElement, oTarget)
+ ) {
+
+ this._hideMenu();
+
+ Event.removeListener(
+ document,
+ "mousedown",
+ this._onDocumentMouseDown
+ );
+
+ }
+
+},
+
+
+/**
+* @method _onOption
+* @description "option" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onOption: function(p_oEvent) {
+
+ if(this.hasClass("activeoption")) {
+
+ this._hideMenu();
+
+ this._bOptionPressed = false;
+
+ }
+ else {
+
+ this._showMenu();
+
+ this._bOptionPressed = true;
+
+ }
+
+},
+
+
+/**
+* @method _onMenuShow
+* @description "show" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuShow: function(p_sType, p_aArgs, p_oButton) {
+
+ Event.on(document, "mousedown", this._onDocumentMouseDown, this, true);
+
+ var sTitle,
+ sClass;
+
+ if(this.get("type") == "splitbutton") {
+
+ sTitle = this.SPLITBUTTON_OPTION_VISIBLE_TITLE;
+ sClass = "activeoption";
+
+ }
+ else {
+
+ sTitle = this.MENUBUTTON_MENU_VISIBLE_TITLE;
+ sClass = "active";
+
+ }
+
+ this.addClass(sClass);
+ this.set("title", sTitle);
+
+},
+
+
+/**
+* @method _onMenuHide
+* @description "hide" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuHide: function(p_sType, p_aArgs, p_oButton) {
+
+ if(this._originalMaxHeight != -1) {
+
+ this._menu.cfg.setProperty("maxheight", this._originalMaxHeight);
+
+ }
+
+
+ var sTitle,
+ sClass;
+
+ if(this.get("type") == "splitbutton") {
+
+ sTitle = this.SPLITBUTTON_DEFAULT_TITLE;
+ sClass = "activeoption";
+
+ }
+ else {
+
+ sTitle = this.MENUBUTTON_DEFAULT_TITLE;
+ sClass = "active";
+ }
+
+
+ this.removeClass(sClass);
+ this.set("title", sTitle);
+
+},
+
+
+/**
+* @method _onMenuKeyDown
+* @description "keydown" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuKeyDown: function(p_sType, p_aArgs, p_oButton) {
+
+ var oEvent = p_aArgs[0];
+
+ if(Event.getCharCode(oEvent) == 27) {
+
+ this.focus();
+
+ if(this.get("type") == "splitbutton") {
+
+ this._bOptionPressed = false;
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onMenuRender
+* @description "render" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuRender: function(p_sType, p_aArgs, p_oButton) {
+
+ this.get("element").parentNode.appendChild(this._menu.element);
+
+},
+
+
+/**
+* @method _onMenuItemSelected
+* @description "selectedchange" event handler for each item in the
+* button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.MenuItem}
+* p_oItem Object representing the menu item that subscribed to the event.
+*/
+_onMenuItemSelected: function(p_sType, p_aArgs, p_oItem) {
+
+ this.set("selectedMenuItem", p_oItem);
+
+},
+
+
+/**
+* @method _onMenuItemAdded
+* @description "itemadded" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.MenuItem}
+* p_oItem Object representing the menu item that subscribed to the event.
+*/
+_onMenuItemAdded: function(p_sType, p_aArgs, p_oItem) {
+
+ var oItem = p_aArgs[0];
+
+ oItem.cfg.subscribeToConfigEvent(
+ "selected",
+ this._onMenuItemSelected,
+ oItem,
+ this
+ );
+
+},
+
+
+/**
+* @method _onMenuClick
+* @description "click" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the menu's button.
+*/
+_onMenuClick: function(p_sType, p_aArgs, p_oButton) {
+
+ var oItem = p_aArgs[0];
+
+ if(oItem) {
+
+ var oSrcElement = this.get("srcelement");
+
+ if(oSrcElement && oSrcElement.type == "submit") {
+
+ this._submitForm();
+
+ }
+
+ this._hideMenu();
+
+ }
+
+},
+
+
+
+// Public methods
+
+
+/**
+* @method createHiddenField
+* @description Creates the button's hidden form field and appends it to its
+* parent form.
+* @return {HTMLInputElement}
+*/
+createHiddenField: function () {
+
+ if(!this.get("disabled")) {
+
+ var sType = this.get("type"),
+
+ bCheckable = (sType == "checkbox" || sType == "radio"),
+
+ oField = createInputElement(
+ (bCheckable ? this.get("type") : "hidden"),
+ this.get("name"),
+ this.get("value"),
+ this.get("checked")
+ ),
+
+ oForm = this.getForm();
+
+
+ if(oField && bCheckable) {
+
+ oField.style.display = "none";
+
+ }
+
+
+ if(oForm) {
+
+ oForm.appendChild(oField);
+
+ }
+
+
+ return oField;
+
+ }
+
+},
+
+
+/**
+* @method init
+* @description The Button class's initialization method.
+* @param {String} p_oElement String specifying the id attribute of the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {HTMLInputElement|HTMLElement} p_oElement Object reference for the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {Object} p_oElement Object literal specifying a set of configuration
+* attributes used to create the button.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button.
+*/
+init: function(p_oElement, p_oAttributes) {
+
+ var sTagName = p_oAttributes.type == "link" ? "A" : "BUTTON",
+ oSrcElement = p_oAttributes.srcelement;
+
+
+ this._button = p_oElement.getElementsByTagName(sTagName)[0];
+
+
+ YAHOO.widget.Button.superclass.init.call(
+ this, p_oElement,
+ p_oAttributes
+ );
+
+
+ m_oButtons[this.get("id")] = this;
+
+
+ this.addClass(this.CSS_CLASS_NAME);
+ this.addClass(this.get("type"));
+
+ Event.on(this._button, "focus", this._onFocus, this, true);
+ this.on("mouseover", this._onMouseOver);
+ this.on("click", this._onClick);
+ this.on("appendTo", this._onAppendTo);
+
+ var oContainer = this.get("container"),
+ oElement = this.get("element");
+
+
+ if(oContainer) {
+
+ if(Lang.isString(oContainer)) {
+
+ var me = this;
+
+ Event.onContentReady(oContainer, function() {
+
+ me.appendTo(this);
+
+ });
+
+ }
+ else {
+
+ this.appendTo(oContainer);
+
+ }
+
+ }
+ else if(
+ !Dom.inDocument(oElement) &&
+ oSrcElement &&
+ oSrcElement.tagName.toUpperCase() == "INPUT"
+ ) {
+
+ var oParentNode = oSrcElement.parentNode;
+
+ if(oParentNode) {
+
+ this.fireEvent("beforeAppendTo", {
+ type: "beforeAppendTo",
+ target: oParentNode
+ });
+
+ oParentNode.replaceChild(oElement, oSrcElement);
+
+ this.fireEvent("appendTo", {
+ type: "appendTo",
+ target: oParentNode
+ });
+
+ }
+
+ }
+ else if(
+ Dom.inDocument(oElement) &&
+ oSrcElement.tagName.toUpperCase() == "SPAN"
+ ) {
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ Event.on(oForm, "reset", this._onFormReset, this, true);
+ Event.on(oForm, "submit", this._onFormSubmit, this, true);
+
+ }
+
+ }
+
+ this.fireEvent("init");
+
+ this.logger.log("Initialization completed.");
+
+},
+
+
+/**
+* @method initAttributes
+* @description Initializes all of the configuration attributes used to create
+* the button.
+* @param {Object} p_oAttributes Object literal specifying a set of
+* configuration attributes used to create the button.
+*/
+initAttributes: function(p_oAttributes) {
+
+ var oAttributes = p_oAttributes || {};
+
+ YAHOO.widget.Button.superclass.initAttributes.call(this, oAttributes);
+
+
+ /**
+ * @config type
+ * @description String specifying the button's type. Possible values are:
+ * "button," "link," "submit," "reset," "checkbox," "radio," "menubutton,"
+ * and "splitbutton."
+ * @default "button"
+ * @type String
+ */
+ this.setAttributeConfig("type", {
+
+ value: (oAttributes.type || "button"),
+ validator: Lang.isString,
+ writeOnce: true,
+ method: this._setType
+
+ });
+
+
+ /**
+ * @config label
+ * @description String specifying the button's text label or innerHTML.
+ * @default null
+ * @type String
+ */
+ this.setAttributeConfig("label", {
+
+ value: oAttributes.label,
+ validator: Lang.isString,
+ method: this._setLabel
+
+ });
+
+
+ /**
+ * @config value
+ * @description Object specifying the value for the button.
+ * @default null
+ * @type Object
+ */
+ this.setAttributeConfig("value", {
+
+ value: oAttributes.value
+
+ });
+
+
+ /**
+ * @config name
+ * @description String specifying the name for the button.
+ * @default null
+ * @type String
+ */
+ this.setAttributeConfig("name", {
+
+ value: oAttributes.name,
+ validator: Lang.isString
+
+ });
+
+
+ /**
+ * @config tabindex
+ * @description Number specifying the tabindex for the button.
+ * @default null
+ * @type Number
+ */
+ this.setAttributeConfig("tabindex", {
+
+ value: oAttributes.tabindex,
+ validator: Lang.isNumber,
+ method: this._setTabIndex
+
+ });
+
+
+ /**
+ * @config title
+ * @description String specifying the title for the button.
+ * @default null
+ * @type String
+ */
+ this.configureAttribute("title", {
+
+ value: oAttributes.title,
+ validator: Lang.isString,
+ method: this._setTitle
+
+ });
+
+
+ /**
+ * @config disabled
+ * @description Boolean indicating if the button should be disabled.
+ * (Disabled buttons are dimmed and will not respond to user input
+ * or fire events.)
+ * @default false
+ * @type Boolean
+ */
+ this.setAttributeConfig("disabled", {
+
+ value: (oAttributes.disabled || false),
+ validator: Lang.isBoolean,
+ method: this._setDisabled
+
+ });
+
+
+ /**
+ * @config href
+ * @description String specifying the href for the button. Applies only to
+ * buttons of type "link."
+ * @type String
+ */
+ this.setAttributeConfig("href", {
+
+ value: oAttributes.href,
+ validator: Lang.isString,
+ method: this._setHref
+
+ });
+
+
+ /**
+ * @config target
+ * @description String specifying the target for the button. Applies only
+ * to buttons of type "link."
+ * @type String
+ */
+ this.setAttributeConfig("target", {
+
+ value: oAttributes.target,
+ validator: Lang.isString,
+ method: this._setTarget
+
+ });
+
+
+ /**
+ * @config checked
+ * @description Boolean indicating if the button is checked. Applies only
+ * to buttons of type "radio" and "checkbox."
+ * @default false
+ * @type Boolean
+ */
+ this.setAttributeConfig("checked", {
+
+ value: (oAttributes.checked || false),
+ validator: Lang.isBoolean,
+ method: this._setChecked
+
+ });
+
+
+ /**
+ * @config container
+ * @description HTML element reference or string specifying the id
+ * attribute of the HTML element that the button's markup should be
+ * rendered into.
+ * @type HTMLElement|String
+ * @default null
+ */
+ this.setAttributeConfig("container", {
+
+ value: oAttributes.container
+
+ });
+
+
+ /**
+ * @config srcelement
+ * @description Object reference to the HTML element (either
+ * <input> or <span>) used to
+ * create the button.
+ * @type HTMLElement|String
+ * @default null
+ */
+ this.setAttributeConfig("srcelement", {
+
+ value: oAttributes.srcelement,
+ writeOnce: true
+
+ });
+
+
+ /**
+ * @config menu
+ * @description Object specifying the menu for the button. The value can be
+ * one of the following:
+ *
String specifying the id attribute of the <div>
+ * element used to create the menu.
+ *
String specifying the id attribute of the
+ * <select> element used to create the menu.
+ *
Object specifying the <div> element used to
+ * create the menu.
+ *
Object specifying the <select> element used to
+ * create the menu.
+ *
Array of object literals, each representing a set of
+ * YAHOO.widget.MenuItem
+ * configuration attributes.
+ *
Array of strings representing the text labels for each menu item in
+ * the menu.
+ *
+ * @type HTMLElement|String|Array
+ * @default null
+ */
+ this.setAttributeConfig("menu", {
+
+ value: null,
+ method: this._setMenu
+
+ });
+
+
+ /**
+ * @config selectedMenuItem
+ * @description Reference to the item in the button's menu that is
+ * currently selected.
+ * @type YAHOO.widget.MenuItem
+ * @default null
+ */
+ this.setAttributeConfig("selectedMenuItem", {
+
+ value: null
+
+ });
+
+
+ /**
+ * @config onclick
+ * @description Object literal representing the code to be executed when
+ * the button is clicked. Format: {
+ * fn: Function, // The handler to call when the
+ * event fires. obj: Object, // An object to
+ * pass back to the handler. scope: Object //
+ * The object to use for the scope of the handler. }
+ * @type Object
+ * @default null
+ */
+ this.setAttributeConfig("onclick", {
+
+ value: oAttributes.onclick,
+ method: this._setOnClick
+
+ });
+
+
+ /**
+ * @config oninit
+ * @description Object literal representing the code to be executed when
+ * the button is initialized. Format: {
+ * fn: Function, // The handler to call when the
+ * event fires. obj: Object, // An object to
+ * pass back to the handler. scope: Object //
+ * The object to use for the scope of the handler. }
+ * @type Object
+ * @default null
+ */
+ this.setAttributeConfig("oninit", {
+
+ value: oAttributes.oninit,
+ method: this._setOnInit
+
+ });
+
+},
+
+
+/**
+* @method focus
+* @description Causes the button to receive the focus and fires the button's
+* "focus" event.
+*/
+focus: function() {
+
+ if(!this.get("disabled")) {
+
+ this._button.focus();
+
+ }
+
+},
+
+
+/**
+* @method blur
+* @description Causes the button to lose focus and fires the button's
+* "blur" event.
+*/
+blur: function() {
+
+ if(!this.get("disabled")) {
+
+ this._button.blur();
+
+ }
+
+},
+
+
+/**
+* @method hasFocus
+* @description Returns a boolean indicating whether or not the button has focus.
+* @return {Boolean}
+*/
+hasFocus: function() {
+
+ return (m_oFocusedButton == this);
+
+},
+
+
+/**
+* @method isActive
+* @description Returns a boolean indicating whether or not the button is active.
+* @return {Boolean}
+*/
+isActive: function() {
+
+ return this.hasClass("active");
+
+},
+
+
+/**
+* @method getMenu
+* @description Returns a reference to the button's menu.
+* @return {YAHOO.widget.Menu}
+*/
+getMenu: function() {
+
+ return this._menu;
+
+},
+
+
+/**
+* @method getForm
+* @description Returns a reference to the button's menu.
+* @return {HTMLFormElement}
+*/
+getForm: function() {
+
+ return this._button.form;
+
+},
+
+
+/**
+* @method destroy
+* @description Removes the button's element from its parent element and
+* removes all event handlers.
+*/
+destroy: function() {
+
+ this.logger.log("Destroying ...");
+
+ var oElement = this.get("element"),
+ oParentNode = oElement.parentNode,
+ oMenu = this._menu;
+
+ if(oMenu) {
+
+ this.logger.log("Destroying menu.");
+
+ oMenu.destroy();
+
+ }
+
+ this.logger.log("Removing DOM event handlers.");
+
+ Event.purgeElement(oElement);
+ Event.purgeElement(this._button);
+ Event.removeListener(document, "mouseup", this._onDocumentMouseUp);
+ Event.removeListener(document, "keyup", this._onDocumentKeyUp);
+ Event.removeListener(document, "mousedown", this._onDocumentMouseDown);
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ Event.removeListener(oForm, "reset", this._onFormReset);
+
+ }
+
+
+ oParentNode.removeChild(oElement);
+
+ this.logger.log("Removing from document.");
+
+ delete m_oButtons[this.get("id")];
+
+ this.logger.log("Destroyed.");
+
+},
+
+
+/**
+* @method toString
+* @description Returns a string representing the button.
+* @return {String}
+*/
+toString: function() {
+
+ return ("Button " + this.get("id"));
+
+}
+
+});
+
+
+/**
+* @method addHiddenFieldsToForm
+* @description Searches the specified form and adds hidden fields for instances
+* of YAHOO.widget.Button that are of type "radio," "checkbox," "menubutton,"
+* and "splitbutton."
+* @param {HTMLFormElement} p_oForm Object reference
+* for the form to search.
+*/
+YAHOO.widget.Button.addHiddenFieldsToForm = function(p_oForm) {
+
+ var aButtons = Dom.getElementsByClassName("yuibutton", "*", p_oForm),
+ nButtons = aButtons.length;
+
+
+ if(nButtons > 0) {
+
+ YAHOO.log("Form contains " + nButtons + " YUI buttons.");
+
+ var oButton = null,
+ sType = null,
+ oMenuItem = null,
+ oMenu = null;
+
+ for(var i=0; iElement.addListener for more
+* information on listening for this event.
+* @type YAHOO.util.CustomEvent
+*/
+
+
+/**
+* @event blur
+* @description Fires when the menu item loses the input focus. Passes back a
+* single object representing the original DOM event object passed back by the
+* event utility (YAHOO.util.Event) when the event was fired. See Element.addListener for more
+* information on listening for this event.
+* @type YAHOO.util.CustomEvent
+*/
+
+
+/**
+* @event option
+* @description Fires when the user invokes the button's option. Passes back a
+* single object representing the original DOM event (either "mousedown" or
+* "keydown") that caused the "option" event to fire. See Element.addListener for more
+* information on listening for this event.
+* @type YAHOO.util.CustomEvent
+*/
+
+
+/**
+* @event init
+* @description Fires when the Button is initialized. Subscribe to this event
+* by specifying a value for the "oninit" configuration attribute. Format:
+* { fn: Function, // The handler to call
+* when the event fires. obj: Object, // An object
+* to pass back to the handler. scope: Object //
+* The object to use for the scope of the handler. }
+* @type YAHOO.util.CustomEvent
+*/
+
+})();
+(function() {
+
+// Shorthard for utilities
+
+var Dom = YAHOO.util.Dom,
+ Event = YAHOO.util.Event,
+ Lang = YAHOO.lang,
+ Button = YAHOO.widget.Button;
+
+ // Private collection of radio buttons
+
+ m_oButtons = {};
+
+
+
+/**
+* The ButtonGroup class creates a set of buttons that are mutually exclusive;
+* checking one button in the set will uncheck all others in the button group.
+* @param {String} p_oElement String specifying the id attribute of the
+* <div> element of the button group.
+* @param {HTMLDivElement} p_oElement Object
+* specifying the <div> element of the button group.
+* @param {Object} p_oElement Object literal specifying a set of
+* configuration attributes used to create the button group.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button group.
+* @namespace YAHOO.widget
+* @class ButtonGroup
+* @constructor
+* @extends YAHOO.util.Element
+*/
+YAHOO.widget.ButtonGroup = function(p_oElement, p_oAttributes) {
+
+ var fnSuperClass = YAHOO.widget.ButtonGroup.superclass.constructor;
+
+ if(
+ arguments.length == 1 &&
+ !Lang.isString(p_oElement) &&
+ !p_oElement.nodeName
+ ) {
+
+ if(!p_oElement.id) {
+
+ var sId = Dom.generateId();
+
+ p_oElement.id = sId;
+
+ YAHOO.log(
+ "No value specified for the button group's \"id\" attribute. " +
+ "Setting button group id to \"" + sId + "\".",
+ "warn"
+ );
+
+ }
+
+ this.logger = new YAHOO.widget.LogWriter("ButtonGroup " + sId);
+
+ this.logger.log(
+ "No source HTML element. " +
+ "Building the button group using the set of " +
+ "configuration attributes."
+ );
+
+ fnSuperClass.call(this, (this._createGroupElement()), p_oElement);
+
+ }
+ else if(Lang.isString(p_oElement)) {
+
+ var me = this;
+
+ Event.onContentReady(p_oElement, function() {
+
+ if(this.nodeName.toUpperCase() == me.TAG_NAME) {
+
+ me.logger =
+ new YAHOO.widget.LogWriter("ButtonGroup " + p_oElement);
+
+ fnSuperClass.call(me, this, p_oAttributes);
+
+ }
+
+ });
+
+ }
+ else {
+
+ var sNodeName = p_oElement.nodeName;
+
+ if(sNodeName && sNodeName == this.TAG_NAME) {
+
+ if(!p_oElement.id) {
+
+ p_oElement.id = Dom.generateId();
+
+ YAHOO.log(
+ "No value specified for the button group's \"id\" " +
+ "attribute. Setting button group id " +
+ "to \"" + p_oElement.id + "\".",
+ "warn"
+ );
+
+ }
+
+ this.logger =
+ new YAHOO.widget.LogWriter("ButtonGroup " + p_oElement.id);
+
+ fnSuperClass.call(this, p_oElement, p_oAttributes);
+
+ }
+
+ }
+
+};
+
+
+YAHOO.extend(YAHOO.widget.ButtonGroup, YAHOO.util.Element, {
+
+
+// Protected properties
+
+
+/**
+* @property _buttons
+* @description Array of buttons in the button group.
+* @default null
+* @protected
+* @type Array
+*/
+_buttons: null,
+
+
+/**
+* @property _oninitAttributeValue
+* @description Object reference to the button group's current value for the
+* "oninit" configuration attribute.
+* @default null
+* @protected
+* @type Object
+*/
+_oninitAttributeValue: null,
+
+
+
+// Constants
+
+
+/**
+* @property TAG_NAME
+* @description The name of the tag to be used for the button group's element.
+* @default "DIV"
+* @final
+* @type String
+*/
+TAG_NAME: "DIV",
+
+
+/**
+* @property CSS_CLASS_NAME
+* @description String representing the CSS class(es) to be applied to the
+* button group's element.
+* @default "yuibuttongroup"
+* @final
+* @type String
+*/
+CSS_CLASS_NAME: "yuibuttongroup",
+
+
+
+// Protected methods
+
+
+/**
+* @method _createGroupElement
+* @description Creates the button group's element.
+* @protected
+* @return {HTMLDivElement}
+*/
+_createGroupElement: function() {
+
+ var oElement = document.createElement(this.TAG_NAME);
+
+ oElement.className = this.CSS_CLASS_NAME;
+
+ return oElement;
+
+},
+
+
+
+// Protected attribute setter methods
+
+
+/**
+* @method _setDisabled
+* @description Sets the value of the button groups's "disabled" attribute.
+* @protected
+* @param {Boolean} p_bDisabled Boolean indicating the value for the button
+* group's "disabled" attribute.
+*/
+_setDisabled: function(p_bDisabled) {
+
+ var nButtons = this.getCount();
+
+ if(nButtons > 0) {
+
+ var i = nButtons - 1;
+
+ do {
+
+ this._buttons[i].set("disabled", p_bDisabled);
+
+ }
+ while(i--);
+
+ }
+
+},
+
+
+/**
+* @method _setOnInit
+* @description Sets the value of the button group's "init" attribute.
+* @protected
+* @param {Object} p_oObject Object indicating the value for the button's
+* "oninit" attribute.
+*/
+_setOnInit: function(p_oObject) {
+
+ /*
+ Remove any existing listeners if a "init" event handler has already
+ been specified.
+ */
+
+ if(
+ this._oninitAttributeValue &&
+ (this._oninitAttributeValue != p_oObject)
+ ) {
+
+ this.removeListener("init", this._oninitAttributeValue.fn);
+
+ this._oninitAttributeValue = null;
+
+ }
+
+
+ if(
+ !this._oninitAttributeValue &&
+ Lang.isObject(p_oObject) &&
+ Lang.isFunction(p_oObject.fn)
+ ) {
+
+ this.on("init", p_oObject.fn, p_oObject.obj, p_oObject.scope);
+
+ this._oninitAttributeValue = p_oObject;
+
+ }
+
+},
+
+
+// Protected event handlers
+
+
+/**
+* @method _onKeyDown
+* @description "keydown" event handler for the button group.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onKeyDown: function(p_oEvent) {
+
+ var oTarget = Event.getTarget(p_oEvent),
+ nCharCode = Event.getCharCode(p_oEvent),
+ sId = oTarget.parentNode.parentNode.id,
+ oButton = m_oButtons[sId],
+ nIndex = -1;
+
+
+ if(nCharCode == 37 || nCharCode == 38) {
+
+ nIndex = (oButton.index === 0) ?
+ (this._buttons.length -1) : (oButton.index - 1);
+
+ }
+ else if(nCharCode == 39 || nCharCode == 40) {
+
+ nIndex = (oButton.index === (this._buttons.length - 1)) ?
+ 0 : (oButton.index + 1);
+
+ }
+
+
+ if(nIndex > -1) {
+
+ this.check(nIndex);
+ this.getButton(nIndex).focus();
+
+ }
+
+},
+
+
+/**
+* @method _onAppendTo
+* @description "appendTo" event handler for the button group.
+* @protected
+* @param {Event} p_oEvent Object representing the event that was fired.
+*/
+_onAppendTo: function(p_oEvent) {
+
+ var aButtons = this._buttons,
+ nButtons = aButtons.length;
+
+ for(var i=0; iYAHOO.widget.Button} p_oButton
+* Object representing the button that
+* fired the event.
+*/
+_onButtonCheckedChange: function(p_oEvent, p_oButton) {
+
+ var bChecked = p_oEvent.newValue,
+ oCheckedButton = this.get("checkedButton");
+
+ if(bChecked && oCheckedButton != p_oButton) {
+
+ if(oCheckedButton) {
+
+ oCheckedButton.set("checked", false, true);
+
+ }
+
+ this.set("checkedButton", p_oButton);
+ this.set("value", p_oButton.get("value"));
+
+ }
+ else if(oCheckedButton && !oCheckedButton.set("checked")) {
+
+ oCheckedButton.set("checked", true, true);
+
+ }
+
+},
+
+
+
+// Public methods
+
+
+/**
+* @method init
+* @description The ButtonGroup class's initialization method.
+* @param {String} p_oElement String specifying the id attribute of the
+* <div> element of the button group.
+* @param {HTMLDivElement} p_oElement Object
+* specifying the <div> element of the button group.
+* @param {Object} p_oElement Object literal specifying a set of configuration
+* attributes used to create the button group.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button group.
+*/
+init: function(p_oElement, p_oAttributes) {
+
+ this._buttons = [];
+
+ YAHOO.widget.ButtonGroup.superclass.init.call(
+ this, p_oElement,
+ p_oAttributes
+ );
+
+
+ this.logger.log(
+ "Searching for child nodes with the class name " +
+ "\"yuibutton\" to add to the button group."
+ );
+
+ var aButtons = this.getElementsByClassName("yuibutton");
+
+
+ if(aButtons.length > 0) {
+
+ this.logger.log(
+ "Found " + aButtons.length + " child nodes with the class " +
+ "name \"yuibutton.\" Attempting to add to button group."
+ );
+
+ this.addButtons(aButtons);
+
+ }
+
+
+ this.logger.log(
+ "Searching for child nodes with the type of \"radio\" to add to the " +
+ " button group."
+ );
+
+ function isRadioButton(p_oElement) {
+
+ return (p_oElement.type == "radio");
+
+ }
+
+ aButtons = Dom.getElementsBy(isRadioButton, "input", this.get("element"));
+
+
+ if(aButtons.length > 0) {
+
+ this.logger.log(
+ "Found " + aButtons.length + " child nodes with the type of " +
+ "\"radio.\" Attempting to add to button group."
+ );
+
+ this.addButtons(aButtons);
+
+ }
+
+ this.on("keydown", this._onKeyDown);
+ this.on("appendTo", this._onAppendTo);
+
+ var oContainer = this.get("container");
+
+ if(oContainer) {
+
+ if(Lang.isString(oContainer)) {
+
+ var me = this;
+
+ Event.onContentReady(oContainer, function() {
+
+ me.appendTo(this);
+
+ });
+
+ }
+ else {
+
+ this.appendTo(oContainer);
+
+ }
+
+ }
+
+
+ this.fireEvent("init");
+
+ this.logger.log("Initialization completed.");
+
+},
+
+
+/**
+* @method initAttributes
+* @description Initializes all of the configuration attributes used to create
+* the button group.
+* @param {Object} p_oAttributes Object literal specifying a set of
+* configuration attributes used to create the button group.
+*/
+initAttributes: function(p_oAttributes) {
+
+ var oAttributes = p_oAttributes || {};
+
+ YAHOO.widget.ButtonGroup.superclass.initAttributes.call(
+ this,
+ oAttributes
+ );
+
+
+ /**
+ * @config name
+ * @description String specifying the name for the button group. This
+ * name will be applied to each button in the button group.
+ * @default null
+ * @type String
+ */
+ this.setAttributeConfig("name", {
+
+ value: oAttributes.name,
+ validator: Lang.isString
+
+ });
+
+
+ /**
+ * @config disabled
+ * @description Boolean indicating if the button group should be disabled.
+ * Disabling the button group will disable each button in the button group.
+ * Disabled buttons are dimmed and will not respond to user input
+ * or fire events.
+ * @default false
+ * @type Boolean
+ */
+ this.setAttributeConfig("disabled", {
+
+ value: (oAttributes.disabled || false),
+ validator: Lang.isBoolean,
+ method: this._setDisabled
+
+ });
+
+
+ /**
+ * @config value
+ * @description Object specifying the value for the button group.
+ * @default null
+ * @type Object
+ */
+ this.setAttributeConfig("value", {
+
+ value: oAttributes.value
+
+ });
+
+
+ /**
+ * @config container
+ * @description HTML element reference or string specifying the id
+ * attribute of the HTML element that the button group's markup should be
+ * rendered into.
+ * @type HTMLElement|String
+ * @default null
+ */
+ this.setAttributeConfig("container", {
+
+ value: oAttributes.container
+
+ });
+
+
+ /**
+ * @config checkedButton
+ * @description Reference for the button in the button group that
+ * is checked.
+ * @type {YAHOO.widget.Button}
+ * @default null
+ */
+ this.setAttributeConfig("checkedButton", {
+
+ value: null
+
+ });
+
+
+ /**
+ * @config oninit
+ * @description Object literal representing the code to be executed when
+ * the button group is initialized. Format: {
+ * fn: Function, // The handler to call when the
+ * event fires. obj: Object, // An object to
+ * pass back to the handler. scope: Object //
+ * The object to use for the scope of the handler. }
+ * @type Object
+ * @default null
+ */
+ this.setAttributeConfig("oninit", {
+
+ value: oAttributes.oninit,
+ method: this._setOnInit
+
+ });
+
+},
+
+
+/**
+* @method addButton
+* @description Adds the button to the button group.
+* @param {YAHOO.widget.Button} p_oButton
+* Object reference for the
+* YAHOO.widget.Button instance to be added to the button group.
+* @param {String} p_oButton String specifying the id attribute of the
+* <input> or <span> element to be
+* used to create the button to be added to the button group.
+* @param {HTMLInputElement|HTMLElement} p_oButton Object reference for the
+* <input> or <span> element to be
+* used to create the button to be added to the button group.
+* @param {Object} p_oButton Object literal specifying a set of
+* YAHOO.widget.Button configuration
+* attributes used to configure the button to be added to the button group.
+* @return {YAHOO.widget.Button}
+*/
+addButton: function(p_oButton) {
+
+ var oButton;
+
+
+ if(p_oButton instanceof Button && p_oButton.get("type") == "radio") {
+
+ oButton = p_oButton;
+
+ }
+ else if(!Lang.isString(p_oButton) && !p_oButton.nodeName) {
+
+ p_oButton.type = "radio";
+
+ oButton = new Button(p_oButton);
+
+ }
+ else {
+
+ oButton = new Button(p_oButton, { type: "radio" });
+
+ }
+
+
+ if(oButton) {
+
+ var nIndex = this._buttons.length,
+ sButtonName = oButton.get("name"),
+ sGroupName = this.get("name");
+
+ oButton.index = nIndex;
+
+ this._buttons[nIndex] = oButton;
+ m_oButtons[oButton.get("id")] = oButton;
+
+
+ if(sButtonName != sGroupName) {
+
+ oButton.set("name", sGroupName);
+
+ }
+
+
+ if(this.get("disabled")) {
+
+ oButton.set("disabled", true);
+
+ }
+
+
+ if(oButton.get("checked")) {
+
+ this.set("checkedButton", oButton);
+
+ }
+
+
+ oButton.on("checkedChange", this._onButtonCheckedChange, oButton, this);
+
+ this.logger.log("Button " + oButton.get("id") + " added.");
+
+ return oButton;
+
+ }
+
+},
+
+
+/**
+* @method addButtons
+* @description Adds the array of buttons to the button group.
+* @param {Array} p_aButtons Array of
+* YAHOO.widget.Button instances to be added
+* to the button group.
+* @param {Array} p_aButtons Array of strings specifying the id attribute of
+* the <input> or <span> elements to
+* be used to create the buttons to be added to the button group.
+* @param {Array} p_aButtons Array of object references for the
+* <input> or <span> elements to be
+* used to create the buttons to be added to the button group.
+* @param {Array} p_aButtons Array of object literals, each containing a set of
+* YAHOO.widget.Button configuration
+* attributes used to configure each button to be added to the button group.
+* @return {Array}
+*/
+addButtons: function(p_aButtons) {
+
+ if(Lang.isArray(p_aButtons)) {
+
+ var nButtons = p_aButtons.length,
+ oButton,
+ aButtons = [];
+
+ if(nButtons > 0) {
+
+ for(var i=0; i 0) {
+
+ this.logger.log(aButtons.length + " buttons added.");
+
+ return aButtons;
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method removeButton
+* @description Removes the button at the specified index from the button group.
+* @param {Number} p_nIndex Number specifying the index of the button to be
+* removed from the button group.
+*/
+removeButton: function(p_nIndex) {
+
+ var oButton = this.getButton(p_nIndex);
+
+ if(oButton) {
+
+ this.logger.log("Removing button " + oButton.get("id") + ".");
+
+ this._buttons.splice(p_nIndex, 1);
+ delete m_oButtons[oButton.get("id")];
+
+ oButton.removeListener("checkedChange", this._onButtonCheckedChange);
+ oButton.destroy();
+
+
+ var nButtons = this._buttons.length;
+
+ if(nButtons > 0) {
+
+ var i = this._buttons.length - 1;
+
+ do {
+
+ this._buttons[i].index = i;
+
+ }
+ while(i--);
+
+ }
+
+ this.logger.log("Button " + oButton.get("id") + " removed.");
+
+ }
+
+},
+
+
+/**
+* @method getButton
+* @description Returns the button at the specified index.
+* @param {Number} p_nIndex The index of the button to retrieve from the
+* button group.
+* @return {YAHOO.widget.Button}
+*/
+getButton: function(p_nIndex) {
+
+ if(Lang.isNumber(p_nIndex)) {
+
+ return this._buttons[p_nIndex];
+
+ }
+
+},
+
+
+/**
+* @method getButtons
+* @description Returns an array of the buttons in the button group.
+* @return {Array}
+*/
+getButtons: function() {
+
+ return this._buttons;
+
+},
+
+
+/**
+* @method getCount
+* @description Returns the number of buttons in the button group.
+* @return {Number}
+*/
+getCount: function() {
+
+ return this._buttons.length;
+
+},
+
+
+/**
+* @method focus
+* @description Sets focus to the button at the specified index.
+* @param {Number} p_nIndex Number indicating the index of the button to focus.
+*/
+focus: function(p_nIndex) {
+
+ var oButton;
+
+ if(Lang.isNumber(p_nIndex)) {
+
+ oButton = this._buttons[p_nIndex];
+
+ if(oButton) {
+
+ oButton.focus();
+
+ }
+
+ }
+ else {
+
+ var nButtons = this.getCount();
+
+ for(var i=0; i 0) {
+
+ var i = this._buttons.length - 1;
+
+ do {
+
+ this._buttons[i].destroy();
+
+ }
+ while(i--);
+
+ }
+
+ this.logger.log("Removing DOM event handlers.");
+
+ Event.purgeElement(oElement);
+
+ this.logger.log("Removing from document.");
+
+ oParentNode.removeChild(oElement);
+
+},
+
+
+/**
+* @method toString
+* @description Returns a string representing the button group.
+* @return {String}
+*/
+toString: function() {
+
+ return ("ButtonGroup " + this.get("id"));
+
+}
+
+});
+
+
+
+// Events
+
+
+/**
+* @event init
+* @description Fires when the button group is initialized. Subscribe to this
+* event by specifying a value for the "oninit" configuration attribute.
+* Format: { fn: Function, // The
+* handler to call when the event fires. obj: Object,
+* // An object to pass back to the handler. scope:
+* Object // The object to use for the scope of the handler.
+* }
+* @type YAHOO.util.CustomEvent
+*/
+
+})();
+YAHOO.register("button", YAHOO.widget.Button, {version: "2.2.0", build: "127"});
diff --git a/interface/ispconfig/interface/js/yui/button/button-beta-min.js b/interface/ispconfig/interface/js/yui/button/button-beta-min.js
new file mode 100644
index 0000000000000000000000000000000000000000..617ec785dd26d3b1e09c5420fc4303fd72f31539
--- /dev/null
+++ b/interface/ispconfig/interface/js/yui/button/button-beta-min.js
@@ -0,0 +1,126 @@
+/*
+Copyright (c) 2007, Yahoo! Inc. All rights reserved.
+Code licensed under the BSD License:
+http://developer.yahoo.net/yui/license.txt
+version: 2.2.0
+*/
+
+(function(){var Dom=YAHOO.util.Dom,Event=YAHOO.util.Event,Lang=YAHOO.lang,m_oButtons={},m_oFocusedButton=null;YAHOO.widget.Button=function(p_oElement,p_oAttributes){var fnSuperClass=YAHOO.widget.Button.superclass.constructor;if(arguments.length==1&&!Lang.isString(p_oElement)&&!p_oElement.nodeName){if(!p_oElement.id){p_oElement.id=Dom.generateId();}
+fnSuperClass.call(this,(this._createButtonElement(p_oElement.type)),p_oElement);}
+else{var oConfig={element:null,attributes:(p_oAttributes||{})};if(Lang.isString(p_oElement)){var me=this;Event.onAvailable(p_oElement,function(){var sTagName=this.tagName.toUpperCase();if(sTagName==me.TAG_NAME){oConfig.attributes.id=this.id;}
+else if(sTagName=="INPUT"&&!oConfig.attributes.id){oConfig.attributes.id=Dom.generateId();}
+oConfig.attributes.srcelement=this;initConfig.call(me,oConfig);if(!oConfig.element){oConfig.element=me._createButtonElement(oConfig.attributes.type);}
+fnSuperClass.call(me,oConfig.element,oConfig.attributes);});}
+else{var sTagName=p_oElement.tagName.toUpperCase();if(sTagName==this.TAG_NAME){if(p_oElement.id){oConfig.attributes.id=p_oElement.id;}
+else{oConfig.attributes.id=Dom.generateId();}}
+else if(sTagName=="INPUT"&&!oConfig.attributes.id){oConfig.attributes.id=Dom.generateId();}
+oConfig.attributes.srcelement=p_oElement;initConfig.call(this,oConfig);if(!oConfig.element){oConfig.element=this._createButtonElement(oConfig.attributes.type);}
+fnSuperClass.call(this,oConfig.element,oConfig.attributes);}}};function getFirstElement(p_oElement){var oFirstChild=p_oElement.firstChild;if(oFirstChild){if(oFirstChild.nodeType==1){return oFirstChild;}
+else{var oNextSibling=oFirstChild.nextSibling;if(oNextSibling&&oNextSibling.nodeType==1){return oNextSibling;}}}}
+function createInputElement(p_sType,p_sName,p_sValue,p_bChecked){var oInput;if(navigator.userAgent.indexOf("MSIE")!=-1){var sInput="";oInput=document.createElement(sInput);}
+else{oInput=document.createElement("input");oInput.name=p_sName;oInput.type=p_sType;if(p_bChecked){oInput.checked=true;}}
+oInput.value=p_sValue;return oInput;}
+function setAttributesFromSrcElement(p_oElement,p_oAttributes){var me=this;function setAttributeFromDOMAttribute(p_sAttribute){if(!(p_sAttribute in p_oAttributes)){var oAttribute=p_oElement.getAttributeNode(p_sAttribute);if(oAttribute&&("value"in oAttribute)){p_oAttributes[p_sAttribute]=oAttribute.value;}}}
+function setFormElementProperties(){setAttributeFromDOMAttribute("type");if(!("disabled"in p_oAttributes)){p_oAttributes.disabled=p_oElement.disabled;}
+setAttributeFromDOMAttribute("name");setAttributeFromDOMAttribute("value");setAttributeFromDOMAttribute("title");}
+var sSrcElementTagName=p_oElement.tagName.toUpperCase();if(!("label"in p_oAttributes)){var sText=sSrcElementTagName=="INPUT"?p_oElement.value:p_oElement.innerHTML;if(sText&&sText.length>0){p_oAttributes.label=sText;}}
+setAttributeFromDOMAttribute("tabindex");setAttributeFromDOMAttribute("accesskey");switch(sSrcElementTagName){case"A":p_oAttributes.type="link";setAttributeFromDOMAttribute("href");setAttributeFromDOMAttribute("target");break;case"INPUT":setFormElementProperties();if(!("checked"in p_oAttributes)){p_oAttributes.checked=p_oElement.checked;}
+break;case"BUTTON":setFormElementProperties();var oRootNode=p_oElement.parentNode.parentNode;if(Dom.hasClass(oRootNode,"checked")){p_oAttributes.checked=true;}
+if(Dom.hasClass(oRootNode,"disabled")){p_oAttributes.disabled=true;}
+p_oElement.removeAttribute("name");p_oElement.removeAttribute("value");p_oElement.setAttribute("type","button");break;}}
+function initConfig(p_oConfig){var oAttributes=p_oConfig.attributes,oSrcElement=oAttributes.srcelement,sSrcElementTagName=oSrcElement.tagName.toUpperCase();if(sSrcElementTagName==this.TAG_NAME){p_oConfig.element=oSrcElement;var oFirstChild=getFirstElement(p_oConfig.element);Dom.addClass(oFirstChild,"first-child");if(oFirstChild){var oButton=getFirstElement(oFirstChild);if(oButton){var sButtonTagName=oButton.tagName.toUpperCase();if(sButtonTagName=="A"||sButtonTagName=="BUTTON"){setAttributesFromSrcElement.call(this,oButton,oAttributes);}}}}
+else if(sSrcElementTagName=="INPUT"){setAttributesFromSrcElement.call(this,oSrcElement,oAttributes);}}
+YAHOO.extend(YAHOO.widget.Button,YAHOO.util.Element,{_button:null,_menu:null,_onclickAttributeValue:null,_oninitAttributeValue:null,_activationKeyPressed:false,_activationButtonPressed:false,_hasKeyEventHandlers:false,_hasMouseEventHandlers:false,TAG_NAME:"SPAN",CHECK_ACTIVATION_KEYS:[32],ACTIVATION_KEYS:[13,32],OPTION_AREA_WIDTH:20,CSS_CLASS_NAME:"yuibutton",RADIO_DEFAULT_TITLE:"Unchecked. Click to check.",RADIO_CHECKED_TITLE:"Checked. Click to uncheck.",CHECKBOX_DEFAULT_TITLE:"Unchecked. Click to check.",CHECKBOX_CHECKED_TITLE:"Checked. Click to uncheck.",MENUBUTTON_DEFAULT_TITLE:"Menu collapsed. Click to expand.",MENUBUTTON_MENU_VISIBLE_TITLE:"Menu expanded. Click or press Esc to collapse.",SPLITBUTTON_DEFAULT_TITLE:"Menu collapsed. Click inside option region or press Ctrl + Shift + M to show the menu.",SPLITBUTTON_OPTION_VISIBLE_TITLE:"Menu expanded. Press Esc or Ctrl + Shift + M to hide the menu.",SUBMIT_TITLE:"Click to submit form.",_setType:function(p_sType){if(p_sType=="splitbutton"){this.on("option",this._onOption);}},_setLabel:function(p_sLabel){this._button.innerHTML=p_sLabel;},_setTabIndex:function(p_nTabIndex){this._button.tabIndex=p_nTabIndex;},_setTitle:function(p_sTitle){if(this.get("type")!="link"){var sTitle=p_sTitle;if(!sTitle){var sType=this.get("type");switch(sType){case"radio":sTitle=this.RADIO_DEFAULT_TITLE;break;case"checkbox":sTitle=this.CHECKBOX_DEFAULT_TITLE;break;case"menubutton":sTitle=this.MENUBUTTON_DEFAULT_TITLE;break;case"splitbutton":sTitle=this.SPLITBUTTON_DEFAULT_TITLE;break;case"submit":sTitle=this.SUBMIT_TITLE;break;}}
+this._button.title=sTitle;}},_setDisabled:function(p_bDisabled){if(this.get("type")!="link"){if(p_bDisabled){if(this.hasFocus()){this.blur();}
+this._button.setAttribute("disabled","disabled");this.addClass("disabled");}
+else{this._button.removeAttribute("disabled");this.removeClass("disabled");}}},_setAccessKey:function(p_sAccessKey){this._button.accessKey=p_sAccessKey;},_setHref:function(p_sHref){if(this.get("type")=="link"){this._button.href=p_sHref;}},_setTarget:function(p_sTarget){if(this.get("type")=="link"){this._button.setAttribute("target",p_sTarget);}},_setChecked:function(p_bChecked){var sType=this.get("type"),sTitle;if(sType=="checkbox"||sType=="radio"){if(p_bChecked){this.addClass("checked");sTitle=(sType=="radio")?this.RADIO_CHECKED_TITLE:this.CHECKBOX_CHECKED_TITLE;}
+else{this.removeClass("checked");sTitle=(sType=="radio")?this.RADIO_DEFAULT_TITLE:this.CHECKBOX_DEFAULT_TITLE;}
+this.set("title",sTitle);}},_setMenu:function(p_oMenu){var Menu=YAHOO.widget.Menu,oMenu,me=this;if(!Menu){return false;}
+function initMenu(){if(oMenu){oMenu.showEvent.subscribe(this._onMenuShow,this,true);oMenu.hideEvent.subscribe(this._onMenuHide,this,true);oMenu.keyDownEvent.subscribe(this._onMenuKeyDown,this,true);oMenu.renderEvent.subscribe(this._onMenuRender,this,true);oMenu.clickEvent.subscribe(this._onMenuClick,this,true);oMenu.itemAddedEvent.subscribe(this._onMenuItemAdded,this,true);var oSrcElement=oMenu.srcElement;if(oSrcElement&&oSrcElement.tagName.toUpperCase()=="SELECT"){oSrcElement.style.display="none";oSrcElement.parentNode.removeChild(oSrcElement);}
+this._menu=oMenu;}
+else{this._menu.destroy();this._menu=null;}}
+if(p_oMenu instanceof Menu){oMenu=p_oMenu;var aItems=oMenu.getItems(),nItems=aItems.length,oItem;if(nItems>0){var i=nItems-1;do{oItem=aItems[i];if(oItem){oItem.cfg.subscribeToConfigEvent("selected",this._onMenuItemSelected,oItem,this);}}
+while(i--);}
+initMenu.call(this);}
+else if(Lang.isArray(p_oMenu)){this.on("appendTo",function(){oMenu=new Menu(Dom.generateId(),{lazyload:true,itemdata:p_oMenu});initMenu.call(me);});}
+else if(Lang.isString(p_oMenu)){Event.onContentReady(p_oMenu,function(){oMenu=new Menu(this,{lazyload:true});initMenu.call(me);});}
+else if(p_oMenu&&p_oMenu.nodeName){oMenu=new Menu(p_oMenu,{lazyload:true});initMenu.call(this);}},_setOnClick:function(p_oObject){if(this._onclickAttributeValue&&(this._onclickAttributeValue!=p_oObject)){this.removeListener("click",this._onclickAttributeValue.fn);this._onclickAttributeValue=null;}
+if(!this._onclickAttributeValue&&Lang.isObject(p_oObject)&&Lang.isFunction(p_oObject.fn)){this.on("click",p_oObject.fn,p_oObject.obj,p_oObject.scope);this._onclickAttributeValue=p_oObject;}},_setOnInit:function(p_oObject){if(this._oninitAttributeValue&&(this._oninitAttributeValue!=p_oObject)){this.removeListener("init",this._oninitAttributeValue.fn);this._oninitAttributeValue=null;}
+if(!this._oninitAttributeValue&&Lang.isObject(p_oObject)&&Lang.isFunction(p_oObject.fn)){this.on("init",p_oObject.fn,p_oObject.obj,p_oObject.scope);this._oninitAttributeValue=p_oObject;}},_createButtonElement:function(p_sType){var sTagName=this.TAG_NAME,oElement=document.createElement(sTagName);oElement.innerHTML="<"+sTagName+" class=\"first-child\">"+
+(p_sType=="link"?"":"")+""+sTagName+">";return oElement;},_isActivationKey:function(p_nKeyCode){var sType=this.get("type"),aKeyCodes=(sType=="checkbox"||sType=="radio")?this.CHECK_ACTIVATION_KEYS:this.ACTIVATION_KEYS,nKeyCodes=aKeyCodes.length;if(nKeyCodes>0){var i=nKeyCodes-1;do{if(p_nKeyCode==aKeyCodes[i]){return true;}}
+while(i--);}},_isSplitButtonOptionKey:function(p_oEvent){return(p_oEvent.ctrlKey&&p_oEvent.shiftKey&&Event.getCharCode(p_oEvent)==77);},_originalMaxHeight:-1,_showMenu:function(){var oMenu=this._menu;if(oMenu){YAHOO.widget.MenuManager.hideVisible();oMenu.cfg.applyConfig({context:[this.get("id"),"tl","bl"],clicktohide:false,constraintoviewport:false,visible:true});oMenu.cfg.fireQueue();var nViewportHeight=Dom.getViewportHeight(),nMenuHeight=oMenu.element.offsetHeight;if((oMenu.cfg.getProperty("y")+nMenuHeight)>nViewportHeight){oMenu.align("bl","tl");var nY=oMenu.cfg.getProperty("y"),nScrollTop=(document.documentElement.scrollTop||document.body.scrollTop);if(nScrollTop>=nY){if(this._originalMaxHeight==-1){this._originalMaxHeight=oMenu.cfg.getProperty("maxheight");}
+oMenu.cfg.setProperty("maxheight",(nMenuHeight-((nScrollTop-nY)+20)));oMenu.align("bl","tl");}}
+oMenu.cfg.setProperty("constraintoviewport",true);}},_hideMenu:function(){var oMenu=this._menu;if(oMenu&&oMenu.cfg.getProperty("visible")){oMenu.hide();}},_submitForm:function(){var oForm=this.getForm();if(oForm){YAHOO.widget.Button.addHiddenFieldsToForm(oForm);this.createHiddenField();oForm.submit();}},_onMouseOver:function(p_oEvent){if(!this.get("disabled")){if(!this._hasMouseEventHandlers){this.on("mouseout",this._onMouseOut);this.on("mousedown",this._onMouseDown);this.on("mouseup",this._onMouseUp);this._hasMouseEventHandlers=true;}
+this.addClass("hover");if(this._activationButtonPressed){this.addClass("active");}
+if(this._bOptionPressed){this.addClass("activeoption");}}},_onMouseOut:function(p_oEvent){if(!this.get("disabled")){this.removeClass("hover");if(this.get("type")!="menubutton"){this.removeClass("active");}
+if(this._activationButtonPressed||this._bOptionPressed){Event.on(document,"mouseup",this._onDocumentMouseUp,this,true);}}},_onDocumentMouseUp:function(p_oEvent,p_oButton){this._activationButtonPressed=false;this._bOptionPressed=false;var sType=this.get("type");if(sType=="menubutton"||sType=="splitbutton"){this.removeClass((sType=="menubutton"?"active":"activeoption"));this._hideMenu();}
+Event.removeListener(document,"mouseup",this._onDocumentMouseUp);},_onMouseDown:function(p_oEvent){if(!this.get("disabled")){if((p_oEvent.which||p_oEvent.button)==1){if(!this.hasFocus()){this.focus();}
+var sType=this.get("type");if(sType=="splitbutton"){var oElement=this.get("element"),nX=Event.getPageX(p_oEvent)-Dom.getX(oElement);if((oElement.offsetWidth-this.OPTION_AREA_WIDTH)0){var oButton=null,sType=null,oMenuItem=null,oMenu=null;for(var i=0;i0){var i=nButtons-1;do{this._buttons[i].set("disabled",p_bDisabled);}
+while(i--);}},_setOnInit:function(p_oObject){if(this._oninitAttributeValue&&(this._oninitAttributeValue!=p_oObject)){this.removeListener("init",this._oninitAttributeValue.fn);this._oninitAttributeValue=null;}
+if(!this._oninitAttributeValue&&Lang.isObject(p_oObject)&&Lang.isFunction(p_oObject.fn)){this.on("init",p_oObject.fn,p_oObject.obj,p_oObject.scope);this._oninitAttributeValue=p_oObject;}},_onKeyDown:function(p_oEvent){var oTarget=Event.getTarget(p_oEvent),nCharCode=Event.getCharCode(p_oEvent),sId=oTarget.parentNode.parentNode.id,oButton=m_oButtons[sId],nIndex=-1;if(nCharCode==37||nCharCode==38){nIndex=(oButton.index===0)?(this._buttons.length-1):(oButton.index-1);}
+else if(nCharCode==39||nCharCode==40){nIndex=(oButton.index===(this._buttons.length-1))?0:(oButton.index+1);}
+if(nIndex>-1){this.check(nIndex);this.getButton(nIndex).focus();}},_onAppendTo:function(p_oEvent){var aButtons=this._buttons,nButtons=aButtons.length;for(var i=0;i0){this.addButtons(aButtons);}
+function isRadioButton(p_oElement){return(p_oElement.type=="radio");}
+aButtons=Dom.getElementsBy(isRadioButton,"input",this.get("element"));if(aButtons.length>0){this.addButtons(aButtons);}
+this.on("keydown",this._onKeyDown);this.on("appendTo",this._onAppendTo);var oContainer=this.get("container");if(oContainer){if(Lang.isString(oContainer)){var me=this;Event.onContentReady(oContainer,function(){me.appendTo(this);});}
+else{this.appendTo(oContainer);}}
+this.fireEvent("init");},initAttributes:function(p_oAttributes){var oAttributes=p_oAttributes||{};YAHOO.widget.ButtonGroup.superclass.initAttributes.call(this,oAttributes);this.setAttributeConfig("name",{value:oAttributes.name,validator:Lang.isString});this.setAttributeConfig("disabled",{value:(oAttributes.disabled||false),validator:Lang.isBoolean,method:this._setDisabled});this.setAttributeConfig("value",{value:oAttributes.value});this.setAttributeConfig("container",{value:oAttributes.container});this.setAttributeConfig("checkedButton",{value:null});this.setAttributeConfig("oninit",{value:oAttributes.oninit,method:this._setOnInit});},addButton:function(p_oButton){var oButton;if(p_oButton instanceof Button&&p_oButton.get("type")=="radio"){oButton=p_oButton;}
+else if(!Lang.isString(p_oButton)&&!p_oButton.nodeName){p_oButton.type="radio";oButton=new Button(p_oButton);}
+else{oButton=new Button(p_oButton,{type:"radio"});}
+if(oButton){var nIndex=this._buttons.length,sButtonName=oButton.get("name"),sGroupName=this.get("name");oButton.index=nIndex;this._buttons[nIndex]=oButton;m_oButtons[oButton.get("id")]=oButton;if(sButtonName!=sGroupName){oButton.set("name",sGroupName);}
+if(this.get("disabled")){oButton.set("disabled",true);}
+if(oButton.get("checked")){this.set("checkedButton",oButton);}
+oButton.on("checkedChange",this._onButtonCheckedChange,oButton,this);return oButton;}},addButtons:function(p_aButtons){if(Lang.isArray(p_aButtons)){var nButtons=p_aButtons.length,oButton,aButtons=[];if(nButtons>0){for(var i=0;i0){return aButtons;}}}},removeButton:function(p_nIndex){var oButton=this.getButton(p_nIndex);if(oButton){this._buttons.splice(p_nIndex,1);delete m_oButtons[oButton.get("id")];oButton.removeListener("checkedChange",this._onButtonCheckedChange);oButton.destroy();var nButtons=this._buttons.length;if(nButtons>0){var i=this._buttons.length-1;do{this._buttons[i].index=i;}
+while(i--);}}},getButton:function(p_nIndex){if(Lang.isNumber(p_nIndex)){return this._buttons[p_nIndex];}},getButtons:function(){return this._buttons;},getCount:function(){return this._buttons.length;},focus:function(p_nIndex){var oButton;if(Lang.isNumber(p_nIndex)){oButton=this._buttons[p_nIndex];if(oButton){oButton.focus();}}
+else{var nButtons=this.getCount();for(var i=0;i0){var i=this._buttons.length-1;do{this._buttons[i].destroy();}
+while(i--);}
+Event.purgeElement(oElement);oParentNode.removeChild(oElement);},toString:function(){return("ButtonGroup "+this.get("id"));}});})();YAHOO.register("button",YAHOO.widget.Button,{version:"2.2.0",build:"127"});
\ No newline at end of file
diff --git a/interface/ispconfig/interface/js/yui/button/button-beta.js b/interface/ispconfig/interface/js/yui/button/button-beta.js
new file mode 100644
index 0000000000000000000000000000000000000000..a102330d470cb2749f18bfc3e0a8de3eac06b3d1
--- /dev/null
+++ b/interface/ispconfig/interface/js/yui/button/button-beta.js
@@ -0,0 +1,3949 @@
+/*
+Copyright (c) 2007, Yahoo! Inc. All rights reserved.
+Code licensed under the BSD License:
+http://developer.yahoo.net/yui/license.txt
+version: 2.2.0
+*/
+/**
+* @module button
+* @description
The Button Control enables the creation of rich, graphical
+* buttons that function like traditional HTML form buttons. Unlike
+* tradition HTML form buttons, buttons created with the Button Control can have
+* a label that is different from its value. With the inclusion of the optional
+* Menu Control, the Button Control can also be
+* used to create menu buttons and split buttons, controls that are not
+* available natively in HTML. The Button Control can also be thought of as a
+* way to create more visually engaging implementations of the browser's
+* default radio-button and check-box controls.
+*
The Button Control supports the following types:
+*
+*
button
+*
Basic push button that can execute a user-specified command when
+* pressed.
+*
link
+*
Navigates to a specified url when pressed.
+*
submit
+*
Submits the parent form when pressed.
+*
reset
+*
Resets the parent form when pressed.
+*
checkbox
+*
Maintains a "checked" state that can be toggled on and off.
+*
radio
+*
Maintains a "checked" state that can be toggled on and off. Use with
+* the ButtonGroup class to create a set of controls that are mutually
+* exclusive; checking one button in the set will uncheck all others in
+* the group.
+*
menubutton
+*
When pressed will show/hide a menu.
+*
splitbutton
+*
Can execute a user-specified command or display a menu when pressed.
+*
+* @title Button
+* @namespace YAHOO.widget
+* @requires yahoo, dom, element, event
+* @optional container, menu
+* @beta
+*/
+
+
+(function() {
+
+// Shorthard for utilities
+
+var Dom = YAHOO.util.Dom,
+ Event = YAHOO.util.Event,
+ Lang = YAHOO.lang,
+
+
+ // Private member variables
+
+ m_oButtons = {},
+ m_oFocusedButton = null;
+
+
+
+// Constructor
+
+
+/**
+* The Button class creates a rich, graphical button.
+* @param {String} p_oElement String specifying the id attribute of the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {HTMLInputElement|HTMLElement} p_oElement Object reference for the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {Object} p_oElement Object literal specifying a set of configuration
+* attributes used to create the button.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button.
+* @namespace YAHOO.widget
+* @class Button
+* @constructor
+* @extends YAHOO.util.Element
+*/
+YAHOO.widget.Button = function(p_oElement, p_oAttributes) {
+
+ var fnSuperClass = YAHOO.widget.Button.superclass.constructor;
+
+ if(
+ arguments.length == 1 &&
+ !Lang.isString(p_oElement) &&
+ !p_oElement.nodeName
+ ) {
+
+ if(!p_oElement.id) {
+
+ p_oElement.id = Dom.generateId();
+
+
+ }
+
+
+
+ fnSuperClass.call(
+ this,
+ (this._createButtonElement(p_oElement.type)),
+ p_oElement
+ );
+
+ }
+ else {
+
+ var oConfig = {
+
+ element: null,
+ attributes: (p_oAttributes || {})
+
+ };
+
+
+ if(Lang.isString(p_oElement)) {
+
+ var me = this;
+
+ Event.onAvailable(p_oElement, function() {
+
+ var sTagName = this.tagName.toUpperCase();
+
+ if(sTagName == me.TAG_NAME) {
+
+ oConfig.attributes.id = this.id;
+
+ }
+ else if(sTagName == "INPUT" && !oConfig.attributes.id) {
+
+ oConfig.attributes.id = Dom.generateId();
+
+
+ }
+
+
+
+
+ oConfig.attributes.srcelement = this;
+
+ initConfig.call(me, oConfig);
+
+
+ if(!oConfig.element) {
+
+
+ oConfig.element =
+ me._createButtonElement(oConfig.attributes.type);
+
+ }
+
+ fnSuperClass.call(me, oConfig.element, oConfig.attributes);
+
+ });
+
+ }
+ else {
+
+ var sTagName = p_oElement.tagName.toUpperCase();
+
+ if(sTagName == this.TAG_NAME) {
+
+ if(p_oElement.id) {
+
+ oConfig.attributes.id = p_oElement.id;
+
+ }
+ else {
+
+ oConfig.attributes.id = Dom.generateId();
+
+
+ }
+
+
+ }
+ else if(sTagName == "INPUT" && !oConfig.attributes.id) {
+
+ oConfig.attributes.id = Dom.generateId();
+
+
+ }
+
+
+
+
+ oConfig.attributes.srcelement = p_oElement;
+
+ initConfig.call(this, oConfig);
+
+
+ if(!oConfig.element) {
+
+
+ oConfig.element =
+ this._createButtonElement(oConfig.attributes.type);
+
+ }
+
+ fnSuperClass.call(this, oConfig.element, oConfig.attributes);
+
+ }
+
+ }
+
+};
+
+
+
+// Private methods
+
+
+/**
+* @method getFirstElement
+* @description Returns an HTML element's first HTML element node.
+* @private
+* @param {HTMLElement} p_oElement Object
+* reference specifying the element to be evaluated.
+* @return {HTMLElement}
+*/
+function getFirstElement(p_oElement) {
+
+ var oFirstChild = p_oElement.firstChild;
+
+ if(oFirstChild) {
+
+ if(oFirstChild.nodeType == 1) {
+
+ return oFirstChild;
+
+ }
+ else {
+
+ var oNextSibling = oFirstChild.nextSibling;
+
+ if(oNextSibling && oNextSibling.nodeType == 1) {
+
+ return oNextSibling;
+
+ }
+
+ }
+
+ }
+
+}
+
+
+/**
+* @method createInputElement
+* @description Creates an <input> element of the
+* specified type.
+* @private
+* @param {String} p_sType String specifying the type of
+* <input> element to create.
+* @param {String} p_sName String specifying the name of
+* <input> element to create.
+* @param {String} p_sValue String specifying the value of
+* <input> element to create.
+* @param {String} p_bChecked Boolean specifying if the
+* <input> element is to be checked.
+* @return {HTMLInputElement}
+*/
+function createInputElement(p_sType, p_sName, p_sValue, p_bChecked) {
+
+ var oInput;
+
+ if(navigator.userAgent.indexOf("MSIE") != -1) {
+
+ /*
+ For IE it is necessary to create the element with the
+ "type," "name," "value," and "checked" properties set all at once.
+ */
+
+ var sInput = "";
+
+ oInput = document.createElement(sInput);
+
+ }
+ else {
+
+ oInput = document.createElement("input");
+ oInput.name = p_sName;
+ oInput.type = p_sType;
+
+ if(p_bChecked) {
+
+ oInput.checked = true;
+
+ }
+
+ }
+
+ oInput.value = p_sValue;
+
+ return oInput;
+
+}
+
+
+/**
+* @method setAttributesFromSrcElement
+* @description Gets the values for all the attributes of the source element
+* (either <input> or <a>) that map to
+* Button configuration attributes and sets them into a collection that is
+* passed to the Button constructor.
+* @private
+* @param {HTMLInputElement|HTMLAnchorElement} p_oElement Object reference to the HTML
+* element (either <input> or <span>)
+* used to create the button.
+* @param {Object} p_oAttributes Object reference for the collection of
+* configuration attributes used to create the button.
+*/
+function setAttributesFromSrcElement(p_oElement, p_oAttributes) {
+
+ var me = this;
+
+ /**
+ * @method setAttributeFromDOMAttribute
+ * @description Gets the value of the specified DOM attribute and sets it
+ * into the collection of configuration attributes used to configure
+ * the button.
+ * @private
+ * @param {String} p_sAttribute String representing the name of the
+ * attribute to retrieve from the DOM element.
+ */
+ function setAttributeFromDOMAttribute(p_sAttribute) {
+
+ if( !(p_sAttribute in p_oAttributes) ) {
+
+ /*
+ Need to use "getAttributeNode" instead of "getAttribute"
+ because using "getAttribute," IE will return the innerText of
+ a <button> for the value attribute rather
+ than the value of the "value" attribute.
+ */
+
+ var oAttribute = p_oElement.getAttributeNode(p_sAttribute);
+
+
+ if(oAttribute && ("value" in oAttribute)) {
+
+
+ p_oAttributes[p_sAttribute] = oAttribute.value;
+
+ }
+
+ }
+
+ }
+
+
+ /**
+ * @method setFormElementProperties
+ * @description Gets the value of the attributes from the form element and
+ * sets them into the collection of configuration attributes used to
+ * configure the button.
+ * @private
+ */
+ function setFormElementProperties() {
+
+ setAttributeFromDOMAttribute("type");
+
+ if( !("disabled" in p_oAttributes) ) {
+
+ p_oAttributes.disabled = p_oElement.disabled;
+
+ }
+
+ setAttributeFromDOMAttribute("name");
+ setAttributeFromDOMAttribute("value");
+ setAttributeFromDOMAttribute("title");
+
+ }
+
+
+ var sSrcElementTagName = p_oElement.tagName.toUpperCase();
+
+
+ if( !("label" in p_oAttributes) ) {
+
+ // Set the "label" property
+
+ var sText = sSrcElementTagName == "INPUT" ?
+ p_oElement.value : p_oElement.innerHTML;
+
+
+ if(sText && sText.length > 0) {
+
+ p_oAttributes.label = sText;
+
+ }
+
+ }
+
+
+ setAttributeFromDOMAttribute("tabindex");
+ setAttributeFromDOMAttribute("accesskey");
+
+
+ switch(sSrcElementTagName) {
+
+ case "A":
+
+ p_oAttributes.type = "link";
+
+ setAttributeFromDOMAttribute("href");
+ setAttributeFromDOMAttribute("target");
+
+ break;
+
+ case "INPUT":
+
+ setFormElementProperties();
+
+ if( !("checked" in p_oAttributes) ) {
+
+ p_oAttributes.checked = p_oElement.checked;
+
+ }
+
+ break;
+
+ case "BUTTON":
+
+ setFormElementProperties();
+
+ var oRootNode = p_oElement.parentNode.parentNode;
+
+ if(Dom.hasClass(oRootNode, "checked")) {
+
+ p_oAttributes.checked = true;
+
+ }
+
+ if(Dom.hasClass(oRootNode, "disabled")) {
+
+ p_oAttributes.disabled = true;
+
+ }
+
+ p_oElement.removeAttribute("name");
+ p_oElement.removeAttribute("value");
+
+ p_oElement.setAttribute("type", "button");
+
+ break;
+
+ }
+
+}
+
+
+/**
+* @method initConfig
+* @description Initializes the set of configuration attributes that are used to
+* instantiate the button.
+* @private
+* @param {Object} Object representing the button's set of
+* configuration attributes.
+*/
+function initConfig(p_oConfig) {
+
+ var oAttributes = p_oConfig.attributes,
+ oSrcElement = oAttributes.srcelement,
+ sSrcElementTagName = oSrcElement.tagName.toUpperCase();
+
+
+ if(sSrcElementTagName == this.TAG_NAME) {
+
+ p_oConfig.element = oSrcElement;
+
+ var oFirstChild = getFirstElement(p_oConfig.element);
+
+ Dom.addClass(oFirstChild, "first-child");
+
+ if(oFirstChild) {
+
+ var oButton = getFirstElement(oFirstChild);
+
+
+ if(oButton) {
+
+ var sButtonTagName = oButton.tagName.toUpperCase();
+
+
+ if(sButtonTagName == "A" || sButtonTagName == "BUTTON") {
+
+ setAttributesFromSrcElement.call(
+ this,
+ oButton,
+ oAttributes
+ );
+
+ }
+
+ }
+
+ }
+
+ }
+ else if(sSrcElementTagName == "INPUT") {
+
+ setAttributesFromSrcElement.call(this, oSrcElement, oAttributes);
+
+ }
+
+}
+
+
+YAHOO.extend(YAHOO.widget.Button, YAHOO.util.Element, {
+
+
+// Protected properties
+
+
+/**
+* @property _button
+* @description Object reference to the button's internal
+* <a> or <button> element.
+* @default null
+* @protected
+* @type HTMLAnchorElement|HTMLButtonElement
+*/
+_button: null,
+
+
+/**
+* @property _menu
+* @description Object reference to the button's menu.
+* @default null
+* @protected
+* @type YAHOO.widget.Menu
+*/
+_menu: null,
+
+
+/**
+* @property _onclickAttributeValue
+* @description Object reference to the button's current value for the "onclick"
+* configuration attribute.
+* @default null
+* @protected
+* @type Object
+*/
+_onclickAttributeValue: null,
+
+
+/**
+* @property _oninitAttributeValue
+* @description Object reference to the button's current value for the "oninit"
+* configuration attribute.
+* @default null
+* @protected
+* @type Object
+*/
+_oninitAttributeValue: null,
+
+
+/**
+* @property _activationKeyPressed
+* @description Boolean indicating if the key(s) that toggle the button's
+* "active" state have been pressed.
+* @default false
+* @protected
+* @type Boolean
+*/
+_activationKeyPressed: false,
+
+
+/**
+* @property _activationButtonPressed
+* @description Boolean indicating if the mouse button that toggles the button's
+* "active" state has been pressed.
+* @default false
+* @protected
+* @type Boolean
+*/
+_activationButtonPressed: false,
+
+
+/**
+* @property _hasKeyEventHandlers
+* @description Boolean indicating if the button's "blur", "keydown" and
+* "keyup" event handlers are assigned
+* @default false
+* @protected
+* @type Boolean
+*/
+_hasKeyEventHandlers: false,
+
+
+/**
+* @property _hasMouseEventHandlers
+* @description Boolean indicating if the button's "mouseout" and "mousedown"
+* and "mouseup" event handlers are assigned
+* @default false
+* @protected
+* @type Boolean
+*/
+_hasMouseEventHandlers: false,
+
+
+
+// Constants
+
+
+/**
+* @property TAG_NAME
+* @description The name of the tag to be used for the button's root element.
+* @default "SPAN"
+* @final
+* @type String
+*/
+TAG_NAME: "SPAN",
+
+
+/**
+* @property CHECK_ACTIVATION_KEYS
+* @description Array of numbers representing keys that (when pressed) toggle
+* the button's "checked" attribute.
+* @default [32]
+* @final
+* @type Array
+*/
+CHECK_ACTIVATION_KEYS: [32],
+
+
+/**
+* @property ACTIVATION_KEYS
+* @description Array of numbers representing keys that (when presed) toggle
+* the button's "active" state.
+* @default [13, 32]
+* @final
+* @type Array
+*/
+ACTIVATION_KEYS: [13, 32],
+
+
+/**
+* @property OPTION_AREA_WIDTH
+* @description Width (in pixels) of the area of a split button that when
+* pressed will display a menu.
+* @default 20
+* @final
+* @type Number
+*/
+OPTION_AREA_WIDTH: 20,
+
+
+/**
+* @property CSS_CLASS_NAME
+* @description String representing the CSS class(es) to be applied to the
+* button's root element.
+* @default "yuibutton"
+* @final
+* @type String
+*/
+CSS_CLASS_NAME: "yuibutton",
+
+
+/**
+* @property RADIO_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "radio."
+* @default "Unchecked. Click to check."
+* @final
+* @type String
+*/
+RADIO_DEFAULT_TITLE: "Unchecked. Click to check.",
+
+
+/**
+* @property RADIO_CHECKED_TITLE
+* @description String representing the title applied to buttons of type "radio"
+* when checked.
+* @default "Checked. Click to uncheck."
+* @final
+* @type String
+*/
+RADIO_CHECKED_TITLE: "Checked. Click to uncheck.",
+
+
+/**
+* @property CHECKBOX_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "checkbox."
+* @default "Unchecked. Click to check."
+* @final
+* @type String
+*/
+CHECKBOX_DEFAULT_TITLE: "Unchecked. Click to check.",
+
+
+/**
+* @property CHECKBOX_CHECKED_TITLE
+* @description String representing the title applied to buttons of type
+* "checkbox" when checked.
+* @default "Checked. Click to uncheck."
+* @final
+* @type String
+*/
+CHECKBOX_CHECKED_TITLE: "Checked. Click to uncheck.",
+
+
+/**
+* @property MENUBUTTON_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "menubutton."
+* @default "Menu collapsed. Click to expand."
+* @final
+* @type String
+*/
+MENUBUTTON_DEFAULT_TITLE: "Menu collapsed. Click to expand.",
+
+
+/**
+* @property MENUBUTTON_MENU_VISIBLE_TITLE
+* @description String representing the title applied to buttons of type
+* "menubutton" when the button's menu is visible.
+* @default "Menu expanded. Click or press Esc to collapse."
+* @final
+* @type String
+*/
+MENUBUTTON_MENU_VISIBLE_TITLE:
+ "Menu expanded. Click or press Esc to collapse.",
+
+
+/**
+* @property SPLITBUTTON_DEFAULT_TITLE
+* @description String representing the default title applied to buttons of
+* type "splitebutton."
+* @default "Menu collapsed. Click inside option region or press
+* Ctrl + Shift + M to show the menu."
+* @final
+* @type String
+*/
+SPLITBUTTON_DEFAULT_TITLE:
+ "Menu collapsed. Click inside option region or press Ctrl + Shift + M to show the menu.",
+
+
+/**
+* @property SPLITBUTTON_OPTION_VISIBLE_TITLE
+* @description String representing the title applied to buttons of type
+* "splitbutton" when the button's menu is visible.
+* @default "Menu expanded. Press Esc or Ctrl + Shift + M to hide the menu."
+* @final
+* @type String
+*/
+SPLITBUTTON_OPTION_VISIBLE_TITLE:
+ "Menu expanded. Press Esc or Ctrl + Shift + M to hide the menu.",
+
+
+/**
+* @property SUBMIT_TITLE
+* @description String representing the title applied to buttons of
+* type "submit."
+* @default "Click to submit form."
+* @final
+* @type String
+*/
+SUBMIT_TITLE: "Click to submit form.",
+
+
+
+// Protected attribute setter methods
+
+
+/**
+* @method _setType
+* @description Sets the value of the button's "type" attribute.
+* @protected
+* @param {String} p_sType String indicating the value for the button's
+* "type" attribute.
+*/
+_setType: function(p_sType) {
+
+ if(p_sType == "splitbutton") {
+
+ this.on("option", this._onOption);
+
+ }
+
+},
+
+
+/**
+* @method _setLabel
+* @description Sets the value of the button's "label" attribute.
+* @protected
+* @param {String} p_sLabel String indicating the value for the button's
+* "label" attribute.
+*/
+_setLabel: function(p_sLabel) {
+
+ this._button.innerHTML = p_sLabel;
+
+},
+
+
+/**
+* @method _setTabIndex
+* @description Sets the value of the button's "tabindex" attribute.
+* @protected
+* @param {Number} p_nTabIndex Number indicating the value for the button's
+* "tabindex" attribute.
+*/
+_setTabIndex: function(p_nTabIndex) {
+
+ this._button.tabIndex = p_nTabIndex;
+
+},
+
+
+/**
+* @method _setTitle
+* @description Sets the value of the button's "title" attribute.
+* @protected
+* @param {String} p_nTabIndex Number indicating the value for the button's
+* "title" attribute.
+*/
+_setTitle: function(p_sTitle) {
+
+ if(this.get("type") != "link") {
+
+ var sTitle = p_sTitle;
+
+ if(!sTitle) {
+
+
+ var sType = this.get("type");
+
+ switch(sType) {
+
+ case "radio":
+
+ sTitle = this.RADIO_DEFAULT_TITLE;
+
+ break;
+
+ case "checkbox":
+
+ sTitle = this.CHECKBOX_DEFAULT_TITLE;
+
+ break;
+
+ case "menubutton":
+
+ sTitle = this.MENUBUTTON_DEFAULT_TITLE;
+
+ break;
+
+ case "splitbutton":
+
+ sTitle = this.SPLITBUTTON_DEFAULT_TITLE;
+
+ break;
+
+ case "submit":
+
+ sTitle = this.SUBMIT_TITLE;
+
+ break;
+
+ }
+
+ }
+
+ this._button.title = sTitle;
+
+ }
+
+},
+
+
+/**
+* @method _setDisabled
+* @description Sets the value of the button's "disabled" attribute.
+* @protected
+* @param {Boolean} p_bDisabled Boolean indicating the value for the button's
+* "disabled" attribute.
+*/
+_setDisabled: function(p_bDisabled) {
+
+ if(this.get("type") != "link") {
+
+ if(p_bDisabled) {
+
+ if(this.hasFocus()) {
+
+ this.blur();
+
+ }
+
+ this._button.setAttribute("disabled", "disabled");
+
+ this.addClass("disabled");
+
+ }
+ else {
+
+ this._button.removeAttribute("disabled");
+
+ this.removeClass("disabled");
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _setAccessKey
+* @description Sets the value of the button's "accesskey" attribute.
+* @protected
+* @param {String} p_sAccessKey String indicating the value for the button's
+* "accesskey" attribute.
+*/
+_setAccessKey: function(p_sAccessKey) {
+
+ this._button.accessKey = p_sAccessKey;
+
+},
+
+
+/**
+* @method _setHref
+* @description Sets the value of the button's "href" attribute.
+* @protected
+* @param {String} p_sHref String indicating the value for the button's
+* "href" attribute.
+*/
+_setHref: function(p_sHref) {
+
+ if(this.get("type") == "link") {
+
+ this._button.href = p_sHref;
+
+ }
+
+},
+
+
+/**
+* @method _setTarget
+* @description Sets the value of the button's "target" attribute.
+* @protected
+* @param {String} p_sTarget String indicating the value for the button's
+* "target" attribute.
+*/
+_setTarget: function(p_sTarget) {
+
+ if(this.get("type") == "link") {
+
+ this._button.setAttribute("target", p_sTarget);
+
+ }
+
+},
+
+
+/**
+* @method _setChecked
+* @description Sets the value of the button's "target" attribute.
+* @protected
+* @param {Boolean} p_bChecked Boolean indicating the value for the button's
+* "checked" attribute.
+*/
+_setChecked: function(p_bChecked) {
+
+ var sType = this.get("type"),
+ sTitle;
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ if(p_bChecked) {
+
+ this.addClass("checked");
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_CHECKED_TITLE :
+ this.CHECKBOX_CHECKED_TITLE;
+
+ }
+ else {
+
+ this.removeClass("checked");
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_DEFAULT_TITLE :
+ this.CHECKBOX_DEFAULT_TITLE;
+
+ }
+
+ this.set("title", sTitle);
+
+ }
+
+},
+
+
+/**
+* @method _setMenu
+* @description Sets the value of the button's "menu" attribute.
+* @protected
+* @param {Object} p_oMenu Object indicating the value for the button's
+* "menu" attribute.
+*/
+_setMenu: function(p_oMenu) {
+
+ var Menu = YAHOO.widget.Menu,
+ oMenu,
+ me = this;
+
+ if(!Menu) {
+
+
+ return false;
+
+ }
+
+
+ function initMenu() {
+
+ if(oMenu) {
+
+ oMenu.showEvent.subscribe(this._onMenuShow, this, true);
+ oMenu.hideEvent.subscribe(this._onMenuHide, this, true);
+ oMenu.keyDownEvent.subscribe(this._onMenuKeyDown, this, true);
+ oMenu.renderEvent.subscribe(this._onMenuRender, this, true);
+ oMenu.clickEvent.subscribe(this._onMenuClick, this, true);
+ oMenu.itemAddedEvent.subscribe(this._onMenuItemAdded, this, true);
+
+ var oSrcElement = oMenu.srcElement;
+
+ if(oSrcElement && oSrcElement.tagName.toUpperCase() == "SELECT") {
+
+ oSrcElement.style.display = "none";
+ oSrcElement.parentNode.removeChild(oSrcElement);
+
+ }
+
+ this._menu = oMenu;
+
+ }
+ else {
+
+ this._menu.destroy();
+ this._menu = null;
+
+ }
+
+ }
+
+
+ if(p_oMenu instanceof Menu) {
+
+ oMenu = p_oMenu;
+
+ var aItems = oMenu.getItems(),
+ nItems = aItems.length,
+ oItem;
+
+ if(nItems > 0) {
+
+ var i = nItems - 1;
+
+ do {
+
+ oItem = aItems[i];
+
+ if(oItem) {
+
+ oItem.cfg.subscribeToConfigEvent(
+ "selected",
+ this._onMenuItemSelected,
+ oItem,
+ this
+ );
+
+ }
+
+ }
+ while(i--);
+
+ }
+
+ initMenu.call(this);
+
+ }
+ else if(Lang.isArray(p_oMenu)) {
+
+ this.on("appendTo", function() {
+
+ oMenu = new Menu(
+ Dom.generateId(),
+ { lazyload: true, itemdata: p_oMenu }
+ );
+
+ initMenu.call(me);
+
+ });
+
+ }
+ else if(Lang.isString(p_oMenu)) {
+
+ Event.onContentReady(p_oMenu, function() {
+
+ oMenu = new Menu(this, { lazyload: true });
+
+ initMenu.call(me);
+
+ });
+
+ }
+ else if(p_oMenu && p_oMenu.nodeName) {
+
+ oMenu = new Menu(p_oMenu, { lazyload: true });
+
+ initMenu.call(this);
+
+ }
+
+},
+
+
+/**
+* @method _setOnClick
+* @description Sets the value of the button's "onclick" attribute.
+* @protected
+* @param {Object} p_oObject Object indicating the value for the button's
+* "onclick" attribute.
+*/
+_setOnClick: function(p_oObject) {
+
+ /*
+ Remove any existing listeners if a "click" event handler has already
+ been specified.
+ */
+
+ if(
+ this._onclickAttributeValue &&
+ (this._onclickAttributeValue != p_oObject)
+ ) {
+
+ this.removeListener("click", this._onclickAttributeValue.fn);
+
+ this._onclickAttributeValue = null;
+
+ }
+
+
+ if(
+ !this._onclickAttributeValue &&
+ Lang.isObject(p_oObject) &&
+ Lang.isFunction(p_oObject.fn)
+ ) {
+
+ this.on("click", p_oObject.fn, p_oObject.obj, p_oObject.scope);
+
+ this._onclickAttributeValue = p_oObject;
+
+ }
+
+},
+
+/**
+* @method _setOnInit
+* @description Sets the value of the button's "init" attribute.
+* @protected
+* @param {Object} p_oObject Object indicating the value for the button's
+* "oninit" attribute.
+*/
+_setOnInit: function(p_oObject) {
+
+ /*
+ Remove any existing listeners if a "init" event handler has already
+ been specified.
+ */
+
+ if(
+ this._oninitAttributeValue &&
+ (this._oninitAttributeValue != p_oObject)
+ ) {
+
+ this.removeListener("init", this._oninitAttributeValue.fn);
+
+ this._oninitAttributeValue = null;
+
+ }
+
+
+ if(
+ !this._oninitAttributeValue &&
+ Lang.isObject(p_oObject) &&
+ Lang.isFunction(p_oObject.fn)
+ ) {
+
+ this.on("init", p_oObject.fn, p_oObject.obj, p_oObject.scope);
+
+ this._oninitAttributeValue = p_oObject;
+
+ }
+
+},
+
+
+
+// Protected methods
+
+
+/**
+* @method _createButtonElement
+* @description Creates the button's element.
+* @protected
+* @param {String} p_sType String indicating the type of element to create.
+* @return {HTMLElement}
+*/
+_createButtonElement: function(p_sType) {
+
+ var sTagName = this.TAG_NAME,
+ oElement = document.createElement(sTagName);
+
+ oElement.innerHTML =
+
+ "<" + sTagName + " class=\"first-child\">" +
+ (p_sType == "link" ? "" : "") +
+ "" + sTagName + ">";
+
+ return oElement;
+
+},
+
+
+/**
+* @method _isActivationKey
+* @description Determines if the specified keycode is one that toggles the
+* button's "active" state.
+* @protected
+* @param {Number} p_nKeyCode Number representing the keycode to be evaluated.
+* @return {Boolean}
+*/
+_isActivationKey: function(p_nKeyCode) {
+
+ var sType = this.get("type"),
+ aKeyCodes = (sType == "checkbox" || sType == "radio") ?
+ this.CHECK_ACTIVATION_KEYS : this.ACTIVATION_KEYS,
+
+ nKeyCodes = aKeyCodes.length;
+
+ if(nKeyCodes > 0) {
+
+ var i = nKeyCodes - 1;
+
+ do {
+
+ if(p_nKeyCode == aKeyCodes[i]) {
+
+ return true;
+
+ }
+
+ }
+ while(i--);
+
+ }
+
+},
+
+
+/**
+* @method _isSplitButtonOptionKey
+* @description Determines if the specified keycode is one that toggles the
+* display of the split button's menu.
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @return {Boolean}
+*/
+_isSplitButtonOptionKey: function(p_oEvent) {
+
+ return (
+ p_oEvent.ctrlKey &&
+ p_oEvent.shiftKey &&
+ Event.getCharCode(p_oEvent) == 77
+ );
+
+},
+
+
+_originalMaxHeight: -1,
+
+
+/**
+* @method _showMenu
+* @description Shows the button's menu.
+* @protected
+*/
+_showMenu: function() {
+
+ var oMenu = this._menu;
+
+ if(oMenu) {
+
+ YAHOO.widget.MenuManager.hideVisible();
+
+ oMenu.cfg.applyConfig({
+ context:[this.get("id"), "tl", "bl"],
+ clicktohide: false,
+ constraintoviewport: false,
+ visible: true
+ });
+
+ oMenu.cfg.fireQueue();
+
+ var nViewportHeight = Dom.getViewportHeight(),
+ nMenuHeight = oMenu.element.offsetHeight;
+
+
+ if((oMenu.cfg.getProperty("y") + nMenuHeight) > nViewportHeight) {
+
+
+ oMenu.align("bl", "tl");
+
+ var nY = oMenu.cfg.getProperty("y"),
+
+ nScrollTop = (
+ document.documentElement.scrollTop ||
+ document.body.scrollTop
+ );
+
+
+ if(nScrollTop >= nY) {
+
+ if(this._originalMaxHeight == -1) {
+
+ this._originalMaxHeight =
+ oMenu.cfg.getProperty("maxheight");
+
+ }
+
+ oMenu.cfg.setProperty(
+ "maxheight",
+ (nMenuHeight - ((nScrollTop - nY) + 20))
+ );
+
+ oMenu.align("bl", "tl");
+
+ }
+
+ }
+
+ oMenu.cfg.setProperty("constraintoviewport", true);
+
+ }
+
+},
+
+
+/**
+* @method _hideMenu
+* @description Hides the button's menu.
+* @protected
+*/
+_hideMenu: function() {
+
+ var oMenu = this._menu;
+
+ if(oMenu && oMenu.cfg.getProperty("visible")) {
+
+ oMenu.hide();
+
+ }
+
+},
+
+
+/**
+* @method _submitForm
+* @description Submits the form to which the button belongs.
+* @protected
+*/
+_submitForm: function() {
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ YAHOO.widget.Button.addHiddenFieldsToForm(oForm);
+
+ this.createHiddenField();
+
+ oForm.submit();
+
+ }
+
+},
+
+
+
+// Protected event handlers
+
+
+/**
+* @method _onMouseOver
+* @description "mouseover" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseOver: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+ if(!this._hasMouseEventHandlers) {
+
+ this.on("mouseout", this._onMouseOut);
+ this.on("mousedown", this._onMouseDown);
+ this.on("mouseup", this._onMouseUp);
+
+ this._hasMouseEventHandlers = true;
+
+ }
+
+ this.addClass("hover");
+
+ if(this._activationButtonPressed) {
+
+ this.addClass("active");
+
+ }
+
+
+ if(this._bOptionPressed) {
+
+ this.addClass("activeoption");
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onMouseOut
+* @description "mouseout" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseOut: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+ this.removeClass("hover");
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ if(this._activationButtonPressed || this._bOptionPressed) {
+
+ Event.on(document, "mouseup", this._onDocumentMouseUp, this, true);
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onDocumentMouseUp
+* @description "mouseup" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onDocumentMouseUp: function(p_oEvent, p_oButton) {
+
+ this._activationButtonPressed = false;
+ this._bOptionPressed = false;
+
+ var sType = this.get("type");
+
+ if(sType == "menubutton" || sType == "splitbutton") {
+
+ this.removeClass((sType == "menubutton" ? "active" : "activeoption"));
+
+ this._hideMenu();
+
+ }
+
+ Event.removeListener(document, "mouseup", this._onDocumentMouseUp);
+
+},
+
+
+/**
+* @method _onMouseDown
+* @description "mousedown" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseDown: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+ if((p_oEvent.which || p_oEvent.button) == 1) {
+
+ if(!this.hasFocus()) {
+
+ this.focus();
+
+ }
+
+
+ var sType = this.get("type");
+
+
+ if(sType == "splitbutton") {
+
+ var oElement = this.get("element"),
+ nX = Event.getPageX(p_oEvent) - Dom.getX(oElement);
+
+ if((oElement.offsetWidth - this.OPTION_AREA_WIDTH) < nX) {
+
+ this.fireEvent("option", p_oEvent);
+
+ }
+ else {
+
+ this.addClass("active");
+
+ this._activationButtonPressed = true;
+
+ }
+
+ }
+ else if(sType == "menubutton") {
+
+ if(this.hasClass("active")) {
+
+ this._hideMenu();
+
+ this._activationButtonPressed = false;
+
+ }
+ else {
+
+ this._showMenu();
+
+ this._activationButtonPressed = true;
+
+ }
+
+ }
+ else {
+
+ this.addClass("active");
+
+ this._activationButtonPressed = true;
+
+ }
+
+
+
+ if(sType == "splitbutton" || sType == "menubutton") {
+
+ var me = this;
+
+
+ function onMouseUp() {
+
+ me._hideMenu();
+ me.removeListener("mouseup", onMouseUp);
+
+ }
+
+
+ this._hideMenuTimerId = window.setTimeout(function() {
+
+ me.on("mouseup", onMouseUp);
+
+ }, 250);
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onMouseUp
+* @description "mouseup" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onMouseUp: function(p_oEvent) {
+
+ if(!this.get("disabled")) {
+
+
+ if(this._hideMenuTimerId) {
+
+ window.clearTimeout(this._hideMenuTimerId);
+
+ }
+
+ var sType = this.get("type");
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ this.set("checked", !(this.get("checked")));
+
+ }
+
+
+ this._activationButtonPressed = false;
+
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onFocus
+* @description "focus" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button that
+* fired the event.
+*/
+_onFocus: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ this.addClass("focus");
+
+ if(this._activationKeyPressed) {
+
+ this.addClass("active");
+
+ }
+
+ m_oFocusedButton = this;
+
+
+ if(!this._hasKeyEventHandlers) {
+
+ var oElement = this._button;
+
+ Event.on(oElement, "blur", this._onBlur, this, true);
+ Event.on(oElement, "keydown", this._onKeyDown, this, true);
+ Event.on(oElement, "keyup", this._onKeyUp, this, true);
+
+ this._hasKeyEventHandlers = true;
+
+ }
+
+
+ this.fireEvent("focus", p_oEvent);
+
+ }
+
+},
+
+
+/**
+* @method _onBlur
+* @description "blur" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onBlur: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ this.removeClass("focus");
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ if(this._activationKeyPressed) {
+
+ Event.on(document, "keyup", this._onDocumentKeyUp, this, true);
+
+ }
+
+
+ m_oFocusedButton = null;
+
+ this.fireEvent("blur", p_oEvent);
+
+ }
+
+},
+
+
+/**
+* @method _onDocumentKeyUp
+* @description "keyup" event handler for the document.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onDocumentKeyUp: function(p_oEvent, p_oButton) {
+
+ if(this._isActivationKey(Event.getCharCode(p_oEvent))) {
+
+ this._activationKeyPressed = false;
+
+ Event.removeListener(document, "keyup", this._onDocumentKeyUp);
+
+ }
+
+},
+
+
+/**
+* @method _onKeyDown
+* @description "keydown" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onKeyDown: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ if(
+ this.get("type") == "splitbutton" &&
+ this._isSplitButtonOptionKey(p_oEvent)
+ ) {
+
+ this.fireEvent("option", p_oEvent);
+
+ }
+ else if(this._isActivationKey(Event.getCharCode(p_oEvent))) {
+
+ if(this.get("type") == "menubutton") {
+
+ this._showMenu();
+
+ }
+ else {
+
+ this._activationKeyPressed = true;
+
+ this.addClass("active");
+
+ }
+
+ }
+
+
+ var oMenu = this._menu;
+
+ if(
+ oMenu && oMenu.cfg.getProperty("visible") &&
+ Event.getCharCode(p_oEvent) == 27
+ ) {
+
+ oMenu.hide();
+ this.focus();
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onKeyUp
+* @description "keyup" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onKeyUp: function(p_oEvent, p_oButton) {
+
+ if(!this.get("disabled")) {
+
+ if(this._isActivationKey(Event.getCharCode(p_oEvent))) {
+
+ var sType = this.get("type");
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ this.set("checked", !(this.get("checked")));
+
+ }
+
+ this._activationKeyPressed = false;
+
+ if(this.get("type") != "menubutton") {
+
+ this.removeClass("active");
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onClick
+* @description "click" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onClick: function(p_oEvent) {
+
+ var sType = this.get("type"),
+ sTitle;
+
+ switch(sType) {
+
+ case "radio":
+ case "checkbox":
+
+ if(this.get("checked")) {
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_CHECKED_TITLE :
+ this.CHECKBOX_CHECKED_TITLE;
+
+ }
+ else {
+
+ sTitle = (sType == "radio") ?
+ this.RADIO_DEFAULT_TITLE :
+ this.CHECKBOX_DEFAULT_TITLE;
+
+ }
+
+ this.set("title", sTitle);
+
+ break;
+
+ case "submit":
+
+ this._submitForm();
+
+ break;
+
+ case "reset":
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ oForm.reset();
+
+ }
+
+ break;
+
+ case "menubutton":
+
+ sTitle = this._menu.cfg.getProperty("visible") ?
+ this.MENUBUTTON_MENU_VISIBLE_TITLE :
+ this.MENUBUTTON_DEFAULT_TITLE;
+
+ this.set("title", sTitle);
+
+ break;
+
+ case "splitbutton":
+
+ var oElement = this.get("element"),
+ nX = Event.getPageX(p_oEvent) - Dom.getX(oElement);
+
+ if((oElement.offsetWidth - this.OPTION_AREA_WIDTH) < nX) {
+
+ return false;
+
+ }
+ else {
+
+ this._hideMenu();
+
+ var oSrcElement = this.get("srcelement");
+
+ if(oSrcElement && oSrcElement.type == "submit") {
+
+ this._submitForm();
+
+ }
+
+ }
+
+ sTitle = this._menu.cfg.getProperty("visible") ?
+ this.SPLITBUTTON_OPTION_VISIBLE_TITLE :
+ this.SPLITBUTTON_DEFAULT_TITLE;
+
+ this.set("title", sTitle);
+
+ break;
+
+ }
+
+},
+
+
+/**
+* @method _onAppendTo
+* @description "appendTo" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onAppendTo: function(p_oEvent) {
+
+ /*
+ It is necessary to call "getForm" using "setTimeout" to make sure that
+ the button's "form" property returns a node reference. Sometimes, if
+ you try to get the reference immediately after appending the field, it
+ is null.
+ */
+
+ var me = this;
+
+ window.setTimeout(function() {
+
+ var oForm = me.getForm();
+
+ if(oForm) {
+
+ Event.on(oForm, "reset", me._onFormReset, me, true);
+ Event.on(oForm, "submit", me._onFormSubmit, me, true);
+
+ }
+
+ }, 0);
+
+},
+
+
+/**
+* @method _onFormSubmit
+* @description "submit" event handler for the button's form.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onFormSubmit: function(p_oEvent, p_oButton) {
+
+ var sType = this.get("type"),
+ oMenuItem = this.get("selectedMenuItem"),
+ oForm = this.getForm();
+
+
+ if(sType == "radio" || sType == "checkbox") {
+
+
+ this.createHiddenField();
+
+ }
+ else if(oMenuItem) {
+
+ var oSrcElement = this._menu.srcElement;
+
+ if(oSrcElement && oSrcElement.tagName.toUpperCase() == "SELECT") {
+
+ oForm.appendChild(oSrcElement);
+ oSrcElement.selectedIndex = oMenuItem.index;
+
+ }
+ else {
+
+ var oValue = (oMenuItem.value === null || oMenuItem.value === "") ?
+ oMenuItem.cfg.getProperty("text") :
+ oMenuItem.value;
+
+
+ if(oValue) {
+
+ var oField = createInputElement(
+ "hidden",
+ (this.get("name") + "_options"),
+ oValue
+ );
+
+ oForm.appendChild(oField);
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onFormReset
+* @description "reset" event handler for the button's form.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onFormReset: function(p_oEvent, p_oButton) {
+
+ var sType = this.get("type");
+
+ if(sType == "checkbox" || sType == "radio") {
+
+ this.resetValue("checked");
+
+ }
+
+ if(this._menu) {
+
+ this.resetValue("selectedMenuItem");
+
+ }
+
+},
+
+
+/**
+* @method _onDocumentMouseDown
+* @description "mousedown" event handler for the document.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onDocumentMouseDown: function(p_oEvent, p_oButton) {
+
+ var oTarget = Event.getTarget(p_oEvent),
+ oButtonElement = this.get("element"),
+ oMenuElement = this._menu.element;
+
+ if(
+ oTarget != oButtonElement &&
+ !Dom.isAncestor(oButtonElement, oTarget) &&
+ oTarget != oMenuElement &&
+ !Dom.isAncestor(oMenuElement, oTarget)
+ ) {
+
+ this._hideMenu();
+
+ Event.removeListener(
+ document,
+ "mousedown",
+ this._onDocumentMouseDown
+ );
+
+ }
+
+},
+
+
+/**
+* @method _onOption
+* @description "option" event handler for the button.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onOption: function(p_oEvent) {
+
+ if(this.hasClass("activeoption")) {
+
+ this._hideMenu();
+
+ this._bOptionPressed = false;
+
+ }
+ else {
+
+ this._showMenu();
+
+ this._bOptionPressed = true;
+
+ }
+
+},
+
+
+/**
+* @method _onMenuShow
+* @description "show" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuShow: function(p_sType, p_aArgs, p_oButton) {
+
+ Event.on(document, "mousedown", this._onDocumentMouseDown, this, true);
+
+ var sTitle,
+ sClass;
+
+ if(this.get("type") == "splitbutton") {
+
+ sTitle = this.SPLITBUTTON_OPTION_VISIBLE_TITLE;
+ sClass = "activeoption";
+
+ }
+ else {
+
+ sTitle = this.MENUBUTTON_MENU_VISIBLE_TITLE;
+ sClass = "active";
+
+ }
+
+ this.addClass(sClass);
+ this.set("title", sTitle);
+
+},
+
+
+/**
+* @method _onMenuHide
+* @description "hide" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuHide: function(p_sType, p_aArgs, p_oButton) {
+
+ if(this._originalMaxHeight != -1) {
+
+ this._menu.cfg.setProperty("maxheight", this._originalMaxHeight);
+
+ }
+
+
+ var sTitle,
+ sClass;
+
+ if(this.get("type") == "splitbutton") {
+
+ sTitle = this.SPLITBUTTON_DEFAULT_TITLE;
+ sClass = "activeoption";
+
+ }
+ else {
+
+ sTitle = this.MENUBUTTON_DEFAULT_TITLE;
+ sClass = "active";
+ }
+
+
+ this.removeClass(sClass);
+ this.set("title", sTitle);
+
+},
+
+
+/**
+* @method _onMenuKeyDown
+* @description "keydown" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuKeyDown: function(p_sType, p_aArgs, p_oButton) {
+
+ var oEvent = p_aArgs[0];
+
+ if(Event.getCharCode(oEvent) == 27) {
+
+ this.focus();
+
+ if(this.get("type") == "splitbutton") {
+
+ this._bOptionPressed = false;
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method _onMenuRender
+* @description "render" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the button.
+*/
+_onMenuRender: function(p_sType, p_aArgs, p_oButton) {
+
+ this.get("element").parentNode.appendChild(this._menu.element);
+
+},
+
+
+/**
+* @method _onMenuItemSelected
+* @description "selectedchange" event handler for each item in the
+* button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.MenuItem}
+* p_oItem Object representing the menu item that subscribed to the event.
+*/
+_onMenuItemSelected: function(p_sType, p_aArgs, p_oItem) {
+
+ this.set("selectedMenuItem", p_oItem);
+
+},
+
+
+/**
+* @method _onMenuItemAdded
+* @description "itemadded" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.MenuItem}
+* p_oItem Object representing the menu item that subscribed to the event.
+*/
+_onMenuItemAdded: function(p_sType, p_aArgs, p_oItem) {
+
+ var oItem = p_aArgs[0];
+
+ oItem.cfg.subscribeToConfigEvent(
+ "selected",
+ this._onMenuItemSelected,
+ oItem,
+ this
+ );
+
+},
+
+
+/**
+* @method _onMenuClick
+* @description "click" event handler for the button's menu.
+* @private
+* @param {String} p_sType String representing the name of the event that
+* was fired.
+* @param {Array} p_aArgs Array of arguments sent when the event was fired.
+* @param {YAHOO.widget.Button} p_oButton Object representing the menu's button.
+*/
+_onMenuClick: function(p_sType, p_aArgs, p_oButton) {
+
+ var oItem = p_aArgs[0];
+
+ if(oItem) {
+
+ var oSrcElement = this.get("srcelement");
+
+ if(oSrcElement && oSrcElement.type == "submit") {
+
+ this._submitForm();
+
+ }
+
+ this._hideMenu();
+
+ }
+
+},
+
+
+
+// Public methods
+
+
+/**
+* @method createHiddenField
+* @description Creates the button's hidden form field and appends it to its
+* parent form.
+* @return {HTMLInputElement}
+*/
+createHiddenField: function () {
+
+ if(!this.get("disabled")) {
+
+ var sType = this.get("type"),
+
+ bCheckable = (sType == "checkbox" || sType == "radio"),
+
+ oField = createInputElement(
+ (bCheckable ? this.get("type") : "hidden"),
+ this.get("name"),
+ this.get("value"),
+ this.get("checked")
+ ),
+
+ oForm = this.getForm();
+
+
+ if(oField && bCheckable) {
+
+ oField.style.display = "none";
+
+ }
+
+
+ if(oForm) {
+
+ oForm.appendChild(oField);
+
+ }
+
+
+ return oField;
+
+ }
+
+},
+
+
+/**
+* @method init
+* @description The Button class's initialization method.
+* @param {String} p_oElement String specifying the id attribute of the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {HTMLInputElement|HTMLElement} p_oElement Object reference for the
+* <input>, <a> or
+* <span> element to be used to create the button.
+* @param {Object} p_oElement Object literal specifying a set of configuration
+* attributes used to create the button.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button.
+*/
+init: function(p_oElement, p_oAttributes) {
+
+ var sTagName = p_oAttributes.type == "link" ? "A" : "BUTTON",
+ oSrcElement = p_oAttributes.srcelement;
+
+
+ this._button = p_oElement.getElementsByTagName(sTagName)[0];
+
+
+ YAHOO.widget.Button.superclass.init.call(
+ this, p_oElement,
+ p_oAttributes
+ );
+
+
+ m_oButtons[this.get("id")] = this;
+
+
+ this.addClass(this.CSS_CLASS_NAME);
+ this.addClass(this.get("type"));
+
+ Event.on(this._button, "focus", this._onFocus, this, true);
+ this.on("mouseover", this._onMouseOver);
+ this.on("click", this._onClick);
+ this.on("appendTo", this._onAppendTo);
+
+ var oContainer = this.get("container"),
+ oElement = this.get("element");
+
+
+ if(oContainer) {
+
+ if(Lang.isString(oContainer)) {
+
+ var me = this;
+
+ Event.onContentReady(oContainer, function() {
+
+ me.appendTo(this);
+
+ });
+
+ }
+ else {
+
+ this.appendTo(oContainer);
+
+ }
+
+ }
+ else if(
+ !Dom.inDocument(oElement) &&
+ oSrcElement &&
+ oSrcElement.tagName.toUpperCase() == "INPUT"
+ ) {
+
+ var oParentNode = oSrcElement.parentNode;
+
+ if(oParentNode) {
+
+ this.fireEvent("beforeAppendTo", {
+ type: "beforeAppendTo",
+ target: oParentNode
+ });
+
+ oParentNode.replaceChild(oElement, oSrcElement);
+
+ this.fireEvent("appendTo", {
+ type: "appendTo",
+ target: oParentNode
+ });
+
+ }
+
+ }
+ else if(
+ Dom.inDocument(oElement) &&
+ oSrcElement.tagName.toUpperCase() == "SPAN"
+ ) {
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ Event.on(oForm, "reset", this._onFormReset, this, true);
+ Event.on(oForm, "submit", this._onFormSubmit, this, true);
+
+ }
+
+ }
+
+ this.fireEvent("init");
+
+
+},
+
+
+/**
+* @method initAttributes
+* @description Initializes all of the configuration attributes used to create
+* the button.
+* @param {Object} p_oAttributes Object literal specifying a set of
+* configuration attributes used to create the button.
+*/
+initAttributes: function(p_oAttributes) {
+
+ var oAttributes = p_oAttributes || {};
+
+ YAHOO.widget.Button.superclass.initAttributes.call(this, oAttributes);
+
+
+ /**
+ * @config type
+ * @description String specifying the button's type. Possible values are:
+ * "button," "link," "submit," "reset," "checkbox," "radio," "menubutton,"
+ * and "splitbutton."
+ * @default "button"
+ * @type String
+ */
+ this.setAttributeConfig("type", {
+
+ value: (oAttributes.type || "button"),
+ validator: Lang.isString,
+ writeOnce: true,
+ method: this._setType
+
+ });
+
+
+ /**
+ * @config label
+ * @description String specifying the button's text label or innerHTML.
+ * @default null
+ * @type String
+ */
+ this.setAttributeConfig("label", {
+
+ value: oAttributes.label,
+ validator: Lang.isString,
+ method: this._setLabel
+
+ });
+
+
+ /**
+ * @config value
+ * @description Object specifying the value for the button.
+ * @default null
+ * @type Object
+ */
+ this.setAttributeConfig("value", {
+
+ value: oAttributes.value
+
+ });
+
+
+ /**
+ * @config name
+ * @description String specifying the name for the button.
+ * @default null
+ * @type String
+ */
+ this.setAttributeConfig("name", {
+
+ value: oAttributes.name,
+ validator: Lang.isString
+
+ });
+
+
+ /**
+ * @config tabindex
+ * @description Number specifying the tabindex for the button.
+ * @default null
+ * @type Number
+ */
+ this.setAttributeConfig("tabindex", {
+
+ value: oAttributes.tabindex,
+ validator: Lang.isNumber,
+ method: this._setTabIndex
+
+ });
+
+
+ /**
+ * @config title
+ * @description String specifying the title for the button.
+ * @default null
+ * @type String
+ */
+ this.configureAttribute("title", {
+
+ value: oAttributes.title,
+ validator: Lang.isString,
+ method: this._setTitle
+
+ });
+
+
+ /**
+ * @config disabled
+ * @description Boolean indicating if the button should be disabled.
+ * (Disabled buttons are dimmed and will not respond to user input
+ * or fire events.)
+ * @default false
+ * @type Boolean
+ */
+ this.setAttributeConfig("disabled", {
+
+ value: (oAttributes.disabled || false),
+ validator: Lang.isBoolean,
+ method: this._setDisabled
+
+ });
+
+
+ /**
+ * @config href
+ * @description String specifying the href for the button. Applies only to
+ * buttons of type "link."
+ * @type String
+ */
+ this.setAttributeConfig("href", {
+
+ value: oAttributes.href,
+ validator: Lang.isString,
+ method: this._setHref
+
+ });
+
+
+ /**
+ * @config target
+ * @description String specifying the target for the button. Applies only
+ * to buttons of type "link."
+ * @type String
+ */
+ this.setAttributeConfig("target", {
+
+ value: oAttributes.target,
+ validator: Lang.isString,
+ method: this._setTarget
+
+ });
+
+
+ /**
+ * @config checked
+ * @description Boolean indicating if the button is checked. Applies only
+ * to buttons of type "radio" and "checkbox."
+ * @default false
+ * @type Boolean
+ */
+ this.setAttributeConfig("checked", {
+
+ value: (oAttributes.checked || false),
+ validator: Lang.isBoolean,
+ method: this._setChecked
+
+ });
+
+
+ /**
+ * @config container
+ * @description HTML element reference or string specifying the id
+ * attribute of the HTML element that the button's markup should be
+ * rendered into.
+ * @type HTMLElement|String
+ * @default null
+ */
+ this.setAttributeConfig("container", {
+
+ value: oAttributes.container
+
+ });
+
+
+ /**
+ * @config srcelement
+ * @description Object reference to the HTML element (either
+ * <input> or <span>) used to
+ * create the button.
+ * @type HTMLElement|String
+ * @default null
+ */
+ this.setAttributeConfig("srcelement", {
+
+ value: oAttributes.srcelement,
+ writeOnce: true
+
+ });
+
+
+ /**
+ * @config menu
+ * @description Object specifying the menu for the button. The value can be
+ * one of the following:
+ *
String specifying the id attribute of the <div>
+ * element used to create the menu.
+ *
String specifying the id attribute of the
+ * <select> element used to create the menu.
+ *
Object specifying the <div> element used to
+ * create the menu.
+ *
Object specifying the <select> element used to
+ * create the menu.
+ *
Array of object literals, each representing a set of
+ * YAHOO.widget.MenuItem
+ * configuration attributes.
+ *
Array of strings representing the text labels for each menu item in
+ * the menu.
+ *
+ * @type HTMLElement|String|Array
+ * @default null
+ */
+ this.setAttributeConfig("menu", {
+
+ value: null,
+ method: this._setMenu
+
+ });
+
+
+ /**
+ * @config selectedMenuItem
+ * @description Reference to the item in the button's menu that is
+ * currently selected.
+ * @type YAHOO.widget.MenuItem
+ * @default null
+ */
+ this.setAttributeConfig("selectedMenuItem", {
+
+ value: null
+
+ });
+
+
+ /**
+ * @config onclick
+ * @description Object literal representing the code to be executed when
+ * the button is clicked. Format: {
+ * fn: Function, // The handler to call when the
+ * event fires. obj: Object, // An object to
+ * pass back to the handler. scope: Object //
+ * The object to use for the scope of the handler. }
+ * @type Object
+ * @default null
+ */
+ this.setAttributeConfig("onclick", {
+
+ value: oAttributes.onclick,
+ method: this._setOnClick
+
+ });
+
+
+ /**
+ * @config oninit
+ * @description Object literal representing the code to be executed when
+ * the button is initialized. Format: {
+ * fn: Function, // The handler to call when the
+ * event fires. obj: Object, // An object to
+ * pass back to the handler. scope: Object //
+ * The object to use for the scope of the handler. }
+ * @type Object
+ * @default null
+ */
+ this.setAttributeConfig("oninit", {
+
+ value: oAttributes.oninit,
+ method: this._setOnInit
+
+ });
+
+},
+
+
+/**
+* @method focus
+* @description Causes the button to receive the focus and fires the button's
+* "focus" event.
+*/
+focus: function() {
+
+ if(!this.get("disabled")) {
+
+ this._button.focus();
+
+ }
+
+},
+
+
+/**
+* @method blur
+* @description Causes the button to lose focus and fires the button's
+* "blur" event.
+*/
+blur: function() {
+
+ if(!this.get("disabled")) {
+
+ this._button.blur();
+
+ }
+
+},
+
+
+/**
+* @method hasFocus
+* @description Returns a boolean indicating whether or not the button has focus.
+* @return {Boolean}
+*/
+hasFocus: function() {
+
+ return (m_oFocusedButton == this);
+
+},
+
+
+/**
+* @method isActive
+* @description Returns a boolean indicating whether or not the button is active.
+* @return {Boolean}
+*/
+isActive: function() {
+
+ return this.hasClass("active");
+
+},
+
+
+/**
+* @method getMenu
+* @description Returns a reference to the button's menu.
+* @return {YAHOO.widget.Menu}
+*/
+getMenu: function() {
+
+ return this._menu;
+
+},
+
+
+/**
+* @method getForm
+* @description Returns a reference to the button's menu.
+* @return {HTMLFormElement}
+*/
+getForm: function() {
+
+ return this._button.form;
+
+},
+
+
+/**
+* @method destroy
+* @description Removes the button's element from its parent element and
+* removes all event handlers.
+*/
+destroy: function() {
+
+
+ var oElement = this.get("element"),
+ oParentNode = oElement.parentNode,
+ oMenu = this._menu;
+
+ if(oMenu) {
+
+
+ oMenu.destroy();
+
+ }
+
+
+ Event.purgeElement(oElement);
+ Event.purgeElement(this._button);
+ Event.removeListener(document, "mouseup", this._onDocumentMouseUp);
+ Event.removeListener(document, "keyup", this._onDocumentKeyUp);
+ Event.removeListener(document, "mousedown", this._onDocumentMouseDown);
+
+ var oForm = this.getForm();
+
+ if(oForm) {
+
+ Event.removeListener(oForm, "reset", this._onFormReset);
+
+ }
+
+
+ oParentNode.removeChild(oElement);
+
+
+ delete m_oButtons[this.get("id")];
+
+
+},
+
+
+/**
+* @method toString
+* @description Returns a string representing the button.
+* @return {String}
+*/
+toString: function() {
+
+ return ("Button " + this.get("id"));
+
+}
+
+});
+
+
+/**
+* @method addHiddenFieldsToForm
+* @description Searches the specified form and adds hidden fields for instances
+* of YAHOO.widget.Button that are of type "radio," "checkbox," "menubutton,"
+* and "splitbutton."
+* @param {HTMLFormElement} p_oForm Object reference
+* for the form to search.
+*/
+YAHOO.widget.Button.addHiddenFieldsToForm = function(p_oForm) {
+
+ var aButtons = Dom.getElementsByClassName("yuibutton", "*", p_oForm),
+ nButtons = aButtons.length;
+
+
+ if(nButtons > 0) {
+
+
+ var oButton = null,
+ sType = null,
+ oMenuItem = null,
+ oMenu = null;
+
+ for(var i=0; iElement.addListener for more
+* information on listening for this event.
+* @type YAHOO.util.CustomEvent
+*/
+
+
+/**
+* @event blur
+* @description Fires when the menu item loses the input focus. Passes back a
+* single object representing the original DOM event object passed back by the
+* event utility (YAHOO.util.Event) when the event was fired. See Element.addListener for more
+* information on listening for this event.
+* @type YAHOO.util.CustomEvent
+*/
+
+
+/**
+* @event option
+* @description Fires when the user invokes the button's option. Passes back a
+* single object representing the original DOM event (either "mousedown" or
+* "keydown") that caused the "option" event to fire. See Element.addListener for more
+* information on listening for this event.
+* @type YAHOO.util.CustomEvent
+*/
+
+
+/**
+* @event init
+* @description Fires when the Button is initialized. Subscribe to this event
+* by specifying a value for the "oninit" configuration attribute. Format:
+* { fn: Function, // The handler to call
+* when the event fires. obj: Object, // An object
+* to pass back to the handler. scope: Object //
+* The object to use for the scope of the handler. }
+* @type YAHOO.util.CustomEvent
+*/
+
+})();
+(function() {
+
+// Shorthard for utilities
+
+var Dom = YAHOO.util.Dom,
+ Event = YAHOO.util.Event,
+ Lang = YAHOO.lang,
+ Button = YAHOO.widget.Button;
+
+ // Private collection of radio buttons
+
+ m_oButtons = {};
+
+
+
+/**
+* The ButtonGroup class creates a set of buttons that are mutually exclusive;
+* checking one button in the set will uncheck all others in the button group.
+* @param {String} p_oElement String specifying the id attribute of the
+* <div> element of the button group.
+* @param {HTMLDivElement} p_oElement Object
+* specifying the <div> element of the button group.
+* @param {Object} p_oElement Object literal specifying a set of
+* configuration attributes used to create the button group.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button group.
+* @namespace YAHOO.widget
+* @class ButtonGroup
+* @constructor
+* @extends YAHOO.util.Element
+*/
+YAHOO.widget.ButtonGroup = function(p_oElement, p_oAttributes) {
+
+ var fnSuperClass = YAHOO.widget.ButtonGroup.superclass.constructor;
+
+ if(
+ arguments.length == 1 &&
+ !Lang.isString(p_oElement) &&
+ !p_oElement.nodeName
+ ) {
+
+ if(!p_oElement.id) {
+
+ var sId = Dom.generateId();
+
+ p_oElement.id = sId;
+
+
+ }
+
+
+
+ fnSuperClass.call(this, (this._createGroupElement()), p_oElement);
+
+ }
+ else if(Lang.isString(p_oElement)) {
+
+ var me = this;
+
+ Event.onContentReady(p_oElement, function() {
+
+ if(this.nodeName.toUpperCase() == me.TAG_NAME) {
+
+
+ fnSuperClass.call(me, this, p_oAttributes);
+
+ }
+
+ });
+
+ }
+ else {
+
+ var sNodeName = p_oElement.nodeName;
+
+ if(sNodeName && sNodeName == this.TAG_NAME) {
+
+ if(!p_oElement.id) {
+
+ p_oElement.id = Dom.generateId();
+
+
+ }
+
+
+ fnSuperClass.call(this, p_oElement, p_oAttributes);
+
+ }
+
+ }
+
+};
+
+
+YAHOO.extend(YAHOO.widget.ButtonGroup, YAHOO.util.Element, {
+
+
+// Protected properties
+
+
+/**
+* @property _buttons
+* @description Array of buttons in the button group.
+* @default null
+* @protected
+* @type Array
+*/
+_buttons: null,
+
+
+/**
+* @property _oninitAttributeValue
+* @description Object reference to the button group's current value for the
+* "oninit" configuration attribute.
+* @default null
+* @protected
+* @type Object
+*/
+_oninitAttributeValue: null,
+
+
+
+// Constants
+
+
+/**
+* @property TAG_NAME
+* @description The name of the tag to be used for the button group's element.
+* @default "DIV"
+* @final
+* @type String
+*/
+TAG_NAME: "DIV",
+
+
+/**
+* @property CSS_CLASS_NAME
+* @description String representing the CSS class(es) to be applied to the
+* button group's element.
+* @default "yuibuttongroup"
+* @final
+* @type String
+*/
+CSS_CLASS_NAME: "yuibuttongroup",
+
+
+
+// Protected methods
+
+
+/**
+* @method _createGroupElement
+* @description Creates the button group's element.
+* @protected
+* @return {HTMLDivElement}
+*/
+_createGroupElement: function() {
+
+ var oElement = document.createElement(this.TAG_NAME);
+
+ oElement.className = this.CSS_CLASS_NAME;
+
+ return oElement;
+
+},
+
+
+
+// Protected attribute setter methods
+
+
+/**
+* @method _setDisabled
+* @description Sets the value of the button groups's "disabled" attribute.
+* @protected
+* @param {Boolean} p_bDisabled Boolean indicating the value for the button
+* group's "disabled" attribute.
+*/
+_setDisabled: function(p_bDisabled) {
+
+ var nButtons = this.getCount();
+
+ if(nButtons > 0) {
+
+ var i = nButtons - 1;
+
+ do {
+
+ this._buttons[i].set("disabled", p_bDisabled);
+
+ }
+ while(i--);
+
+ }
+
+},
+
+
+/**
+* @method _setOnInit
+* @description Sets the value of the button group's "init" attribute.
+* @protected
+* @param {Object} p_oObject Object indicating the value for the button's
+* "oninit" attribute.
+*/
+_setOnInit: function(p_oObject) {
+
+ /*
+ Remove any existing listeners if a "init" event handler has already
+ been specified.
+ */
+
+ if(
+ this._oninitAttributeValue &&
+ (this._oninitAttributeValue != p_oObject)
+ ) {
+
+ this.removeListener("init", this._oninitAttributeValue.fn);
+
+ this._oninitAttributeValue = null;
+
+ }
+
+
+ if(
+ !this._oninitAttributeValue &&
+ Lang.isObject(p_oObject) &&
+ Lang.isFunction(p_oObject.fn)
+ ) {
+
+ this.on("init", p_oObject.fn, p_oObject.obj, p_oObject.scope);
+
+ this._oninitAttributeValue = p_oObject;
+
+ }
+
+},
+
+
+// Protected event handlers
+
+
+/**
+* @method _onKeyDown
+* @description "keydown" event handler for the button group.
+* @protected
+* @param {Event} p_oEvent Object representing the DOM event object passed
+* back by the event utility (YAHOO.util.Event).
+*/
+_onKeyDown: function(p_oEvent) {
+
+ var oTarget = Event.getTarget(p_oEvent),
+ nCharCode = Event.getCharCode(p_oEvent),
+ sId = oTarget.parentNode.parentNode.id,
+ oButton = m_oButtons[sId],
+ nIndex = -1;
+
+
+ if(nCharCode == 37 || nCharCode == 38) {
+
+ nIndex = (oButton.index === 0) ?
+ (this._buttons.length -1) : (oButton.index - 1);
+
+ }
+ else if(nCharCode == 39 || nCharCode == 40) {
+
+ nIndex = (oButton.index === (this._buttons.length - 1)) ?
+ 0 : (oButton.index + 1);
+
+ }
+
+
+ if(nIndex > -1) {
+
+ this.check(nIndex);
+ this.getButton(nIndex).focus();
+
+ }
+
+},
+
+
+/**
+* @method _onAppendTo
+* @description "appendTo" event handler for the button group.
+* @protected
+* @param {Event} p_oEvent Object representing the event that was fired.
+*/
+_onAppendTo: function(p_oEvent) {
+
+ var aButtons = this._buttons,
+ nButtons = aButtons.length;
+
+ for(var i=0; iYAHOO.widget.Button} p_oButton
+* Object representing the button that
+* fired the event.
+*/
+_onButtonCheckedChange: function(p_oEvent, p_oButton) {
+
+ var bChecked = p_oEvent.newValue,
+ oCheckedButton = this.get("checkedButton");
+
+ if(bChecked && oCheckedButton != p_oButton) {
+
+ if(oCheckedButton) {
+
+ oCheckedButton.set("checked", false, true);
+
+ }
+
+ this.set("checkedButton", p_oButton);
+ this.set("value", p_oButton.get("value"));
+
+ }
+ else if(oCheckedButton && !oCheckedButton.set("checked")) {
+
+ oCheckedButton.set("checked", true, true);
+
+ }
+
+},
+
+
+
+// Public methods
+
+
+/**
+* @method init
+* @description The ButtonGroup class's initialization method.
+* @param {String} p_oElement String specifying the id attribute of the
+* <div> element of the button group.
+* @param {HTMLDivElement} p_oElement Object
+* specifying the <div> element of the button group.
+* @param {Object} p_oElement Object literal specifying a set of configuration
+* attributes used to create the button group.
+* @param {Object} p_oAttributes Optional. Object literal specifying a set of
+* configuration attributes used to create the button group.
+*/
+init: function(p_oElement, p_oAttributes) {
+
+ this._buttons = [];
+
+ YAHOO.widget.ButtonGroup.superclass.init.call(
+ this, p_oElement,
+ p_oAttributes
+ );
+
+
+
+ var aButtons = this.getElementsByClassName("yuibutton");
+
+
+ if(aButtons.length > 0) {
+
+
+ this.addButtons(aButtons);
+
+ }
+
+
+
+ function isRadioButton(p_oElement) {
+
+ return (p_oElement.type == "radio");
+
+ }
+
+ aButtons = Dom.getElementsBy(isRadioButton, "input", this.get("element"));
+
+
+ if(aButtons.length > 0) {
+
+
+ this.addButtons(aButtons);
+
+ }
+
+ this.on("keydown", this._onKeyDown);
+ this.on("appendTo", this._onAppendTo);
+
+ var oContainer = this.get("container");
+
+ if(oContainer) {
+
+ if(Lang.isString(oContainer)) {
+
+ var me = this;
+
+ Event.onContentReady(oContainer, function() {
+
+ me.appendTo(this);
+
+ });
+
+ }
+ else {
+
+ this.appendTo(oContainer);
+
+ }
+
+ }
+
+
+ this.fireEvent("init");
+
+
+},
+
+
+/**
+* @method initAttributes
+* @description Initializes all of the configuration attributes used to create
+* the button group.
+* @param {Object} p_oAttributes Object literal specifying a set of
+* configuration attributes used to create the button group.
+*/
+initAttributes: function(p_oAttributes) {
+
+ var oAttributes = p_oAttributes || {};
+
+ YAHOO.widget.ButtonGroup.superclass.initAttributes.call(
+ this,
+ oAttributes
+ );
+
+
+ /**
+ * @config name
+ * @description String specifying the name for the button group. This
+ * name will be applied to each button in the button group.
+ * @default null
+ * @type String
+ */
+ this.setAttributeConfig("name", {
+
+ value: oAttributes.name,
+ validator: Lang.isString
+
+ });
+
+
+ /**
+ * @config disabled
+ * @description Boolean indicating if the button group should be disabled.
+ * Disabling the button group will disable each button in the button group.
+ * Disabled buttons are dimmed and will not respond to user input
+ * or fire events.
+ * @default false
+ * @type Boolean
+ */
+ this.setAttributeConfig("disabled", {
+
+ value: (oAttributes.disabled || false),
+ validator: Lang.isBoolean,
+ method: this._setDisabled
+
+ });
+
+
+ /**
+ * @config value
+ * @description Object specifying the value for the button group.
+ * @default null
+ * @type Object
+ */
+ this.setAttributeConfig("value", {
+
+ value: oAttributes.value
+
+ });
+
+
+ /**
+ * @config container
+ * @description HTML element reference or string specifying the id
+ * attribute of the HTML element that the button group's markup should be
+ * rendered into.
+ * @type HTMLElement|String
+ * @default null
+ */
+ this.setAttributeConfig("container", {
+
+ value: oAttributes.container
+
+ });
+
+
+ /**
+ * @config checkedButton
+ * @description Reference for the button in the button group that
+ * is checked.
+ * @type {YAHOO.widget.Button}
+ * @default null
+ */
+ this.setAttributeConfig("checkedButton", {
+
+ value: null
+
+ });
+
+
+ /**
+ * @config oninit
+ * @description Object literal representing the code to be executed when
+ * the button group is initialized. Format: {
+ * fn: Function, // The handler to call when the
+ * event fires. obj: Object, // An object to
+ * pass back to the handler. scope: Object //
+ * The object to use for the scope of the handler. }
+ * @type Object
+ * @default null
+ */
+ this.setAttributeConfig("oninit", {
+
+ value: oAttributes.oninit,
+ method: this._setOnInit
+
+ });
+
+},
+
+
+/**
+* @method addButton
+* @description Adds the button to the button group.
+* @param {YAHOO.widget.Button} p_oButton
+* Object reference for the
+* YAHOO.widget.Button instance to be added to the button group.
+* @param {String} p_oButton String specifying the id attribute of the
+* <input> or <span> element to be
+* used to create the button to be added to the button group.
+* @param {HTMLInputElement|HTMLElement} p_oButton Object reference for the
+* <input> or <span> element to be
+* used to create the button to be added to the button group.
+* @param {Object} p_oButton Object literal specifying a set of
+* YAHOO.widget.Button configuration
+* attributes used to configure the button to be added to the button group.
+* @return {YAHOO.widget.Button}
+*/
+addButton: function(p_oButton) {
+
+ var oButton;
+
+
+ if(p_oButton instanceof Button && p_oButton.get("type") == "radio") {
+
+ oButton = p_oButton;
+
+ }
+ else if(!Lang.isString(p_oButton) && !p_oButton.nodeName) {
+
+ p_oButton.type = "radio";
+
+ oButton = new Button(p_oButton);
+
+ }
+ else {
+
+ oButton = new Button(p_oButton, { type: "radio" });
+
+ }
+
+
+ if(oButton) {
+
+ var nIndex = this._buttons.length,
+ sButtonName = oButton.get("name"),
+ sGroupName = this.get("name");
+
+ oButton.index = nIndex;
+
+ this._buttons[nIndex] = oButton;
+ m_oButtons[oButton.get("id")] = oButton;
+
+
+ if(sButtonName != sGroupName) {
+
+ oButton.set("name", sGroupName);
+
+ }
+
+
+ if(this.get("disabled")) {
+
+ oButton.set("disabled", true);
+
+ }
+
+
+ if(oButton.get("checked")) {
+
+ this.set("checkedButton", oButton);
+
+ }
+
+
+ oButton.on("checkedChange", this._onButtonCheckedChange, oButton, this);
+
+
+ return oButton;
+
+ }
+
+},
+
+
+/**
+* @method addButtons
+* @description Adds the array of buttons to the button group.
+* @param {Array} p_aButtons Array of
+* YAHOO.widget.Button instances to be added
+* to the button group.
+* @param {Array} p_aButtons Array of strings specifying the id attribute of
+* the <input> or <span> elements to
+* be used to create the buttons to be added to the button group.
+* @param {Array} p_aButtons Array of object references for the
+* <input> or <span> elements to be
+* used to create the buttons to be added to the button group.
+* @param {Array} p_aButtons Array of object literals, each containing a set of
+* YAHOO.widget.Button configuration
+* attributes used to configure each button to be added to the button group.
+* @return {Array}
+*/
+addButtons: function(p_aButtons) {
+
+ if(Lang.isArray(p_aButtons)) {
+
+ var nButtons = p_aButtons.length,
+ oButton,
+ aButtons = [];
+
+ if(nButtons > 0) {
+
+ for(var i=0; i 0) {
+
+
+ return aButtons;
+
+ }
+
+ }
+
+ }
+
+},
+
+
+/**
+* @method removeButton
+* @description Removes the button at the specified index from the button group.
+* @param {Number} p_nIndex Number specifying the index of the button to be
+* removed from the button group.
+*/
+removeButton: function(p_nIndex) {
+
+ var oButton = this.getButton(p_nIndex);
+
+ if(oButton) {
+
+
+ this._buttons.splice(p_nIndex, 1);
+ delete m_oButtons[oButton.get("id")];
+
+ oButton.removeListener("checkedChange", this._onButtonCheckedChange);
+ oButton.destroy();
+
+
+ var nButtons = this._buttons.length;
+
+ if(nButtons > 0) {
+
+ var i = this._buttons.length - 1;
+
+ do {
+
+ this._buttons[i].index = i;
+
+ }
+ while(i--);
+
+ }
+
+
+ }
+
+},
+
+
+/**
+* @method getButton
+* @description Returns the button at the specified index.
+* @param {Number} p_nIndex The index of the button to retrieve from the
+* button group.
+* @return {YAHOO.widget.Button}
+*/
+getButton: function(p_nIndex) {
+
+ if(Lang.isNumber(p_nIndex)) {
+
+ return this._buttons[p_nIndex];
+
+ }
+
+},
+
+
+/**
+* @method getButtons
+* @description Returns an array of the buttons in the button group.
+* @return {Array}
+*/
+getButtons: function() {
+
+ return this._buttons;
+
+},
+
+
+/**
+* @method getCount
+* @description Returns the number of buttons in the button group.
+* @return {Number}
+*/
+getCount: function() {
+
+ return this._buttons.length;
+
+},
+
+
+/**
+* @method focus
+* @description Sets focus to the button at the specified index.
+* @param {Number} p_nIndex Number indicating the index of the button to focus.
+*/
+focus: function(p_nIndex) {
+
+ var oButton;
+
+ if(Lang.isNumber(p_nIndex)) {
+
+ oButton = this._buttons[p_nIndex];
+
+ if(oButton) {
+
+ oButton.focus();
+
+ }
+
+ }
+ else {
+
+ var nButtons = this.getCount();
+
+ for(var i=0; i 0) {
+
+ var i = this._buttons.length - 1;
+
+ do {
+
+ this._buttons[i].destroy();
+
+ }
+ while(i--);
+
+ }
+
+
+ Event.purgeElement(oElement);
+
+
+ oParentNode.removeChild(oElement);
+
+},
+
+
+/**
+* @method toString
+* @description Returns a string representing the button group.
+* @return {String}
+*/
+toString: function() {
+
+ return ("ButtonGroup " + this.get("id"));
+
+}
+
+});
+
+
+
+// Events
+
+
+/**
+* @event init
+* @description Fires when the button group is initialized. Subscribe to this
+* event by specifying a value for the "oninit" configuration attribute.
+* Format: { fn: Function, // The
+* handler to call when the event fires. obj: Object,
+* // An object to pass back to the handler. scope:
+* Object // The object to use for the scope of the handler.
+* }
+* @type YAHOO.util.CustomEvent
+*/
+
+})();
+YAHOO.register("button", YAHOO.widget.Button, {version: "2.2.0", build: "127"});
diff --git a/interface/ispconfig/interface/js/yui/calendar/README b/interface/ispconfig/interface/js/yui/calendar/README
new file mode 100644
index 0000000000000000000000000000000000000000..f0ddd1214bd0ecdd5d13e73f0d3c1f19a08195b3
--- /dev/null
+++ b/interface/ispconfig/interface/js/yui/calendar/README
@@ -0,0 +1,88 @@
+Calendar Release Notes
+
+*** version 2.2.0 ***
+
+ - Image customization can now be done through CSS. Images for Close, Left and Right Arrows are now pulled in using CSS defined in calendar.css and by default use relative paths to the images in the same directory as calendar.css.
+ - Deprecated Calendar.IMG_ROOT and NAV_ARROW_LEFT, NAV_ARROW_RIGHT configuration properties. Customizations based on older releases which set these properties will still function as expected.
+ - Deprecated CalendarGroup.CSS_2UPCLOSE. Calendar's Style.CSS_CLOSE property now represents the new default CSS class (calclose) for the close button. CSS_2UPCLOSE is still applied along with CSS_CLOSE to the new markup for the close button to support existing customizations of the CSS_2UPCLOSE CSS class (close-icon)
+ - Fixed problem with Safari setting Calendar pages to incorrect dates if the pages spanned a year boundary in CalendarGroups with 3 or more pages, due to a bug in Safari's implementation of Date setMonth
+ - Fixed problem with CalendarGroup setMonth rendering Calendar pages with incorrect dates in all browsers if current pages spanned year boundary
+ - Fixed incorrect CalendarGroup logging statement in calendar-debug.js
+ - Fixed domEventMap support for Safari versions prior to 2.0.2, caused by hasOwnProperty not being supported
+ - Removed unused private property : _pageDate from Calendar class
+
+*** version 0.12.2 ***
+
+ - Corrected documentation for clearTime function to reflect the change from midnight to noon
+
+*** version 0.12.1 ***
+
+ - Calendar and CalendarGroup now automatically parse the argument passed to setMonth and setYear into an integer, eliminating potential concatenation bugs.
+
+*** version 0.12 ***
+
+ - New documentation format implemented
+ - Calendar2up and Calendar_Core are now deprecated. Now, Calendar alone represents the single Calendar instance, and CalendarGroup represents an n-up instance, defaulting to 2up
+ - Added semantic style classes to Calendar elements to allow for custom styling solely using CSS.
+ - Remapped all configuration properties to use the Config object (familiar to those who use the Container collection of controls). Property names are the same as their previous counterparts, but wrapped into Calendar.cfg, allowing for runtime reconfiguration of most properties
+ - Added "title" property for setting the Calendar title
+ - Added "close" property for enabling and disabling the close icon
+ - Added "iframe" property for enabling an iframe shim in Internet Explorer 6 and below to fix the select bleed-through bug
+ - pageDate moved to property: "pagedate"
+ - selectedDates moved to property: "selected"
+ - minDate moved to property : "mindate", which accepts a JavaScript Date object like its predecessor, but also supports string dates
+ - maxDate moved to property : "maxdate", which accepts a JavaScript Date object like its predecessor, but also supports string dates
+ - Moved style declarations to initStyles function
+ - Optimized event handling in doSelectCell/doCellMouseOver/doCellMouseOut by only attaching the listener to the outer Calendar container, and only reacting to events on cells with the "selectable" CSS class.
+ - Added domEventMap field for applying DOM event listeners to cells containing specific class and tag combinations.
+ - Moved all cell DOM event attachment to applyListeners function
+ - Added getDateByCellId / getDateFieldsByCellId helper functions
+ - Corrected DateMath.getWeekNumber to comply with ISO week number handling
+ - Separated renderCellDefault style portions into styleCellDefault function for easy extension
+ - Deprecated onBeforeSelect. Created beforeSelectEvent which automatically subscribes to its deprecated predecessor.
+ - Deprecated onSelect. Created selectEvent, which automatically subscribes to its deprecated predecessor.
+ - Deprecated onBeforeDeselect. Created beforeSelectEvent which automatically subscribes to its deprecated predecessor.
+ - Deprecated onDeselect. Created beforeDeselectEvent, which automatically subscribes to its deprecated predecessor.
+ - Deprecated onChangePage. Created changePageEvent, which automatically subscribes to its deprecated predecessor.
+ - Deprecated onRender. Created renderEvent, which automatically subscribes to its deprecated predecessor.
+ - Deprecated onReset. Created resetEvent, which automatically subscribes to its deprecated predecessor.
+ - Deprecated onClear. Created clearEvent, which automatically subscribes to its deprecated predecessor.
+ - Corrected setMonth documentation to refer to 0-11 indexed months.
+ - Added show and hide methods to Calendar for setting the Calendar's display property.
+ - Optimized internal render classes to use innerHTML and string buffers
+ - Removed wireCustomEvents function
+ - Removed wireDefaultEvents function
+ - Removed doNextMonth / doPreviousMonth
+ - Removed all buildShell (header, body, footer) functions, since the Calendar shell is now built dynamically on each render
+ - Wired all CalendarGroup events and configuration properties to be properly delegated to Calendar
+ - Augmented CalendarGroup with all built-in renderers, label functions, hide, show, and initStyles, creating API transparency between Calendar and CalendarGroup.
+ - Made all tagName, createElement, and entity references XHTML compliant
+ - Fixed Daylight Saving Time bug for Brazilian time zone
+
+*** version 0.11.3 ***
+
+ - Calendar_Core: Added arguments for selected/deselected dates to onSelect/onDeselect
+ - CalendarGroup: Fixed bug where selected dates passed to constructor were not represented in selectedDates
+ - Calendar2up: Now displays correctly in Opera 9
+
+*** version 0.11.0 ***
+
+ - DateMath: DateMath.add now properly adds weeks
+ - DateMath: between() function added
+ - DateMath: getWeekNumber() fixed to take starting day of week into account
+ - All references to Calendar's built in CSS class handlers are removed, replaced with calls to Dom utility (addClass, removeClass)
+ - Several CSS class constants now have clearer names
+ - All CSS classes are now properly namespaced to avoid CSS conflicts
+ - Fixed table:hover bug in CSS
+ - Calendar no longer requires the container ID and variable name to match in order for month navigation to function properly
+ - Calendar month navigation arrows are now represented as background images
+
+*** version 0.10.0 ***
+
+ - Major performance improvements from attaching DOM events to associated table cells only once, when the Calendar shell is built
+ - DOM events for mouseover/mouseout are now fired for all browsers (not just Internet Explorer)
+ - Reset functionality bug fixed for 2-up Calendar view
+
+*** version 0.9.0 ***
+
+* Initial release
diff --git a/interface/ispconfig/interface/js/yui/calendar/assets/calendar.css b/interface/ispconfig/interface/js/yui/calendar/assets/calendar.css
new file mode 100644
index 0000000000000000000000000000000000000000..8a91844c59b1186dbc03398bb4276bdadece066c
--- /dev/null
+++ b/interface/ispconfig/interface/js/yui/calendar/assets/calendar.css
@@ -0,0 +1,197 @@
+/*
+Copyright (c) 2007, Yahoo! Inc. All rights reserved.
+Code licensed under the BSD License:
+http://developer.yahoo.net/yui/license.txt
+version: 2.2.0
+*/
+.yui-calcontainer {
+ position:relative;
+ padding:5px;
+ background-color:#F7F9FB;
+ border:1px solid #7B9EBD;
+ float:left;
+ overflow:hidden;
+}
+
+.yui-calcontainer iframe {
+ position:absolute;
+ border:none;
+ margin:0;padding:0;
+ left:-1px;
+ top:-1px;
+ z-index:0;
+ width:50em;
+ height:50em;
+}
+
+.yui-calcontainer.multi {
+ padding:0;
+}
+
+.yui-calcontainer.multi .groupcal {
+ padding:5px;
+ background-color:transparent;
+ z-index:1;
+ float:left;
+ position:relative;
+ border:none;
+}
+
+.yui-calcontainer .title {
+ font:100% sans-serif;
+ color:#000;
+ font-weight:bold;
+ margin-bottom:5px;
+ height:25px;
+ position:absolute;
+ top:3px;left:5px;
+ z-index:1;
+}
+
+.yui-calcontainer .close-icon {
+ position:absolute;
+ right:3px;
+ top:3px;
+ border:none;
+ z-index:1;
+}
+
+.yui-calcontainer .calclose {
+ background: url("calx.gif") no-repeat;
+ width:17px;
+ height:13px;
+ cursor:pointer;
+}
+
+/* Calendar element styles */
+
+.yui-calendar {
+ font:100% sans-serif;
+ text-align:center;
+ border-spacing:0;
+ border-collapse:separate;
+ position:relative;
+}
+
+.yui-calcontainer.withtitle {
+ padding-top:1.5em;
+}
+
+.yui-calendar .calnavleft {
+ position:absolute;
+ cursor:pointer;
+ top:2px;
+ bottom:0;
+ width:9px;
+ height:12px;
+ left:2px;
+ z-index:1;
+ background: url("callt.gif") no-repeat;
+}
+
+.yui-calendar .calnavright {
+ position:absolute;
+ cursor:pointer;
+ top:2px;
+ bottom:0;
+ width:9px;
+ height:12px;
+ right:2px;
+ z-index:1;
+ background: url("calrt.gif") no-repeat;
+}
+
+.yui-calendar td.calcell {
+ padding:.1em .2em;
+ border:1px solid #E0E0E0;
+ text-align:center;
+}
+
+.yui-calendar td.calcell a {
+ color:#003DB8;
+ text-decoration:none;
+}
+
+.yui-calendar td.calcell.today {
+ border:1px solid #000;
+}
+
+.yui-calendar td.calcell.oom {
+ cursor:default;
+ color:#999;
+ background-color:#EEE;
+ border:1px solid #E0E0E0;
+}
+
+.yui-calendar td.calcell.selected {
+ color:#003DB8;
+ background-color:#FFF19F;
+ border:1px solid #FF9900;
+}
+
+.yui-calendar td.calcell.calcellhover {
+ cursor:pointer;
+ color:#FFF;
+ background-color:#FF9900;
+ border:1px solid #FF9900;
+}
+
+.yui-calendar td.calcell.calcellhover a {
+ color:#FFF;
+}
+
+.yui-calendar td.calcell.restricted {
+ text-decoration:line-through;
+}
+
+.yui-calendar td.calcell.previous {
+ color:#CCC;
+}
+
+.yui-calendar td.calcell.highlight1 { background-color:#CCFF99; }
+.yui-calendar td.calcell.highlight2 { background-color:#99CCFF; }
+.yui-calendar td.calcell.highlight3 { background-color:#FFCCCC; }
+.yui-calendar td.calcell.highlight4 { background-color:#CCFF99; }
+
+.yui-calendar .calhead {
+ border:1px solid #E0E0E0;
+ vertical-align:middle;
+ background-color:#FFF;
+}
+
+.yui-calendar .calheader {
+ position:relative;
+ width:100%;
+ text-align:center;
+}
+
+.yui-calendar .calheader img {
+ border:none;
+}
+
+.yui-calendar .calweekdaycell {
+ color:#666;
+ font-weight:normal;
+ text-align:center;
+ width:1.5em;
+}
+
+.yui-calendar .calfoot {
+ background-color:#EEE;
+}
+
+.yui-calendar .calrowhead, .yui-calendar .calrowfoot {
+ color:#666;
+ font-size:9px;
+ font-style:italic;
+ font-weight:normal;
+ width:15px;
+}
+
+.yui-calendar .calrowhead {
+ border-right-width:2px;
+}
+
+/* Specific changes for calendar running under fonts/reset */
+.yui-calendar .calbody a:hover {background:inherit;}
+p#clear {clear:left; padding-top:10px;}
diff --git a/interface/ispconfig/interface/js/yui/calendar/assets/callt.gif b/interface/ispconfig/interface/js/yui/calendar/assets/callt.gif
new file mode 100644
index 0000000000000000000000000000000000000000..a6cc8da5b221d372ea075b3a4a10211d3a23cb51
Binary files /dev/null and b/interface/ispconfig/interface/js/yui/calendar/assets/callt.gif differ
diff --git a/interface/ispconfig/interface/js/yui/calendar/assets/calrt.gif b/interface/ispconfig/interface/js/yui/calendar/assets/calrt.gif
new file mode 100644
index 0000000000000000000000000000000000000000..ee137b2ff769d99132234b67f1e528daf65cb397
Binary files /dev/null and b/interface/ispconfig/interface/js/yui/calendar/assets/calrt.gif differ
diff --git a/interface/ispconfig/interface/js/yui/calendar/assets/calx.gif b/interface/ispconfig/interface/js/yui/calendar/assets/calx.gif
new file mode 100644
index 0000000000000000000000000000000000000000..27e7bc36e4524623db3c43f4d86717a703f37406
Binary files /dev/null and b/interface/ispconfig/interface/js/yui/calendar/assets/calx.gif differ
diff --git a/interface/ispconfig/interface/js/yui/calendar/calendar-debug.js b/interface/ispconfig/interface/js/yui/calendar/calendar-debug.js
new file mode 100644
index 0000000000000000000000000000000000000000..9e60a1c96dafdbc0115d2b7d8eb08cca042d57a5
--- /dev/null
+++ b/interface/ispconfig/interface/js/yui/calendar/calendar-debug.js
@@ -0,0 +1,4331 @@
+/*
+Copyright (c) 2007, Yahoo! Inc. All rights reserved.
+Code licensed under the BSD License:
+http://developer.yahoo.net/yui/license.txt
+version: 2.2.0
+*/
+/**
+* Config is a utility used within an Object to allow the implementer to maintain a list of local configuration properties and listen for changes to those properties dynamically using CustomEvent. The initial values are also maintained so that the configuration can be reset at any given point to its initial state.
+* @namespace YAHOO.util
+* @class Config
+* @constructor
+* @param {Object} owner The owner Object to which this Config Object belongs
+*/
+YAHOO.util.Config = function(owner) {
+ if (owner) {
+ this.init(owner);
+ }
+ if (!owner) { YAHOO.log("No owner specified for Config object", "error"); }
+};
+
+YAHOO.util.Config.prototype = {
+
+ /**
+ * Object reference to the owner of this Config Object
+ * @property owner
+ * @type Object
+ */
+ owner : null,
+
+ /**
+ * Boolean flag that specifies whether a queue is currently being executed
+ * @property queueInProgress
+ * @type Boolean
+ */
+ queueInProgress : false,
+
+
+ /**
+ * Validates that the value passed in is a Boolean.
+ * @method checkBoolean
+ * @param {Object} val The value to validate
+ * @return {Boolean} true, if the value is valid
+ */
+ checkBoolean: function(val) {
+ if (typeof val == 'boolean') {
+ return true;
+ } else {
+ return false;
+ }
+ },
+
+ /**
+ * Validates that the value passed in is a number.
+ * @method checkNumber
+ * @param {Object} val The value to validate
+ * @return {Boolean} true, if the value is valid
+ */
+ checkNumber: function(val) {
+ if (isNaN(val)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+};
+
+
+/**
+* Initializes the configuration Object and all of its local members.
+* @method init
+* @param {Object} owner The owner Object to which this Config Object belongs
+*/
+YAHOO.util.Config.prototype.init = function(owner) {
+
+ this.owner = owner;
+
+ /**
+ * Object reference to the owner of this Config Object
+ * @event configChangedEvent
+ */
+ this.configChangedEvent = new YAHOO.util.CustomEvent("configChanged");
+ this.queueInProgress = false;
+
+ /* Private Members */
+
+ /**
+ * Maintains the local collection of configuration property objects and their specified values
+ * @property config
+ * @private
+ * @type Object
+ */
+ var config = {};
+
+ /**
+ * Maintains the local collection of configuration property objects as they were initially applied.
+ * This object is used when resetting a property.
+ * @property initialConfig
+ * @private
+ * @type Object
+ */
+ var initialConfig = {};
+
+ /**
+ * Maintains the local, normalized CustomEvent queue
+ * @property eventQueue
+ * @private
+ * @type Object
+ */
+ var eventQueue = [];
+
+ /**
+ * Fires a configuration property event using the specified value.
+ * @method fireEvent
+ * @private
+ * @param {String} key The configuration property's name
+ * @param {value} Object The value of the correct type for the property
+ */
+ var fireEvent = function( key, value ) {
+ YAHOO.log("Firing Config event: " + key + "=" + value, "info");
+ key = key.toLowerCase();
+
+ var property = config[key];
+
+ if (typeof property != 'undefined' && property.event) {
+ property.event.fire(value);
+ }
+ };
+ /* End Private Members */
+
+ /**
+ * Adds a property to the Config Object's private config hash.
+ * @method addProperty
+ * @param {String} key The configuration property's name
+ * @param {Object} propertyObject The Object containing all of this property's arguments
+ */
+ this.addProperty = function( key, propertyObject ) {
+ key = key.toLowerCase();
+ YAHOO.log("Added property: " + key, "info");
+
+ config[key] = propertyObject;
+
+ propertyObject.event = new YAHOO.util.CustomEvent(key);
+ propertyObject.key = key;
+
+ if (propertyObject.handler) {
+ propertyObject.event.subscribe(propertyObject.handler, this.owner, true);
+ }
+
+ this.setProperty(key, propertyObject.value, true);
+
+ if (! propertyObject.suppressEvent) {
+ this.queueProperty(key, propertyObject.value);
+ }
+ };
+
+ /**
+ * Returns a key-value configuration map of the values currently set in the Config Object.
+ * @method getConfig
+ * @return {Object} The current config, represented in a key-value map
+ */
+ this.getConfig = function() {
+ var cfg = {};
+
+ for (var prop in config) {
+ var property = config[prop];
+ if (typeof property != 'undefined' && property.event) {
+ cfg[prop] = property.value;
+ }
+ }
+
+ return cfg;
+ };
+
+ /**
+ * Returns the value of specified property.
+ * @method getProperty
+ * @param {String} key The name of the property
+ * @return {Object} The value of the specified property
+ */
+ this.getProperty = function(key) {
+ key = key.toLowerCase();
+
+ var property = config[key];
+ if (typeof property != 'undefined' && property.event) {
+ return property.value;
+ } else {
+ return undefined;
+ }
+ };
+
+ /**
+ * Resets the specified property's value to its initial value.
+ * @method resetProperty
+ * @param {String} key The name of the property
+ * @return {Boolean} True is the property was reset, false if not
+ */
+ this.resetProperty = function(key) {
+ key = key.toLowerCase();
+
+ var property = config[key];
+ if (typeof property != 'undefined' && property.event) {
+ if (initialConfig[key] && initialConfig[key] != 'undefined') {
+ this.setProperty(key, initialConfig[key]);
+ }
+ return true;
+ } else {
+ return false;
+ }
+ };
+
+ /**
+ * Sets the value of a property. If the silent property is passed as true, the property's event will not be fired.
+ * @method setProperty
+ * @param {String} key The name of the property
+ * @param {String} value The value to set the property to
+ * @param {Boolean} silent Whether the value should be set silently, without firing the property event.
+ * @return {Boolean} True, if the set was successful, false if it failed.
+ */
+ this.setProperty = function(key, value, silent) {
+ key = key.toLowerCase();
+ YAHOO.log("setProperty: " + key + "=" + value, "info");
+
+ if (this.queueInProgress && ! silent) {
+ this.queueProperty(key,value); // Currently running through a queue...
+ return true;
+ } else {
+ var property = config[key];
+ if (typeof property != 'undefined' && property.event) {
+ if (property.validator && ! property.validator(value)) { // validator
+ return false;
+ } else {
+ property.value = value;
+ if (! silent) {
+ fireEvent(key, value);
+ this.configChangedEvent.fire([key, value]);
+ }
+ return true;
+ }
+ } else {
+ return false;
+ }
+ }
+ };
+
+ /**
+ * Sets the value of a property and queues its event to execute. If the event is already scheduled to execute, it is
+ * moved from its current position to the end of the queue.
+ * @method queueProperty
+ * @param {String} key The name of the property
+ * @param {String} value The value to set the property to
+ * @return {Boolean} true, if the set was successful, false if it failed.
+ */
+ this.queueProperty = function(key, value) {
+ key = key.toLowerCase();
+ YAHOO.log("queueProperty: " + key + "=" + value, "info");
+
+ var property = config[key];
+
+ if (typeof property != 'undefined' && property.event) {
+ if (typeof value != 'undefined' && property.validator && ! property.validator(value)) { // validator
+ return false;
+ } else {
+
+ if (typeof value != 'undefined') {
+ property.value = value;
+ } else {
+ value = property.value;
+ }
+
+ var foundDuplicate = false;
+
+ for (var i=0;i 11) {
+ while (newMonth > 11) {
+ newMonth -= 12;
+ years += 1;
+ }
+ }
+
+ d.setMonth(newMonth);
+ d.setFullYear(date.getFullYear() + years);
+ break;
+ case this.DAY:
+ d.setDate(date.getDate() + amount);
+ break;
+ case this.YEAR:
+ d.setFullYear(date.getFullYear() + amount);
+ break;
+ case this.WEEK:
+ d.setDate(date.getDate() + (amount * 7));
+ break;
+ }
+ return d;
+ },
+
+ /**
+ * Subtracts the specified amount of time from the this instance.
+ * @method subtract
+ * @param {Date} date The JavaScript Date object to perform subtraction on
+ * @param {Number} field The this field constant to be used for performing subtraction.
+ * @param {Number} amount The number of units (measured in the field constant) to subtract from the date.
+ * @return {Date} The resulting Date object
+ */
+ subtract : function(date, field, amount) {
+ return this.add(date, field, (amount*-1));
+ },
+
+ /**
+ * Determines whether a given date is before another date on the calendar.
+ * @method before
+ * @param {Date} date The Date object to compare with the compare argument
+ * @param {Date} compareTo The Date object to use for the comparison
+ * @return {Boolean} true if the date occurs before the compared date; false if not.
+ */
+ before : function(date, compareTo) {
+ var ms = compareTo.getTime();
+ if (date.getTime() < ms) {
+ return true;
+ } else {
+ return false;
+ }
+ },
+
+ /**
+ * Determines whether a given date is after another date on the calendar.
+ * @method after
+ * @param {Date} date The Date object to compare with the compare argument
+ * @param {Date} compareTo The Date object to use for the comparison
+ * @return {Boolean} true if the date occurs after the compared date; false if not.
+ */
+ after : function(date, compareTo) {
+ var ms = compareTo.getTime();
+ if (date.getTime() > ms) {
+ return true;
+ } else {
+ return false;
+ }
+ },
+
+ /**
+ * Determines whether a given date is between two other dates on the calendar.
+ * @method between
+ * @param {Date} date The date to check for
+ * @param {Date} dateBegin The start of the range
+ * @param {Date} dateEnd The end of the range
+ * @return {Boolean} true if the date occurs between the compared dates; false if not.
+ */
+ between : function(date, dateBegin, dateEnd) {
+ if (this.after(date, dateBegin) && this.before(date, dateEnd)) {
+ return true;
+ } else {
+ return false;
+ }
+ },
+
+ /**
+ * Retrieves a JavaScript Date object representing January 1 of any given year.
+ * @method getJan1
+ * @param {Number} calendarYear The calendar year for which to retrieve January 1
+ * @return {Date} January 1 of the calendar year specified.
+ */
+ getJan1 : function(calendarYear) {
+ return new Date(calendarYear,0,1);
+ },
+
+ /**
+ * Calculates the number of days the specified date is from January 1 of the specified calendar year.
+ * Passing January 1 to this function would return an offset value of zero.
+ * @method getDayOffset
+ * @param {Date} date The JavaScript date for which to find the offset
+ * @param {Number} calendarYear The calendar year to use for determining the offset
+ * @return {Number} The number of days since January 1 of the given year
+ */
+ getDayOffset : function(date, calendarYear) {
+ var beginYear = this.getJan1(calendarYear); // Find the start of the year. This will be in week 1.
+
+ // Find the number of days the passed in date is away from the calendar year start
+ var dayOffset = Math.ceil((date.getTime()-beginYear.getTime()) / this.ONE_DAY_MS);
+ return dayOffset;
+ },
+
+ /**
+ * Calculates the week number for the given date. This function assumes that week 1 is the
+ * week in which January 1 appears, regardless of whether the week consists of a full 7 days.
+ * The calendar year can be specified to help find what a the week number would be for a given
+ * date if the date overlaps years. For instance, a week may be considered week 1 of 2005, or
+ * week 53 of 2004. Specifying the optional calendarYear allows one to make this distinction
+ * easily.
+ * @method getWeekNumber
+ * @param {Date} date The JavaScript date for which to find the week number
+ * @param {Number} calendarYear OPTIONAL - The calendar year to use for determining the week number. Default is
+ * the calendar year of parameter "date".
+ * @param {Number} weekStartsOn OPTIONAL - The integer (0-6) representing which day a week begins on. Default is 0 (for Sunday).
+ * @return {Number} The week number of the given date.
+ */
+ getWeekNumber : function(date, calendarYear) {
+ date = this.clearTime(date);
+ var nearestThurs = new Date(date.getTime() + (4 * this.ONE_DAY_MS) - ((date.getDay()) * this.ONE_DAY_MS));
+
+ var jan1 = new Date(nearestThurs.getFullYear(),0,1);
+ var dayOfYear = ((nearestThurs.getTime() - jan1.getTime()) / this.ONE_DAY_MS) - 1;
+
+ var weekNum = Math.ceil((dayOfYear)/ 7);
+ return weekNum;
+ },
+
+ /**
+ * Determines if a given week overlaps two different years.
+ * @method isYearOverlapWeek
+ * @param {Date} weekBeginDate The JavaScript Date representing the first day of the week.
+ * @return {Boolean} true if the date overlaps two different years.
+ */
+ isYearOverlapWeek : function(weekBeginDate) {
+ var overlaps = false;
+ var nextWeek = this.add(weekBeginDate, this.DAY, 6);
+ if (nextWeek.getFullYear() != weekBeginDate.getFullYear()) {
+ overlaps = true;
+ }
+ return overlaps;
+ },
+
+ /**
+ * Determines if a given week overlaps two different months.
+ * @method isMonthOverlapWeek
+ * @param {Date} weekBeginDate The JavaScript Date representing the first day of the week.
+ * @return {Boolean} true if the date overlaps two different months.
+ */
+ isMonthOverlapWeek : function(weekBeginDate) {
+ var overlaps = false;
+ var nextWeek = this.add(weekBeginDate, this.DAY, 6);
+ if (nextWeek.getMonth() != weekBeginDate.getMonth()) {
+ overlaps = true;
+ }
+ return overlaps;
+ },
+
+ /**
+ * Gets the first day of a month containing a given date.
+ * @method findMonthStart
+ * @param {Date} date The JavaScript Date used to calculate the month start
+ * @return {Date} The JavaScript Date representing the first day of the month
+ */
+ findMonthStart : function(date) {
+ var start = new Date(date.getFullYear(), date.getMonth(), 1);
+ return start;
+ },
+
+ /**
+ * Gets the last day of a month containing a given date.
+ * @method findMonthEnd
+ * @param {Date} date The JavaScript Date used to calculate the month end
+ * @return {Date} The JavaScript Date representing the last day of the month
+ */
+ findMonthEnd : function(date) {
+ var start = this.findMonthStart(date);
+ var nextMonth = this.add(start, this.MONTH, 1);
+ var end = this.subtract(nextMonth, this.DAY, 1);
+ return end;
+ },
+
+ /**
+ * Clears the time fields from a given date, effectively setting the time to 12 noon.
+ * @method clearTime
+ * @param {Date} date The JavaScript Date for which the time fields will be cleared
+ * @return {Date} The JavaScript Date cleared of all time fields
+ */
+ clearTime : function(date) {
+ date.setHours(12,0,0,0);
+ return date;
+ }
+};
+
+/**
+* The Calendar component is a UI control that enables users to choose one or more dates from a graphical calendar presented in a one-month ("one-up") or two-month ("two-up") interface. Calendars are generated entirely via script and can be navigated without any page refreshes.
+* @module calendar
+* @title Calendar
+* @namespace YAHOO.widget
+* @requires yahoo,dom,event
+*/
+
+/**
+* Calendar is the base class for the Calendar widget. In its most basic
+* implementation, it has the ability to render a calendar widget on the page
+* that can be manipulated to select a single date, move back and forth between
+* months and years.
+*
To construct the placeholder for the calendar widget, the code is as
+* follows:
+*
+*
+*
+* Note that the table can be replaced with any kind of element.
+*
+* @namespace YAHOO.widget
+* @class Calendar
+* @constructor
+* @param {String} id The id of the table element that will represent the calendar widget
+* @param {String} containerId The id of the container div element that will wrap the calendar table
+* @param {Object} config The configuration object containing the Calendar's arguments
+*/
+YAHOO.widget.Calendar = function(id, containerId, config) {
+ this.init(id, containerId, config);
+};
+
+/**
+* The path to be used for images loaded for the Calendar
+* @property YAHOO.widget.Calendar.IMG_ROOT
+* @static
+* @deprecated You can now customize images by overriding the calclose, calnavleft and calnavright default CSS classes for the close icon, left arrow and right arrow respectively
+* @type String
+*/
+YAHOO.widget.Calendar.IMG_ROOT = null;
+
+/**
+* Type constant used for renderers to represent an individual date (M/D/Y)
+* @property YAHOO.widget.Calendar.DATE
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.Calendar.DATE = "D";
+
+/**
+* Type constant used for renderers to represent an individual date across any year (M/D)
+* @property YAHOO.widget.Calendar.MONTH_DAY
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.Calendar.MONTH_DAY = "MD";
+
+/**
+* Type constant used for renderers to represent a weekday
+* @property YAHOO.widget.Calendar.WEEKDAY
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.Calendar.WEEKDAY = "WD";
+
+/**
+* Type constant used for renderers to represent a range of individual dates (M/D/Y-M/D/Y)
+* @property YAHOO.widget.Calendar.RANGE
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.Calendar.RANGE = "R";
+
+/**
+* Type constant used for renderers to represent a month across any year
+* @property YAHOO.widget.Calendar.MONTH
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.Calendar.MONTH = "M";
+
+/**
+* Constant that represents the total number of date cells that are displayed in a given month
+* @property YAHOO.widget.Calendar.DISPLAY_DAYS
+* @static
+* @final
+* @type Number
+*/
+YAHOO.widget.Calendar.DISPLAY_DAYS = 42;
+
+/**
+* Constant used for halting the execution of the remainder of the render stack
+* @property YAHOO.widget.Calendar.STOP_RENDER
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.Calendar.STOP_RENDER = "S";
+
+YAHOO.widget.Calendar.prototype = {
+
+ /**
+ * The configuration object used to set up the calendars various locale and style options.
+ * @property Config
+ * @private
+ * @deprecated Configuration properties should be set by calling Calendar.cfg.setProperty.
+ * @type Object
+ */
+ Config : null,
+
+ /**
+ * The parent CalendarGroup, only to be set explicitly by the parent group
+ * @property parent
+ * @type CalendarGroup
+ */
+ parent : null,
+
+ /**
+ * The index of this item in the parent group
+ * @property index
+ * @type Number
+ */
+ index : -1,
+
+ /**
+ * The collection of calendar table cells
+ * @property cells
+ * @type HTMLTableCellElement[]
+ */
+ cells : null,
+
+ /**
+ * The collection of calendar cell dates that is parallel to the cells collection. The array contains dates field arrays in the format of [YYYY, M, D].
+ * @property cellDates
+ * @type Array[](Number[])
+ */
+ cellDates : null,
+
+ /**
+ * The id that uniquely identifies this calendar. This id should match the id of the placeholder element on the page.
+ * @property id
+ * @type String
+ */
+ id : null,
+
+ /**
+ * The DOM element reference that points to this calendar's container element. The calendar will be inserted into this element when the shell is rendered.
+ * @property oDomContainer
+ * @type HTMLElement
+ */
+ oDomContainer : null,
+
+ /**
+ * A Date object representing today's date.
+ * @property today
+ * @type Date
+ */
+ today : null,
+
+ /**
+ * The list of render functions, along with required parameters, used to render cells.
+ * @property renderStack
+ * @type Array[]
+ */
+ renderStack : null,
+
+ /**
+ * A copy of the initial render functions created before rendering.
+ * @property _renderStack
+ * @private
+ * @type Array
+ */
+ _renderStack : null,
+
+ /**
+ * The private list of initially selected dates.
+ * @property _selectedDates
+ * @private
+ * @type Array
+ */
+ _selectedDates : null,
+
+ /**
+ * A map of DOM event handlers to attach to cells associated with specific CSS class names
+ * @property domEventMap
+ * @type Object
+ */
+ domEventMap : null
+};
+
+
+
+/**
+* Initializes the Calendar widget.
+* @method init
+* @param {String} id The id of the table element that will represent the calendar widget
+* @param {String} containerId The id of the container div element that will wrap the calendar table
+* @param {Object} config The configuration object containing the Calendar's arguments
+*/
+YAHOO.widget.Calendar.prototype.init = function(id, containerId, config) {
+ this.logger = new YAHOO.widget.LogWriter("Calendar_Core " + id);
+ this.initEvents();
+ this.today = new Date();
+ YAHOO.widget.DateMath.clearTime(this.today);
+
+ this.id = id;
+ this.oDomContainer = document.getElementById(containerId);
+ if (! this.oDomContainer) { this.logger.log("No valid container present.", "error"); }
+
+ /**
+ * The Config object used to hold the configuration variables for the Calendar
+ * @property cfg
+ * @type YAHOO.util.Config
+ */
+ this.cfg = new YAHOO.util.Config(this);
+
+ /**
+ * The local object which contains the Calendar's options
+ * @property Options
+ * @type Object
+ */
+ this.Options = {};
+
+ /**
+ * The local object which contains the Calendar's locale settings
+ * @property Locale
+ * @type Object
+ */
+ this.Locale = {};
+
+ this.initStyles();
+
+ YAHOO.util.Dom.addClass(this.oDomContainer, this.Style.CSS_CONTAINER);
+ YAHOO.util.Dom.addClass(this.oDomContainer, this.Style.CSS_SINGLE);
+
+ this.cellDates = [];
+ this.cells = [];
+ this.renderStack = [];
+ this._renderStack = [];
+
+ this.setupConfig();
+
+ if (config) {
+ this.cfg.applyConfig(config, true);
+ }
+
+ this.cfg.fireQueue();
+};
+
+/**
+* Renders the built-in IFRAME shim for the IE6 and below
+* @method configIframe
+*/
+YAHOO.widget.Calendar.prototype.configIframe = function(type, args, obj) {
+ var useIframe = args[0];
+
+ if (YAHOO.util.Dom.inDocument(this.oDomContainer)) {
+ if (useIframe) {
+ var pos = YAHOO.util.Dom.getStyle(this.oDomContainer, "position");
+
+ if (this.browser == "ie" && (pos == "absolute" || pos == "relative")) {
+ if (! YAHOO.util.Dom.inDocument(this.iframe)) {
+ this.iframe = document.createElement("iframe");
+ this.iframe.src = "javascript:false;";
+ YAHOO.util.Dom.setStyle(this.iframe, "opacity", "0");
+ this.oDomContainer.insertBefore(this.iframe, this.oDomContainer.firstChild);
+ }
+ }
+ } else {
+ if (this.iframe) {
+ if (this.iframe.parentNode) {
+ this.iframe.parentNode.removeChild(this.iframe);
+ }
+ this.iframe = null;
+ }
+ }
+ }
+};
+
+/**
+* Default handler for the "title" property
+* @method configTitle
+*/
+YAHOO.widget.Calendar.prototype.configTitle = function(type, args, obj) {
+ var title = args[0];
+ var close = this.cfg.getProperty("close");
+
+ var titleDiv;
+
+ if (title && title !== "") {
+ titleDiv = YAHOO.util.Dom.getElementsByClassName(YAHOO.widget.CalendarGroup.CSS_2UPTITLE, "div", this.oDomContainer)[0] || document.createElement("div");
+ titleDiv.className = YAHOO.widget.CalendarGroup.CSS_2UPTITLE;
+ titleDiv.innerHTML = title;
+ this.oDomContainer.insertBefore(titleDiv, this.oDomContainer.firstChild);
+ YAHOO.util.Dom.addClass(this.oDomContainer, "withtitle");
+ } else {
+ titleDiv = YAHOO.util.Dom.getElementsByClassName(YAHOO.widget.CalendarGroup.CSS_2UPTITLE, "div", this.oDomContainer)[0] || null;
+
+ if (titleDiv) {
+ YAHOO.util.Event.purgeElement(titleDiv);
+ this.oDomContainer.removeChild(titleDiv);
+ }
+ if (! close) {
+ YAHOO.util.Dom.removeClass(this.oDomContainer, "withtitle");
+ }
+ }
+};
+
+/**
+* Default handler for the "close" property
+* @method configClose
+*/
+YAHOO.widget.Calendar.prototype.configClose = function(type, args, obj) {
+ var close = args[0];
+ var title = this.cfg.getProperty("title");
+
+ var DEPR_CLOSE_PATH = "us/my/bn/x_d.gif";
+
+ var linkClose;
+
+ if (close === true) {
+ linkClose = YAHOO.util.Dom.getElementsByClassName("link-close", "a", this.oDomContainer)[0] || document.createElement("a");
+ linkClose.href = "javascript:void(null);";
+ linkClose.className = "link-close";
+ YAHOO.util.Event.addListener(linkClose, "click", this.hide, this, true);
+
+ if (YAHOO.widget.Calendar.IMG_ROOT !== null) {
+ var imgClose = document.createElement("img");
+ imgClose.src = YAHOO.widget.Calendar.IMG_ROOT + DEPR_CLOSE_PATH;
+ imgClose.className = YAHOO.widget.CalendarGroup.CSS_2UPCLOSE;
+ linkClose.appendChild(imgClose);
+ } else {
+ linkClose.innerHTML = '';
+ }
+
+ this.oDomContainer.appendChild(linkClose);
+ YAHOO.util.Dom.addClass(this.oDomContainer, "withtitle");
+ } else {
+ linkClose = YAHOO.util.Dom.getElementsByClassName("link-close", "a", this.oDomContainer)[0] || null;
+ if (linkClose) {
+ YAHOO.util.Event.purgeElement(linkClose);
+ this.oDomContainer.removeChild(linkClose);
+ }
+ if (! title || title === "") {
+ YAHOO.util.Dom.removeClass(this.oDomContainer, "withtitle");
+ }
+ }
+};
+
+/**
+* Initializes Calendar's built-in CustomEvents
+* @method initEvents
+*/
+YAHOO.widget.Calendar.prototype.initEvents = function() {
+
+ /**
+ * Fired before a selection is made
+ * @event beforeSelectEvent
+ */
+ this.beforeSelectEvent = new YAHOO.util.CustomEvent("beforeSelect");
+
+ /**
+ * Fired when a selection is made
+ * @event selectEvent
+ * @param {Array} Array of Date field arrays in the format [YYYY, MM, DD].
+ */
+ this.selectEvent = new YAHOO.util.CustomEvent("select");
+
+ /**
+ * Fired before a selection is made
+ * @event beforeDeselectEvent
+ */
+ this.beforeDeselectEvent = new YAHOO.util.CustomEvent("beforeDeselect");
+
+ /**
+ * Fired when a selection is made
+ * @event deselectEvent
+ * @param {Array} Array of Date field arrays in the format [YYYY, MM, DD].
+ */
+ this.deselectEvent = new YAHOO.util.CustomEvent("deselect");
+
+ /**
+ * Fired when the Calendar page is changed
+ * @event changePageEvent
+ */
+ this.changePageEvent = new YAHOO.util.CustomEvent("changePage");
+
+ /**
+ * Fired before the Calendar is rendered
+ * @event beforeRenderEvent
+ */
+ this.beforeRenderEvent = new YAHOO.util.CustomEvent("beforeRender");
+
+ /**
+ * Fired when the Calendar is rendered
+ * @event renderEvent
+ */
+ this.renderEvent = new YAHOO.util.CustomEvent("render");
+
+ /**
+ * Fired when the Calendar is reset
+ * @event resetEvent
+ */
+ this.resetEvent = new YAHOO.util.CustomEvent("reset");
+
+ /**
+ * Fired when the Calendar is cleared
+ * @event clearEvent
+ */
+ this.clearEvent = new YAHOO.util.CustomEvent("clear");
+
+ this.beforeSelectEvent.subscribe(this.onBeforeSelect, this, true);
+ this.selectEvent.subscribe(this.onSelect, this, true);
+ this.beforeDeselectEvent.subscribe(this.onBeforeDeselect, this, true);
+ this.deselectEvent.subscribe(this.onDeselect, this, true);
+ this.changePageEvent.subscribe(this.onChangePage, this, true);
+ this.renderEvent.subscribe(this.onRender, this, true);
+ this.resetEvent.subscribe(this.onReset, this, true);
+ this.clearEvent.subscribe(this.onClear, this, true);
+};
+
+
+/**
+* The default event function that is attached to a date link within a calendar cell
+* when the calendar is rendered.
+* @method doSelectCell
+* @param {DOMEvent} e The event
+* @param {Calendar} cal A reference to the calendar passed by the Event utility
+*/
+YAHOO.widget.Calendar.prototype.doSelectCell = function(e, cal) {
+ var target = YAHOO.util.Event.getTarget(e);
+
+ var cell,index,d,date;
+
+ while (target.tagName.toLowerCase() != "td" && ! YAHOO.util.Dom.hasClass(target, cal.Style.CSS_CELL_SELECTABLE)) {
+ target = target.parentNode;
+ if (target.tagName.toLowerCase() == "html") {
+ return;
+ }
+ }
+
+ cell = target;
+
+ if (YAHOO.util.Dom.hasClass(cell, cal.Style.CSS_CELL_SELECTABLE)) {
+ index = cell.id.split("cell")[1];
+ d = cal.cellDates[index];
+ date = new Date(d[0],d[1]-1,d[2]);
+
+ var link;
+
+ cal.logger.log("Selecting cell " + index + " via click", "info");
+ if (cal.Options.MULTI_SELECT) {
+ link = cell.getElementsByTagName("a")[0];
+ if (link) {
+ link.blur();
+ }
+
+ var cellDate = cal.cellDates[index];
+ var cellDateIndex = cal._indexOfSelectedFieldArray(cellDate);
+
+ if (cellDateIndex > -1) {
+ cal.deselectCell(index);
+ } else {
+ cal.selectCell(index);
+ }
+
+ } else {
+ link = cell.getElementsByTagName("a")[0];
+ if (link) {
+ link.blur();
+ }
+ cal.selectCell(index);
+ }
+ }
+};
+
+/**
+* The event that is executed when the user hovers over a cell
+* @method doCellMouseOver
+* @param {DOMEvent} e The event
+* @param {Calendar} cal A reference to the calendar passed by the Event utility
+*/
+YAHOO.widget.Calendar.prototype.doCellMouseOver = function(e, cal) {
+ var target;
+ if (e) {
+ target = YAHOO.util.Event.getTarget(e);
+ } else {
+ target = this;
+ }
+
+ while (target.tagName.toLowerCase() != "td") {
+ target = target.parentNode;
+ if (target.tagName.toLowerCase() == "html") {
+ return;
+ }
+ }
+
+ if (YAHOO.util.Dom.hasClass(target, cal.Style.CSS_CELL_SELECTABLE)) {
+ YAHOO.util.Dom.addClass(target, cal.Style.CSS_CELL_HOVER);
+ }
+};
+
+/**
+* The event that is executed when the user moves the mouse out of a cell
+* @method doCellMouseOut
+* @param {DOMEvent} e The event
+* @param {Calendar} cal A reference to the calendar passed by the Event utility
+*/
+YAHOO.widget.Calendar.prototype.doCellMouseOut = function(e, cal) {
+ var target;
+ if (e) {
+ target = YAHOO.util.Event.getTarget(e);
+ } else {
+ target = this;
+ }
+
+ while (target.tagName.toLowerCase() != "td") {
+ target = target.parentNode;
+ if (target.tagName.toLowerCase() == "html") {
+ return;
+ }
+ }
+
+ if (YAHOO.util.Dom.hasClass(target, cal.Style.CSS_CELL_SELECTABLE)) {
+ YAHOO.util.Dom.removeClass(target, cal.Style.CSS_CELL_HOVER);
+ }
+};
+
+YAHOO.widget.Calendar.prototype.setupConfig = function() {
+
+ /**
+ * The month/year representing the current visible Calendar date (mm/yyyy)
+ * @config pagedate
+ * @type String
+ * @default today's date
+ */
+ this.cfg.addProperty("pagedate", { value:new Date(), handler:this.configPageDate } );
+
+ /**
+ * The date or range of dates representing the current Calendar selection
+ * @config selected
+ * @type String
+ * @default []
+ */
+ this.cfg.addProperty("selected", { value:[], handler:this.configSelected } );
+
+ /**
+ * The title to display above the Calendar's month header
+ * @config title
+ * @type String
+ * @default ""
+ */
+ this.cfg.addProperty("title", { value:"", handler:this.configTitle } );
+
+ /**
+ * Whether or not a close button should be displayed for this Calendar
+ * @config close
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("close", { value:false, handler:this.configClose } );
+
+ /**
+ * Whether or not an iframe shim should be placed under the Calendar to prevent select boxes from bleeding through in Internet Explorer 6 and below.
+ * @config iframe
+ * @type Boolean
+ * @default true
+ */
+ this.cfg.addProperty("iframe", { value:true, handler:this.configIframe, validator:this.cfg.checkBoolean } );
+
+ /**
+ * The minimum selectable date in the current Calendar (mm/dd/yyyy)
+ * @config mindate
+ * @type String
+ * @default null
+ */
+ this.cfg.addProperty("mindate", { value:null, handler:this.configMinDate } );
+
+ /**
+ * The maximum selectable date in the current Calendar (mm/dd/yyyy)
+ * @config maxdate
+ * @type String
+ * @default null
+ */
+ this.cfg.addProperty("maxdate", { value:null, handler:this.configMaxDate } );
+
+
+ // Options properties
+
+ /**
+ * True if the Calendar should allow multiple selections. False by default.
+ * @config MULTI_SELECT
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("MULTI_SELECT", { value:false, handler:this.configOptions, validator:this.cfg.checkBoolean } );
+
+ /**
+ * The weekday the week begins on. Default is 0 (Sunday).
+ * @config START_WEEKDAY
+ * @type number
+ * @default 0
+ */
+ this.cfg.addProperty("START_WEEKDAY", { value:0, handler:this.configOptions, validator:this.cfg.checkNumber } );
+
+ /**
+ * True if the Calendar should show weekday labels. True by default.
+ * @config SHOW_WEEKDAYS
+ * @type Boolean
+ * @default true
+ */
+ this.cfg.addProperty("SHOW_WEEKDAYS", { value:true, handler:this.configOptions, validator:this.cfg.checkBoolean } );
+
+ /**
+ * True if the Calendar should show week row headers. False by default.
+ * @config SHOW_WEEK_HEADER
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("SHOW_WEEK_HEADER",{ value:false, handler:this.configOptions, validator:this.cfg.checkBoolean } );
+
+ /**
+ * True if the Calendar should show week row footers. False by default.
+ * @config SHOW_WEEK_FOOTER
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("SHOW_WEEK_FOOTER",{ value:false, handler:this.configOptions, validator:this.cfg.checkBoolean } );
+
+ /**
+ * True if the Calendar should suppress weeks that are not a part of the current month. False by default.
+ * @config HIDE_BLANK_WEEKS
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("HIDE_BLANK_WEEKS",{ value:false, handler:this.configOptions, validator:this.cfg.checkBoolean } );
+
+ /**
+ * The image that should be used for the left navigation arrow.
+ * @config NAV_ARROW_LEFT
+ * @type String
+ * @deprecated You can customize the image by overriding the default CSS class for the left arrow - "calnavleft"
+ * @default null
+ */
+ this.cfg.addProperty("NAV_ARROW_LEFT", { value:null, handler:this.configOptions } );
+
+ /**
+ * The image that should be used for the right navigation arrow.
+ * @config NAV_ARROW_RIGHT
+ * @type String
+ * @deprecated You can customize the image by overriding the default CSS class for the right arrow - "calnavright"
+ * @default null
+ */
+ this.cfg.addProperty("NAV_ARROW_RIGHT", { value:null, handler:this.configOptions } );
+
+ // Locale properties
+
+ /**
+ * The short month labels for the current locale.
+ * @config MONTHS_SHORT
+ * @type String[]
+ * @default ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
+ */
+ this.cfg.addProperty("MONTHS_SHORT", { value:["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], handler:this.configLocale } );
+
+ /**
+ * The long month labels for the current locale.
+ * @config MONTHS_LONG
+ * @type String[]
+ * @default ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"
+ */
+ this.cfg.addProperty("MONTHS_LONG", { value:["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], handler:this.configLocale } );
+
+ /**
+ * The 1-character weekday labels for the current locale.
+ * @config WEEKDAYS_1CHAR
+ * @type String[]
+ * @default ["S", "M", "T", "W", "T", "F", "S"]
+ */
+ this.cfg.addProperty("WEEKDAYS_1CHAR", { value:["S", "M", "T", "W", "T", "F", "S"], handler:this.configLocale } );
+
+ /**
+ * The short weekday labels for the current locale.
+ * @config WEEKDAYS_SHORT
+ * @type String[]
+ * @default ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"]
+ */
+ this.cfg.addProperty("WEEKDAYS_SHORT", { value:["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], handler:this.configLocale } );
+
+ /**
+ * The medium weekday labels for the current locale.
+ * @config WEEKDAYS_MEDIUM
+ * @type String[]
+ * @default ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"]
+ */
+ this.cfg.addProperty("WEEKDAYS_MEDIUM", { value:["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], handler:this.configLocale } );
+
+ /**
+ * The long weekday labels for the current locale.
+ * @config WEEKDAYS_LONG
+ * @type String[]
+ * @default ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"]
+ */
+ this.cfg.addProperty("WEEKDAYS_LONG", { value:["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"], handler:this.configLocale } );
+
+ /**
+ * Refreshes the locale values used to build the Calendar.
+ * @method refreshLocale
+ * @private
+ */
+ var refreshLocale = function() {
+ this.cfg.refireEvent("LOCALE_MONTHS");
+ this.cfg.refireEvent("LOCALE_WEEKDAYS");
+ };
+
+ this.cfg.subscribeToConfigEvent("START_WEEKDAY", refreshLocale, this, true);
+ this.cfg.subscribeToConfigEvent("MONTHS_SHORT", refreshLocale, this, true);
+ this.cfg.subscribeToConfigEvent("MONTHS_LONG", refreshLocale, this, true);
+ this.cfg.subscribeToConfigEvent("WEEKDAYS_1CHAR", refreshLocale, this, true);
+ this.cfg.subscribeToConfigEvent("WEEKDAYS_SHORT", refreshLocale, this, true);
+ this.cfg.subscribeToConfigEvent("WEEKDAYS_MEDIUM", refreshLocale, this, true);
+ this.cfg.subscribeToConfigEvent("WEEKDAYS_LONG", refreshLocale, this, true);
+
+ /**
+ * The setting that determines which length of month labels should be used. Possible values are "short" and "long".
+ * @config LOCALE_MONTHS
+ * @type String
+ * @default "long"
+ */
+ this.cfg.addProperty("LOCALE_MONTHS", { value:"long", handler:this.configLocaleValues } );
+
+ /**
+ * The setting that determines which length of weekday labels should be used. Possible values are "1char", "short", "medium", and "long".
+ * @config LOCALE_WEEKDAYS
+ * @type String
+ * @default "short"
+ */
+ this.cfg.addProperty("LOCALE_WEEKDAYS", { value:"short", handler:this.configLocaleValues } );
+
+ /**
+ * The value used to delimit individual dates in a date string passed to various Calendar functions.
+ * @config DATE_DELIMITER
+ * @type String
+ * @default ","
+ */
+ this.cfg.addProperty("DATE_DELIMITER", { value:",", handler:this.configLocale } );
+
+ /**
+ * The value used to delimit date fields in a date string passed to various Calendar functions.
+ * @config DATE_FIELD_DELIMITER
+ * @type String
+ * @default "/"
+ */
+ this.cfg.addProperty("DATE_FIELD_DELIMITER",{ value:"/", handler:this.configLocale } );
+
+ /**
+ * The value used to delimit date ranges in a date string passed to various Calendar functions.
+ * @config DATE_RANGE_DELIMITER
+ * @type String
+ * @default "-"
+ */
+ this.cfg.addProperty("DATE_RANGE_DELIMITER",{ value:"-", handler:this.configLocale } );
+
+ /**
+ * The position of the month in a month/year date string
+ * @config MY_MONTH_POSITION
+ * @type Number
+ * @default 1
+ */
+ this.cfg.addProperty("MY_MONTH_POSITION", { value:1, handler:this.configLocale, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the year in a month/year date string
+ * @config MY_YEAR_POSITION
+ * @type Number
+ * @default 2
+ */
+ this.cfg.addProperty("MY_YEAR_POSITION", { value:2, handler:this.configLocale, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the month in a month/day date string
+ * @config MD_MONTH_POSITION
+ * @type Number
+ * @default 1
+ */
+ this.cfg.addProperty("MD_MONTH_POSITION", { value:1, handler:this.configLocale, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the day in a month/year date string
+ * @config MD_DAY_POSITION
+ * @type Number
+ * @default 2
+ */
+ this.cfg.addProperty("MD_DAY_POSITION", { value:2, handler:this.configLocale, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the month in a month/day/year date string
+ * @config MDY_MONTH_POSITION
+ * @type Number
+ * @default 1
+ */
+ this.cfg.addProperty("MDY_MONTH_POSITION", { value:1, handler:this.configLocale, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the day in a month/day/year date string
+ * @config MDY_DAY_POSITION
+ * @type Number
+ * @default 2
+ */
+ this.cfg.addProperty("MDY_DAY_POSITION", { value:2, handler:this.configLocale, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the year in a month/day/year date string
+ * @config MDY_YEAR_POSITION
+ * @type Number
+ * @default 3
+ */
+ this.cfg.addProperty("MDY_YEAR_POSITION", { value:3, handler:this.configLocale, validator:this.cfg.checkNumber } );
+};
+
+/**
+* The default handler for the "pagedate" property
+* @method configPageDate
+*/
+YAHOO.widget.Calendar.prototype.configPageDate = function(type, args, obj) {
+ this.cfg.setProperty("pagedate", this._parsePageDate(args[0]), true);
+};
+
+/**
+* The default handler for the "mindate" property
+* @method configMinDate
+*/
+YAHOO.widget.Calendar.prototype.configMinDate = function(type, args, obj) {
+ var val = args[0];
+ if (typeof val == 'string') {
+ val = this._parseDate(val);
+ this.cfg.setProperty("mindate", new Date(val[0],(val[1]-1),val[2]));
+ }
+};
+
+/**
+* The default handler for the "maxdate" property
+* @method configMaxDate
+*/
+YAHOO.widget.Calendar.prototype.configMaxDate = function(type, args, obj) {
+ var val = args[0];
+ if (typeof val == 'string') {
+ val = this._parseDate(val);
+ this.cfg.setProperty("maxdate", new Date(val[0],(val[1]-1),val[2]));
+ }
+};
+
+/**
+* The default handler for the "selected" property
+* @method configSelected
+*/
+YAHOO.widget.Calendar.prototype.configSelected = function(type, args, obj) {
+ var selected = args[0];
+
+ if (selected) {
+ if (typeof selected == 'string') {
+ this.cfg.setProperty("selected", this._parseDates(selected), true);
+ }
+ }
+ if (! this._selectedDates) {
+ this._selectedDates = this.cfg.getProperty("selected");
+ }
+};
+
+/**
+* The default handler for all configuration options properties
+* @method configOptions
+*/
+YAHOO.widget.Calendar.prototype.configOptions = function(type, args, obj) {
+ type = type.toUpperCase();
+ var val = args[0];
+ this.Options[type] = val;
+};
+
+/**
+* The default handler for all configuration locale properties
+* @method configLocale
+*/
+YAHOO.widget.Calendar.prototype.configLocale = function(type, args, obj) {
+ type = type.toUpperCase();
+ var val = args[0];
+ this.Locale[type] = val;
+
+ this.cfg.refireEvent("LOCALE_MONTHS");
+ this.cfg.refireEvent("LOCALE_WEEKDAYS");
+
+};
+
+/**
+* The default handler for all configuration locale field length properties
+* @method configLocaleValues
+*/
+YAHOO.widget.Calendar.prototype.configLocaleValues = function(type, args, obj) {
+ type = type.toUpperCase();
+ var val = args[0];
+
+ switch (type) {
+ case "LOCALE_MONTHS":
+ switch (val) {
+ case "short":
+ this.Locale.LOCALE_MONTHS = this.cfg.getProperty("MONTHS_SHORT").concat();
+ break;
+ case "long":
+ this.Locale.LOCALE_MONTHS = this.cfg.getProperty("MONTHS_LONG").concat();
+ break;
+ }
+ break;
+ case "LOCALE_WEEKDAYS":
+ switch (val) {
+ case "1char":
+ this.Locale.LOCALE_WEEKDAYS = this.cfg.getProperty("WEEKDAYS_1CHAR").concat();
+ break;
+ case "short":
+ this.Locale.LOCALE_WEEKDAYS = this.cfg.getProperty("WEEKDAYS_SHORT").concat();
+ break;
+ case "medium":
+ this.Locale.LOCALE_WEEKDAYS = this.cfg.getProperty("WEEKDAYS_MEDIUM").concat();
+ break;
+ case "long":
+ this.Locale.LOCALE_WEEKDAYS = this.cfg.getProperty("WEEKDAYS_LONG").concat();
+ break;
+ }
+
+ var START_WEEKDAY = this.cfg.getProperty("START_WEEKDAY");
+
+ if (START_WEEKDAY > 0) {
+ for (var w=0;w";
+ html[html.length] = "
";
+ html[html.length] = '
';
+ html[html.length] = '
';
+
+ var renderLeft, renderRight = false;
+
+ if (this.parent) {
+ if (this.index === 0) {
+ renderLeft = true;
+ }
+ if (this.index == (this.parent.cfg.getProperty("pages") -1)) {
+ renderRight = true;
+ }
+ } else {
+ renderLeft = true;
+ renderRight = true;
+ }
+
+ var cal = this.parent || this;
+
+ if (renderLeft) {
+ var leftArrow = this.cfg.getProperty("NAV_ARROW_LEFT");
+ // Check for deprecated customization - If someone set IMG_ROOT, but didn't set NAV_ARROW_LEFT, then set NAV_ARROW_LEFT to the old deprecated value
+ if (leftArrow === null && YAHOO.widget.Calendar.IMG_ROOT !== null) {
+ leftArrow = YAHOO.widget.Calendar.IMG_ROOT + DEPR_NAV_LEFT;
+ }
+ var leftStyle = (leftArrow === null) ? "" : ' style="background-image:url(' + leftArrow + ')"';
+ html[html.length] = '';
+ }
+
+ html[html.length] = this.buildMonthLabel();
+
+ if (renderRight) {
+ var rightArrow = this.cfg.getProperty("NAV_ARROW_RIGHT");
+ if (rightArrow === null && YAHOO.widget.Calendar.IMG_ROOT !== null) {
+ rightArrow = YAHOO.widget.Calendar.IMG_ROOT + DEPR_NAV_RIGHT;
+ }
+ var rightStyle = (rightArrow === null) ? "" : ' style="background-image:url(' + rightArrow + ')"';
+ html[html.length] = '';
+ }
+
+ html[html.length] = '
';
+ html[html.length] = '
';
+ html[html.length] = '
';
+
+ if (this.cfg.getProperty("SHOW_WEEKDAYS")) {
+ html = this.buildWeekdays(html);
+ }
+
+ html[html.length] = '';
+
+ return html;
+};
+
+/**
+* Renders the Calendar's weekday headers.
+* @method buildWeekdays
+* @param {Array} html The current working HTML array
+* @return {Array} The current working HTML array
+*/
+YAHOO.widget.Calendar.prototype.buildWeekdays = function(html) {
+
+ html[html.length] = '
';
+
+ if (this.cfg.getProperty("SHOW_WEEK_HEADER")) {
+ html[html.length] = '
';
+ }
+ }
+
+ html[html.length] = '';
+
+ return html;
+};
+
+/**
+* Renders the calendar footer. In the default implementation, there is
+* no footer.
+* @method renderFooter
+* @param {Array} html The current working HTML array
+* @return {Array} The current working HTML array
+*/
+YAHOO.widget.Calendar.prototype.renderFooter = function(html) { return html; };
+
+/**
+* Renders the calendar after it has been configured. The render() method has a specific call chain that will execute
+* when the method is called: renderHeader, renderBody, renderFooter.
+* Refer to the documentation for those methods for information on
+* individual render tasks.
+* @method render
+*/
+YAHOO.widget.Calendar.prototype.render = function() {
+ this.beforeRenderEvent.fire();
+
+ // Find starting day of the current month
+ var workingDate = YAHOO.widget.DateMath.findMonthStart(this.cfg.getProperty("pagedate"));
+
+ this.resetRenderers();
+ this.cellDates.length = 0;
+
+ YAHOO.util.Event.purgeElement(this.oDomContainer, true);
+
+ var html = [];
+
+ html[html.length] = '
';
+ html = this.renderHeader(html);
+ html = this.renderBody(workingDate, html);
+ html = this.renderFooter(html);
+ html[html.length] = '
';
+
+ this.oDomContainer.innerHTML = html.join("\n");
+
+ this.applyListeners();
+ this.cells = this.oDomContainer.getElementsByTagName("td");
+
+ this.cfg.refireEvent("title");
+ this.cfg.refireEvent("close");
+ this.cfg.refireEvent("iframe");
+
+ this.renderEvent.fire();
+};
+
+/**
+* Applies the Calendar's DOM listeners to applicable elements.
+* @method applyListeners
+*/
+YAHOO.widget.Calendar.prototype.applyListeners = function() {
+
+ var root = this.oDomContainer;
+ var cal = this.parent || this;
+
+ var linkLeft, linkRight;
+
+ linkLeft = YAHOO.util.Dom.getElementsByClassName(this.Style.CSS_NAV_LEFT, "a", root);
+ linkRight = YAHOO.util.Dom.getElementsByClassName(this.Style.CSS_NAV_RIGHT, "a", root);
+
+ if (linkLeft) {
+ this.linkLeft = linkLeft[0];
+ YAHOO.util.Event.addListener(this.linkLeft, "mousedown", cal.previousMonth, cal, true);
+ }
+
+ if (linkRight) {
+ this.linkRight = linkRight[0];
+ YAHOO.util.Event.addListener(this.linkRight, "mousedown", cal.nextMonth, cal, true);
+ }
+
+ if (this.domEventMap) {
+ var el,elements;
+ for (var cls in this.domEventMap) {
+ if (YAHOO.lang.hasOwnProperty(this.domEventMap, cls)) {
+ var items = this.domEventMap[cls];
+
+ if (! (items instanceof Array)) {
+ items = [items];
+ }
+
+ for (var i=0;i' + weekNum + '';
+ return html;
+};
+
+/**
+* Renders the row footer for a week.
+* @method renderRowFooter
+* @param {Number} weekNum The week number of the current row
+* @param {Array} cell The current working HTML array
+*/
+YAHOO.widget.Calendar.prototype.renderRowFooter = function(weekNum, html) {
+ html[html.length] = '
' + weekNum + '
';
+ return html;
+};
+
+/**
+* Renders a single standard calendar cell in the calendar widget table.
+* All logic for determining how a standard default cell will be rendered is
+* encapsulated in this method, and must be accounted for when extending the
+* widget class.
+* @method renderCellDefault
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+*/
+YAHOO.widget.Calendar.prototype.renderCellDefault = function(workingDate, cell) {
+ cell.innerHTML = '' + this.buildDayLabel(workingDate) + "";
+};
+
+/**
+* Styles a selectable cell.
+* @method styleCellDefault
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+*/
+YAHOO.widget.Calendar.prototype.styleCellDefault = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_SELECTABLE);
+};
+
+
+/**
+* Renders a single standard calendar cell using the CSS hightlight1 style
+* @method renderCellStyleHighlight1
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+*/
+YAHOO.widget.Calendar.prototype.renderCellStyleHighlight1 = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_HIGHLIGHT1);
+};
+
+/**
+* Renders a single standard calendar cell using the CSS hightlight2 style
+* @method renderCellStyleHighlight2
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+*/
+YAHOO.widget.Calendar.prototype.renderCellStyleHighlight2 = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_HIGHLIGHT2);
+};
+
+/**
+* Renders a single standard calendar cell using the CSS hightlight3 style
+* @method renderCellStyleHighlight3
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+*/
+YAHOO.widget.Calendar.prototype.renderCellStyleHighlight3 = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_HIGHLIGHT3);
+};
+
+/**
+* Renders a single standard calendar cell using the CSS hightlight4 style
+* @method renderCellStyleHighlight4
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+*/
+YAHOO.widget.Calendar.prototype.renderCellStyleHighlight4 = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_HIGHLIGHT4);
+};
+
+/**
+* Applies the default style used for rendering today's date to the current calendar cell
+* @method renderCellStyleToday
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+*/
+YAHOO.widget.Calendar.prototype.renderCellStyleToday = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_TODAY);
+};
+
+/**
+* Applies the default style used for rendering selected dates to the current calendar cell
+* @method renderCellStyleSelected
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+* @return {String} YAHOO.widget.Calendar.STOP_RENDER if rendering should stop with this style, null or nothing if rendering
+* should not be terminated
+*/
+YAHOO.widget.Calendar.prototype.renderCellStyleSelected = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_SELECTED);
+};
+
+/**
+* Applies the default style used for rendering dates that are not a part of the current
+* month (preceding or trailing the cells for the current month)
+* @method renderCellNotThisMonth
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+* @return {String} YAHOO.widget.Calendar.STOP_RENDER if rendering should stop with this style, null or nothing if rendering
+* should not be terminated
+*/
+YAHOO.widget.Calendar.prototype.renderCellNotThisMonth = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_OOM);
+ cell.innerHTML=workingDate.getDate();
+ return YAHOO.widget.Calendar.STOP_RENDER;
+};
+
+/**
+* Renders the current calendar cell as a non-selectable "black-out" date using the default
+* restricted style.
+* @method renderBodyCellRestricted
+* @param {Date} workingDate The current working Date object being used to generate the calendar
+* @param {HTMLTableCellElement} cell The current working cell in the calendar
+* @return {String} YAHOO.widget.Calendar.STOP_RENDER if rendering should stop with this style, null or nothing if rendering
+* should not be terminated
+*/
+YAHOO.widget.Calendar.prototype.renderBodyCellRestricted = function(workingDate, cell) {
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL);
+ YAHOO.util.Dom.addClass(cell, this.Style.CSS_CELL_RESTRICTED);
+ cell.innerHTML=workingDate.getDate();
+ return YAHOO.widget.Calendar.STOP_RENDER;
+};
+
+// END BUILT-IN TABLE CELL RENDERERS
+
+// BEGIN MONTH NAVIGATION METHODS
+
+/**
+* Adds the designated number of months to the current calendar month, and sets the current
+* calendar page date to the new month.
+* @method addMonths
+* @param {Number} count The number of months to add to the current calendar
+*/
+YAHOO.widget.Calendar.prototype.addMonths = function(count) {
+ this.cfg.setProperty("pagedate", YAHOO.widget.DateMath.add(this.cfg.getProperty("pagedate"), YAHOO.widget.DateMath.MONTH, count));
+ this.resetRenderers();
+ this.changePageEvent.fire();
+};
+
+/**
+* Subtracts the designated number of months from the current calendar month, and sets the current
+* calendar page date to the new month.
+* @method subtractMonths
+* @param {Number} count The number of months to subtract from the current calendar
+*/
+YAHOO.widget.Calendar.prototype.subtractMonths = function(count) {
+ this.cfg.setProperty("pagedate", YAHOO.widget.DateMath.subtract(this.cfg.getProperty("pagedate"), YAHOO.widget.DateMath.MONTH, count));
+ this.resetRenderers();
+ this.changePageEvent.fire();
+};
+
+/**
+* Adds the designated number of years to the current calendar, and sets the current
+* calendar page date to the new month.
+* @method addYears
+* @param {Number} count The number of years to add to the current calendar
+*/
+YAHOO.widget.Calendar.prototype.addYears = function(count) {
+ this.cfg.setProperty("pagedate", YAHOO.widget.DateMath.add(this.cfg.getProperty("pagedate"), YAHOO.widget.DateMath.YEAR, count));
+ this.resetRenderers();
+ this.changePageEvent.fire();
+};
+
+/**
+* Subtcats the designated number of years from the current calendar, and sets the current
+* calendar page date to the new month.
+* @method subtractYears
+* @param {Number} count The number of years to subtract from the current calendar
+*/
+YAHOO.widget.Calendar.prototype.subtractYears = function(count) {
+ this.cfg.setProperty("pagedate", YAHOO.widget.DateMath.subtract(this.cfg.getProperty("pagedate"), YAHOO.widget.DateMath.YEAR, count));
+ this.resetRenderers();
+ this.changePageEvent.fire();
+};
+
+/**
+* Navigates to the next month page in the calendar widget.
+* @method nextMonth
+*/
+YAHOO.widget.Calendar.prototype.nextMonth = function() {
+ this.addMonths(1);
+};
+
+/**
+* Navigates to the previous month page in the calendar widget.
+* @method previousMonth
+*/
+YAHOO.widget.Calendar.prototype.previousMonth = function() {
+ this.subtractMonths(1);
+};
+
+/**
+* Navigates to the next year in the currently selected month in the calendar widget.
+* @method nextYear
+*/
+YAHOO.widget.Calendar.prototype.nextYear = function() {
+ this.addYears(1);
+};
+
+/**
+* Navigates to the previous year in the currently selected month in the calendar widget.
+* @method previousYear
+*/
+YAHOO.widget.Calendar.prototype.previousYear = function() {
+ this.subtractYears(1);
+};
+
+// END MONTH NAVIGATION METHODS
+
+// BEGIN SELECTION METHODS
+
+/**
+* Resets the calendar widget to the originally selected month and year, and
+* sets the calendar to the initial selection(s).
+* @method reset
+*/
+YAHOO.widget.Calendar.prototype.reset = function() {
+ this.cfg.resetProperty("selected");
+ this.cfg.resetProperty("pagedate");
+ this.resetEvent.fire();
+};
+
+/**
+* Clears the selected dates in the current calendar widget and sets the calendar
+* to the current month and year.
+* @method clear
+*/
+YAHOO.widget.Calendar.prototype.clear = function() {
+ this.cfg.setProperty("selected", []);
+ this.cfg.setProperty("pagedate", new Date(this.today.getTime()));
+ this.clearEvent.fire();
+};
+
+/**
+* Selects a date or a collection of dates on the current calendar. This method, by default,
+* does not call the render method explicitly. Once selection has completed, render must be
+* called for the changes to be reflected visually.
+* @method select
+* @param {String/Date/Date[]} date The date string of dates to select in the current calendar. Valid formats are
+* individual date(s) (12/24/2005,12/26/2005) or date range(s) (12/24/2005-1/1/2006).
+* Multiple comma-delimited dates can also be passed to this method (12/24/2005,12/11/2005-12/13/2005).
+* This method can also take a JavaScript Date object or an array of Date objects.
+* @return {Date[]} Array of JavaScript Date objects representing all individual dates that are currently selected.
+*/
+YAHOO.widget.Calendar.prototype.select = function(date) {
+ this.logger.log("Select: " + date, "info");
+ this.beforeSelectEvent.fire();
+
+ var selected = this.cfg.getProperty("selected");
+ var aToBeSelected = this._toFieldArray(date);
+ this.logger.log("Selection field array: " + aToBeSelected, "info");
+
+ for (var a=0;a -1) {
+ if (this.cfg.getProperty("pagedate").getMonth() == dCellDate.getMonth() &&
+ this.cfg.getProperty("pagedate").getFullYear() == dCellDate.getFullYear()) {
+ YAHOO.util.Dom.removeClass(cell, this.Style.CSS_CELL_SELECTED);
+ }
+
+ selected.splice(cellDateIndex, 1);
+ }
+
+
+ if (this.parent) {
+ this.parent.cfg.setProperty("selected", selected);
+ } else {
+ this.cfg.setProperty("selected", selected);
+ }
+
+ this.deselectEvent.fire(selectDate);
+ return this.getSelectedDates();
+};
+
+/**
+* Deselects all dates on the current calendar.
+* @method deselectAll
+* @return {Date[]} Array of JavaScript Date objects representing all individual dates that are currently selected.
+* Assuming that this function executes properly, the return value should be an empty array.
+* However, the empty array is returned for the sake of being able to check the selection status
+* of the calendar.
+*/
+YAHOO.widget.Calendar.prototype.deselectAll = function() {
+ this.beforeDeselectEvent.fire();
+
+ var selected = this.cfg.getProperty("selected");
+ var count = selected.length;
+ var sel = selected.concat();
+
+ if (this.parent) {
+ this.parent.cfg.setProperty("selected", []);
+ } else {
+ this.cfg.setProperty("selected", []);
+ }
+
+ if (count > 0) {
+ this.deselectEvent.fire(sel);
+ }
+
+ return this.getSelectedDates();
+};
+
+// END SELECTION METHODS
+
+// BEGIN TYPE CONVERSION METHODS
+
+/**
+* Converts a date (either a JavaScript Date object, or a date string) to the internal data structure
+* used to represent dates: [[yyyy,mm,dd],[yyyy,mm,dd]].
+* @method _toFieldArray
+* @private
+* @param {String/Date/Date[]} date The date string of dates to deselect in the current calendar. Valid formats are
+* individual date(s) (12/24/2005,12/26/2005) or date range(s) (12/24/2005-1/1/2006).
+* Multiple comma-delimited dates can also be passed to this method (12/24/2005,12/11/2005-12/13/2005).
+* This method can also take a JavaScript Date object or an array of Date objects.
+* @return {Array[](Number[])} Array of date field arrays
+*/
+YAHOO.widget.Calendar.prototype._toFieldArray = function(date) {
+ var returnDate = [];
+
+ if (date instanceof Date) {
+ returnDate = [[date.getFullYear(), date.getMonth()+1, date.getDate()]];
+ } else if (typeof date == 'string') {
+ returnDate = this._parseDates(date);
+ } else if (date instanceof Array) {
+ for (var i=0;i
+*
+*
+*
+* The tables for the calendars ("cal1_0" and "cal1_1") will be inserted into those containers.
+* @namespace YAHOO.widget
+* @class CalendarGroup
+* @constructor
+* @param {String} id The id of the table element that will represent the calendar widget
+* @param {String} containerId The id of the container div element that will wrap the calendar table
+* @param {Object} config The configuration object containing the Calendar's arguments
+*/
+YAHOO.widget.CalendarGroup = function(id, containerId, config) {
+ if (arguments.length > 0) {
+ this.init(id, containerId, config);
+ }
+};
+
+/**
+* Initializes the calendar group. All subclasses must call this method in order for the
+* group to be initialized properly.
+* @method init
+* @param {String} id The id of the table element that will represent the calendar widget
+* @param {String} containerId The id of the container div element that will wrap the calendar table
+* @param {Object} config The configuration object containing the Calendar's arguments
+*/
+YAHOO.widget.CalendarGroup.prototype.init = function(id, containerId, config) {
+ this.logger = new YAHOO.widget.LogWriter("CalendarGroup " + id);
+ this.initEvents();
+ this.initStyles();
+
+ /**
+ * The collection of Calendar pages contained within the CalendarGroup
+ * @property pages
+ * @type YAHOO.widget.Calendar[]
+ */
+ this.pages = [];
+
+ /**
+ * The unique id associated with the CalendarGroup
+ * @property id
+ * @type String
+ */
+ this.id = id;
+
+ /**
+ * The unique id associated with the CalendarGroup container
+ * @property containerId
+ * @type String
+ */
+ this.containerId = containerId;
+
+ /**
+ * The outer containing element for the CalendarGroup
+ * @property oDomContainer
+ * @type HTMLElement
+ */
+ this.oDomContainer = document.getElementById(containerId);
+
+ YAHOO.util.Dom.addClass(this.oDomContainer, YAHOO.widget.CalendarGroup.CSS_CONTAINER);
+ YAHOO.util.Dom.addClass(this.oDomContainer, YAHOO.widget.CalendarGroup.CSS_MULTI_UP);
+
+ /**
+ * The Config object used to hold the configuration variables for the CalendarGroup
+ * @property cfg
+ * @type YAHOO.util.Config
+ */
+ this.cfg = new YAHOO.util.Config(this);
+
+ /**
+ * The local object which contains the CalendarGroup's options
+ * @property Options
+ * @type Object
+ */
+ this.Options = {};
+
+ /**
+ * The local object which contains the CalendarGroup's locale settings
+ * @property Locale
+ * @type Object
+ */
+ this.Locale = {};
+
+ this.setupConfig();
+
+ if (config) {
+ this.cfg.applyConfig(config, true);
+ }
+
+ this.cfg.fireQueue();
+
+ // OPERA HACK FOR MISWRAPPED FLOATS
+ if (this.browser == "opera"){
+ var fixWidth = function() {
+ var startW = this.oDomContainer.offsetWidth;
+ var w = 0;
+ for (var p=0;p 0) {
+ this.oDomContainer.style.width = w + "px";
+ }
+ };
+ this.renderEvent.subscribe(fixWidth,this,true);
+ }
+ this.logger.log("Initialized " + this.pages.length + "-page CalendarGroup", "info");
+};
+
+
+YAHOO.widget.CalendarGroup.prototype.setupConfig = function() {
+ /**
+ * The number of pages to include in the CalendarGroup. This value can only be set once, in the CalendarGroup's constructor arguments.
+ * @config pages
+ * @type Number
+ * @default 2
+ */
+ this.cfg.addProperty("pages", { value:2, validator:this.cfg.checkNumber, handler:this.configPages } );
+
+ /**
+ * The month/year representing the current visible Calendar date (mm/yyyy)
+ * @config pagedate
+ * @type String
+ * @default today's date
+ */
+ this.cfg.addProperty("pagedate", { value:new Date(), handler:this.configPageDate } );
+
+ /**
+ * The date or range of dates representing the current Calendar selection
+ * @config selected
+ * @type String
+ * @default []
+ */
+ this.cfg.addProperty("selected", { value:[], handler:this.delegateConfig } );
+
+ /**
+ * The title to display above the CalendarGroup's month header
+ * @config title
+ * @type String
+ * @default ""
+ */
+ this.cfg.addProperty("title", { value:"", handler:this.configTitle } );
+
+ /**
+ * Whether or not a close button should be displayed for this CalendarGroup
+ * @config close
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("close", { value:false, handler:this.configClose } );
+
+ /**
+ * Whether or not an iframe shim should be placed under the Calendar to prevent select boxes from bleeding through in Internet Explorer 6 and below.
+ * @config iframe
+ * @type Boolean
+ * @default true
+ */
+ this.cfg.addProperty("iframe", { value:true, handler:this.delegateConfig, validator:this.cfg.checkBoolean } );
+
+ /**
+ * The minimum selectable date in the current Calendar (mm/dd/yyyy)
+ * @config mindate
+ * @type String
+ * @default null
+ */
+ this.cfg.addProperty("mindate", { value:null, handler:this.delegateConfig } );
+
+ /**
+ * The maximum selectable date in the current Calendar (mm/dd/yyyy)
+ * @config maxdate
+ * @type String
+ * @default null
+ */
+ this.cfg.addProperty("maxdate", { value:null, handler:this.delegateConfig } );
+
+ // Options properties
+
+ /**
+ * True if the Calendar should allow multiple selections. False by default.
+ * @config MULTI_SELECT
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("MULTI_SELECT", { value:false, handler:this.delegateConfig, validator:this.cfg.checkBoolean } );
+
+ /**
+ * The weekday the week begins on. Default is 0 (Sunday).
+ * @config START_WEEKDAY
+ * @type number
+ * @default 0
+ */
+ this.cfg.addProperty("START_WEEKDAY", { value:0, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+ /**
+ * True if the Calendar should show weekday labels. True by default.
+ * @config SHOW_WEEKDAYS
+ * @type Boolean
+ * @default true
+ */
+ this.cfg.addProperty("SHOW_WEEKDAYS", { value:true, handler:this.delegateConfig, validator:this.cfg.checkBoolean } );
+
+ /**
+ * True if the Calendar should show week row headers. False by default.
+ * @config SHOW_WEEK_HEADER
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("SHOW_WEEK_HEADER",{ value:false, handler:this.delegateConfig, validator:this.cfg.checkBoolean } );
+
+ /**
+ * True if the Calendar should show week row footers. False by default.
+ * @config SHOW_WEEK_FOOTER
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("SHOW_WEEK_FOOTER",{ value:false, handler:this.delegateConfig, validator:this.cfg.checkBoolean } );
+
+ /**
+ * True if the Calendar should suppress weeks that are not a part of the current month. False by default.
+ * @config HIDE_BLANK_WEEKS
+ * @type Boolean
+ * @default false
+ */
+ this.cfg.addProperty("HIDE_BLANK_WEEKS",{ value:false, handler:this.delegateConfig, validator:this.cfg.checkBoolean } );
+
+ /**
+ * The image that should be used for the left navigation arrow.
+ * @config NAV_ARROW_LEFT
+ * @type String
+ * @deprecated You can customize the image by overriding the default CSS class for the left arrow - "calnavleft"
+ * @default null
+ */
+ this.cfg.addProperty("NAV_ARROW_LEFT", { value:null, handler:this.delegateConfig } );
+
+ /**
+ * The image that should be used for the right navigation arrow.
+ * @config NAV_ARROW_RIGHT
+ * @type String
+ * @deprecated You can customize the image by overriding the default CSS class for the right arrow - "calnavright"
+ * @default null
+ */
+ this.cfg.addProperty("NAV_ARROW_RIGHT", { value:null, handler:this.delegateConfig } );
+
+ // Locale properties
+
+ /**
+ * The short month labels for the current locale.
+ * @config MONTHS_SHORT
+ * @type String[]
+ * @default ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
+ */
+ this.cfg.addProperty("MONTHS_SHORT", { value:["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], handler:this.delegateConfig } );
+
+ /**
+ * The long month labels for the current locale.
+ * @config MONTHS_LONG
+ * @type String[]
+ * @default ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"
+ */
+ this.cfg.addProperty("MONTHS_LONG", { value:["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], handler:this.delegateConfig } );
+
+ /**
+ * The 1-character weekday labels for the current locale.
+ * @config WEEKDAYS_1CHAR
+ * @type String[]
+ * @default ["S", "M", "T", "W", "T", "F", "S"]
+ */
+ this.cfg.addProperty("WEEKDAYS_1CHAR", { value:["S", "M", "T", "W", "T", "F", "S"], handler:this.delegateConfig } );
+
+ /**
+ * The short weekday labels for the current locale.
+ * @config WEEKDAYS_SHORT
+ * @type String[]
+ * @default ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"]
+ */
+ this.cfg.addProperty("WEEKDAYS_SHORT", { value:["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], handler:this.delegateConfig } );
+
+ /**
+ * The medium weekday labels for the current locale.
+ * @config WEEKDAYS_MEDIUM
+ * @type String[]
+ * @default ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"]
+ */
+ this.cfg.addProperty("WEEKDAYS_MEDIUM", { value:["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], handler:this.delegateConfig } );
+
+ /**
+ * The long weekday labels for the current locale.
+ * @config WEEKDAYS_LONG
+ * @type String[]
+ * @default ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"]
+ */
+ this.cfg.addProperty("WEEKDAYS_LONG", { value:["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"], handler:this.delegateConfig } );
+
+ /**
+ * The setting that determines which length of month labels should be used. Possible values are "short" and "long".
+ * @config LOCALE_MONTHS
+ * @type String
+ * @default "long"
+ */
+ this.cfg.addProperty("LOCALE_MONTHS", { value:"long", handler:this.delegateConfig } );
+
+ /**
+ * The setting that determines which length of weekday labels should be used. Possible values are "1char", "short", "medium", and "long".
+ * @config LOCALE_WEEKDAYS
+ * @type String
+ * @default "short"
+ */
+ this.cfg.addProperty("LOCALE_WEEKDAYS", { value:"short", handler:this.delegateConfig } );
+
+ /**
+ * The value used to delimit individual dates in a date string passed to various Calendar functions.
+ * @config DATE_DELIMITER
+ * @type String
+ * @default ","
+ */
+ this.cfg.addProperty("DATE_DELIMITER", { value:",", handler:this.delegateConfig } );
+
+ /**
+ * The value used to delimit date fields in a date string passed to various Calendar functions.
+ * @config DATE_FIELD_DELIMITER
+ * @type String
+ * @default "/"
+ */
+ this.cfg.addProperty("DATE_FIELD_DELIMITER",{ value:"/", handler:this.delegateConfig } );
+
+ /**
+ * The value used to delimit date ranges in a date string passed to various Calendar functions.
+ * @config DATE_RANGE_DELIMITER
+ * @type String
+ * @default "-"
+ */
+ this.cfg.addProperty("DATE_RANGE_DELIMITER",{ value:"-", handler:this.delegateConfig } );
+
+ /**
+ * The position of the month in a month/year date string
+ * @config MY_MONTH_POSITION
+ * @type Number
+ * @default 1
+ */
+ this.cfg.addProperty("MY_MONTH_POSITION", { value:1, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the year in a month/year date string
+ * @config MY_YEAR_POSITION
+ * @type Number
+ * @default 2
+ */
+ this.cfg.addProperty("MY_YEAR_POSITION", { value:2, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the month in a month/day date string
+ * @config MD_MONTH_POSITION
+ * @type Number
+ * @default 1
+ */
+ this.cfg.addProperty("MD_MONTH_POSITION", { value:1, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the day in a month/year date string
+ * @config MD_DAY_POSITION
+ * @type Number
+ * @default 2
+ */
+ this.cfg.addProperty("MD_DAY_POSITION", { value:2, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the month in a month/day/year date string
+ * @config MDY_MONTH_POSITION
+ * @type Number
+ * @default 1
+ */
+ this.cfg.addProperty("MDY_MONTH_POSITION", { value:1, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the day in a month/day/year date string
+ * @config MDY_DAY_POSITION
+ * @type Number
+ * @default 2
+ */
+ this.cfg.addProperty("MDY_DAY_POSITION", { value:2, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+ /**
+ * The position of the year in a month/day/year date string
+ * @config MDY_YEAR_POSITION
+ * @type Number
+ * @default 3
+ */
+ this.cfg.addProperty("MDY_YEAR_POSITION", { value:3, handler:this.delegateConfig, validator:this.cfg.checkNumber } );
+
+};
+
+/**
+* Initializes CalendarGroup's built-in CustomEvents
+* @method initEvents
+*/
+YAHOO.widget.CalendarGroup.prototype.initEvents = function() {
+ var me = this;
+
+ /**
+ * Proxy subscriber to subscribe to the CalendarGroup's child Calendars' CustomEvents
+ * @method sub
+ * @private
+ * @param {Function} fn The function to subscribe to this CustomEvent
+ * @param {Object} obj The CustomEvent's scope object
+ * @param {Boolean} bOverride Whether or not to apply scope correction
+ */
+ var sub = function(fn, obj, bOverride) {
+ for (var p=0;p0) {
+ year+=1;
+ }
+ cal.setYear(year);
+ }
+};
+/**
+* Calls the render function of all child calendars within the group.
+* @method render
+*/
+YAHOO.widget.CalendarGroup.prototype.render = function() {
+ this.renderHeader();
+ for (var p=0;p=0;--p) {
+ var cal = this.pages[p];
+ cal.previousMonth();
+ }
+};
+
+/**
+* Navigates to the next year in the currently selected month in the calendar widget.
+* @method nextYear
+*/
+YAHOO.widget.CalendarGroup.prototype.nextYear = function() {
+ for (var p=0;p 11)) {
+ var DM = YAHOO.widget.DateMath;
+ var newDate = DM.add(date, DM.MONTH, iMonth-date.getMonth());
+ date.setTime(newDate.getTime());
+ } else {
+ date.setMonth(iMonth);
+ }
+};
+
+
+/**
+* CSS class representing the container for the calendar
+* @property YAHOO.widget.CalendarGroup.CSS_CONTAINER
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.CalendarGroup.CSS_CONTAINER = "yui-calcontainer";
+
+/**
+* CSS class representing the container for the calendar
+* @property YAHOO.widget.CalendarGroup.CSS_MULTI_UP
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.CalendarGroup.CSS_MULTI_UP = "multi";
+
+/**
+* CSS class representing the title for the 2-up calendar
+* @property YAHOO.widget.CalendarGroup.CSS_2UPTITLE
+* @static
+* @final
+* @type String
+*/
+YAHOO.widget.CalendarGroup.CSS_2UPTITLE = "title";
+
+/**
+* CSS class representing the close icon for the 2-up calendar
+* @property YAHOO.widget.CalendarGroup.CSS_2UPCLOSE
+* @static
+* @final
+* @deprecated Along with Calendar.IMG_ROOT and NAV_ARROW_LEFT, NAV_ARROW_RIGHT configuration properties.
+* Calendar's Style.CSS_CLOSE property now represents the CSS class used to render the close icon
+* @type String
+*/
+YAHOO.widget.CalendarGroup.CSS_2UPCLOSE = "close-icon";
+
+YAHOO.augment(YAHOO.widget.CalendarGroup, YAHOO.widget.Calendar, "buildDayLabel",
+ "buildMonthLabel",
+ "renderOutOfBoundsDate",
+ "renderRowHeader",
+ "renderRowFooter",
+ "renderCellDefault",
+ "styleCellDefault",
+ "renderCellStyleHighlight1",
+ "renderCellStyleHighlight2",
+ "renderCellStyleHighlight3",
+ "renderCellStyleHighlight4",
+ "renderCellStyleToday",
+ "renderCellStyleSelected",
+ "renderCellNotThisMonth",
+ "renderBodyCellRestricted",
+ "initStyles",
+ "configTitle",
+ "configClose",
+ "hide",
+ "show",
+ "browser");
+
+/**
+* Returns a string representation of the object.
+* @method toString
+* @return {String} A string representation of the CalendarGroup object.
+*/
+YAHOO.widget.CalendarGroup.prototype.toString = function() {
+ return "CalendarGroup " + this.id;
+};
+
+YAHOO.widget.CalGrp = YAHOO.widget.CalendarGroup;
+
+/**
+* @class YAHOO.widget.Calendar2up
+* @extends YAHOO.widget.CalendarGroup
+* @deprecated The old Calendar2up class is no longer necessary, since CalendarGroup renders in a 2up view by default.
+*/
+YAHOO.widget.Calendar2up = function(id, containerId, config) {
+ this.init(id, containerId, config);
+};
+
+YAHOO.extend(YAHOO.widget.Calendar2up, YAHOO.widget.CalendarGroup);
+
+/**
+* @deprecated The old Calendar2up class is no longer necessary, since CalendarGroup renders in a 2up view by default.
+*/
+YAHOO.widget.Cal2up = YAHOO.widget.Calendar2up;
+
+YAHOO.register("calendar", YAHOO.widget.Calendar, {version: "2.2.0", build: "127"});
diff --git a/interface/ispconfig/interface/js/yui/calendar/calendar-min.js b/interface/ispconfig/interface/js/yui/calendar/calendar-min.js
new file mode 100644
index 0000000000000000000000000000000000000000..ca96867314166139229fb1f331ad830e9787f9c6
--- /dev/null
+++ b/interface/ispconfig/interface/js/yui/calendar/calendar-min.js
@@ -0,0 +1,116 @@
+/*
+Copyright (c) 2007, Yahoo! Inc. All rights reserved.
+Code licensed under the BSD License:
+http://developer.yahoo.net/yui/license.txt
+version: 2.2.0
+*/
+
+YAHOO.util.Config=function(owner){if(owner){this.init(owner);}};YAHOO.util.Config.prototype={owner:null,queueInProgress:false,checkBoolean:function(val){if(typeof val=='boolean'){return true;}else{return false;}},checkNumber:function(val){if(isNaN(val)){return false;}else{return true;}}};YAHOO.util.Config.prototype.init=function(owner){this.owner=owner;this.configChangedEvent=new YAHOO.util.CustomEvent("configChanged");this.queueInProgress=false;var config={};var initialConfig={};var eventQueue=[];var fireEvent=function(key,value){key=key.toLowerCase();var property=config[key];if(typeof property!='undefined'&&property.event){property.event.fire(value);}};this.addProperty=function(key,propertyObject){key=key.toLowerCase();config[key]=propertyObject;propertyObject.event=new YAHOO.util.CustomEvent(key);propertyObject.key=key;if(propertyObject.handler){propertyObject.event.subscribe(propertyObject.handler,this.owner,true);}
+this.setProperty(key,propertyObject.value,true);if(!propertyObject.suppressEvent){this.queueProperty(key,propertyObject.value);}};this.getConfig=function(){var cfg={};for(var prop in config){var property=config[prop];if(typeof property!='undefined'&&property.event){cfg[prop]=property.value;}}
+return cfg;};this.getProperty=function(key){key=key.toLowerCase();var property=config[key];if(typeof property!='undefined'&&property.event){return property.value;}else{return undefined;}};this.resetProperty=function(key){key=key.toLowerCase();var property=config[key];if(typeof property!='undefined'&&property.event){if(initialConfig[key]&&initialConfig[key]!='undefined'){this.setProperty(key,initialConfig[key]);}
+return true;}else{return false;}};this.setProperty=function(key,value,silent){key=key.toLowerCase();if(this.queueInProgress&&!silent){this.queueProperty(key,value);return true;}else{var property=config[key];if(typeof property!='undefined'&&property.event){if(property.validator&&!property.validator(value)){return false;}else{property.value=value;if(!silent){fireEvent(key,value);this.configChangedEvent.fire([key,value]);}
+return true;}}else{return false;}}};this.queueProperty=function(key,value){key=key.toLowerCase();var property=config[key];if(typeof property!='undefined'&&property.event){if(typeof value!='undefined'&&property.validator&&!property.validator(value)){return false;}else{if(typeof value!='undefined'){property.value=value;}else{value=property.value;}
+var foundDuplicate=false;for(var i=0;i11){while(newMonth>11){newMonth-=12;years+=1;}}
+d.setMonth(newMonth);d.setFullYear(date.getFullYear()+years);break;case this.DAY:d.setDate(date.getDate()+amount);break;case this.YEAR:d.setFullYear(date.getFullYear()+amount);break;case this.WEEK:d.setDate(date.getDate()+(amount*7));break;}
+return d;},subtract:function(date,field,amount){return this.add(date,field,(amount*-1));},before:function(date,compareTo){var ms=compareTo.getTime();if(date.getTime()ms){return true;}else{return false;}},between:function(date,dateBegin,dateEnd){if(this.after(date,dateBegin)&&this.before(date,dateEnd)){return true;}else{return false;}},getJan1:function(calendarYear){return new Date(calendarYear,0,1);},getDayOffset:function(date,calendarYear){var beginYear=this.getJan1(calendarYear);var dayOffset=Math.ceil((date.getTime()-beginYear.getTime())/this.ONE_DAY_MS);return dayOffset;},getWeekNumber:function(date,calendarYear){date=this.clearTime(date);var nearestThurs=new Date(date.getTime()+(4*this.ONE_DAY_MS)-((date.getDay())*this.ONE_DAY_MS));var jan1=new Date(nearestThurs.getFullYear(),0,1);var dayOfYear=((nearestThurs.getTime()-jan1.getTime())/this.ONE_DAY_MS)-1;var weekNum=Math.ceil((dayOfYear)/7);return weekNum;},isYearOverlapWeek:function(weekBeginDate){var overlaps=false;var nextWeek=this.add(weekBeginDate,this.DAY,6);if(nextWeek.getFullYear()!=weekBeginDate.getFullYear()){overlaps=true;}
+return overlaps;},isMonthOverlapWeek:function(weekBeginDate){var overlaps=false;var nextWeek=this.add(weekBeginDate,this.DAY,6);if(nextWeek.getMonth()!=weekBeginDate.getMonth()){overlaps=true;}
+return overlaps;},findMonthStart:function(date){var start=new Date(date.getFullYear(),date.getMonth(),1);return start;},findMonthEnd:function(date){var start=this.findMonthStart(date);var nextMonth=this.add(start,this.MONTH,1);var end=this.subtract(nextMonth,this.DAY,1);return end;},clearTime:function(date){date.setHours(12,0,0,0);return date;}};YAHOO.widget.Calendar=function(id,containerId,config){this.init(id,containerId,config);};YAHOO.widget.Calendar.IMG_ROOT=null;YAHOO.widget.Calendar.DATE="D";YAHOO.widget.Calendar.MONTH_DAY="MD";YAHOO.widget.Calendar.WEEKDAY="WD";YAHOO.widget.Calendar.RANGE="R";YAHOO.widget.Calendar.MONTH="M";YAHOO.widget.Calendar.DISPLAY_DAYS=42;YAHOO.widget.Calendar.STOP_RENDER="S";YAHOO.widget.Calendar.prototype={Config:null,parent:null,index:-1,cells:null,cellDates:null,id:null,oDomContainer:null,today:null,renderStack:null,_renderStack:null,_selectedDates:null,domEventMap:null};YAHOO.widget.Calendar.prototype.init=function(id,containerId,config){this.initEvents();this.today=new Date();YAHOO.widget.DateMath.clearTime(this.today);this.id=id;this.oDomContainer=document.getElementById(containerId);this.cfg=new YAHOO.util.Config(this);this.Options={};this.Locale={};this.initStyles();YAHOO.util.Dom.addClass(this.oDomContainer,this.Style.CSS_CONTAINER);YAHOO.util.Dom.addClass(this.oDomContainer,this.Style.CSS_SINGLE);this.cellDates=[];this.cells=[];this.renderStack=[];this._renderStack=[];this.setupConfig();if(config){this.cfg.applyConfig(config,true);}
+this.cfg.fireQueue();};YAHOO.widget.Calendar.prototype.configIframe=function(type,args,obj){var useIframe=args[0];if(YAHOO.util.Dom.inDocument(this.oDomContainer)){if(useIframe){var pos=YAHOO.util.Dom.getStyle(this.oDomContainer,"position");if(this.browser=="ie"&&(pos=="absolute"||pos=="relative")){if(!YAHOO.util.Dom.inDocument(this.iframe)){this.iframe=document.createElement("iframe");this.iframe.src="javascript:false;";YAHOO.util.Dom.setStyle(this.iframe,"opacity","0");this.oDomContainer.insertBefore(this.iframe,this.oDomContainer.firstChild);}}}else{if(this.iframe){if(this.iframe.parentNode){this.iframe.parentNode.removeChild(this.iframe);}
+this.iframe=null;}}}};YAHOO.widget.Calendar.prototype.configTitle=function(type,args,obj){var title=args[0];var close=this.cfg.getProperty("close");var titleDiv;if(title&&title!==""){titleDiv=YAHOO.util.Dom.getElementsByClassName(YAHOO.widget.CalendarGroup.CSS_2UPTITLE,"div",this.oDomContainer)[0]||document.createElement("div");titleDiv.className=YAHOO.widget.CalendarGroup.CSS_2UPTITLE;titleDiv.innerHTML=title;this.oDomContainer.insertBefore(titleDiv,this.oDomContainer.firstChild);YAHOO.util.Dom.addClass(this.oDomContainer,"withtitle");}else{titleDiv=YAHOO.util.Dom.getElementsByClassName(YAHOO.widget.CalendarGroup.CSS_2UPTITLE,"div",this.oDomContainer)[0]||null;if(titleDiv){YAHOO.util.Event.purgeElement(titleDiv);this.oDomContainer.removeChild(titleDiv);}
+if(!close){YAHOO.util.Dom.removeClass(this.oDomContainer,"withtitle");}}};YAHOO.widget.Calendar.prototype.configClose=function(type,args,obj){var close=args[0];var title=this.cfg.getProperty("title");var DEPR_CLOSE_PATH="us/my/bn/x_d.gif";var linkClose;if(close===true){linkClose=YAHOO.util.Dom.getElementsByClassName("link-close","a",this.oDomContainer)[0]||document.createElement("a");linkClose.href="javascript:void(null);";linkClose.className="link-close";YAHOO.util.Event.addListener(linkClose,"click",this.hide,this,true);if(YAHOO.widget.Calendar.IMG_ROOT!==null){var imgClose=document.createElement("img");imgClose.src=YAHOO.widget.Calendar.IMG_ROOT+DEPR_CLOSE_PATH;imgClose.className=YAHOO.widget.CalendarGroup.CSS_2UPCLOSE;linkClose.appendChild(imgClose);}else{linkClose.innerHTML='';}
+this.oDomContainer.appendChild(linkClose);YAHOO.util.Dom.addClass(this.oDomContainer,"withtitle");}else{linkClose=YAHOO.util.Dom.getElementsByClassName("link-close","a",this.oDomContainer)[0]||null;if(linkClose){YAHOO.util.Event.purgeElement(linkClose);this.oDomContainer.removeChild(linkClose);}
+if(!title||title===""){YAHOO.util.Dom.removeClass(this.oDomContainer,"withtitle");}}};YAHOO.widget.Calendar.prototype.initEvents=function(){this.beforeSelectEvent=new YAHOO.util.CustomEvent("beforeSelect");this.selectEvent=new YAHOO.util.CustomEvent("select");this.beforeDeselectEvent=new YAHOO.util.CustomEvent("beforeDeselect");this.deselectEvent=new YAHOO.util.CustomEvent("deselect");this.changePageEvent=new YAHOO.util.CustomEvent("changePage");this.beforeRenderEvent=new YAHOO.util.CustomEvent("beforeRender");this.renderEvent=new YAHOO.util.CustomEvent("render");this.resetEvent=new YAHOO.util.CustomEvent("reset");this.clearEvent=new YAHOO.util.CustomEvent("clear");this.beforeSelectEvent.subscribe(this.onBeforeSelect,this,true);this.selectEvent.subscribe(this.onSelect,this,true);this.beforeDeselectEvent.subscribe(this.onBeforeDeselect,this,true);this.deselectEvent.subscribe(this.onDeselect,this,true);this.changePageEvent.subscribe(this.onChangePage,this,true);this.renderEvent.subscribe(this.onRender,this,true);this.resetEvent.subscribe(this.onReset,this,true);this.clearEvent.subscribe(this.onClear,this,true);};YAHOO.widget.Calendar.prototype.doSelectCell=function(e,cal){var target=YAHOO.util.Event.getTarget(e);var cell,index,d,date;while(target.tagName.toLowerCase()!="td"&&!YAHOO.util.Dom.hasClass(target,cal.Style.CSS_CELL_SELECTABLE)){target=target.parentNode;if(target.tagName.toLowerCase()=="html"){return;}}
+cell=target;if(YAHOO.util.Dom.hasClass(cell,cal.Style.CSS_CELL_SELECTABLE)){index=cell.id.split("cell")[1];d=cal.cellDates[index];date=new Date(d[0],d[1]-1,d[2]);var link;if(cal.Options.MULTI_SELECT){link=cell.getElementsByTagName("a")[0];if(link){link.blur();}
+var cellDate=cal.cellDates[index];var cellDateIndex=cal._indexOfSelectedFieldArray(cellDate);if(cellDateIndex>-1){cal.deselectCell(index);}else{cal.selectCell(index);}}else{link=cell.getElementsByTagName("a")[0];if(link){link.blur();}
+cal.selectCell(index);}}};YAHOO.widget.Calendar.prototype.doCellMouseOver=function(e,cal){var target;if(e){target=YAHOO.util.Event.getTarget(e);}else{target=this;}
+while(target.tagName.toLowerCase()!="td"){target=target.parentNode;if(target.tagName.toLowerCase()=="html"){return;}}
+if(YAHOO.util.Dom.hasClass(target,cal.Style.CSS_CELL_SELECTABLE)){YAHOO.util.Dom.addClass(target,cal.Style.CSS_CELL_HOVER);}};YAHOO.widget.Calendar.prototype.doCellMouseOut=function(e,cal){var target;if(e){target=YAHOO.util.Event.getTarget(e);}else{target=this;}
+while(target.tagName.toLowerCase()!="td"){target=target.parentNode;if(target.tagName.toLowerCase()=="html"){return;}}
+if(YAHOO.util.Dom.hasClass(target,cal.Style.CSS_CELL_SELECTABLE)){YAHOO.util.Dom.removeClass(target,cal.Style.CSS_CELL_HOVER);}};YAHOO.widget.Calendar.prototype.setupConfig=function(){this.cfg.addProperty("pagedate",{value:new Date(),handler:this.configPageDate});this.cfg.addProperty("selected",{value:[],handler:this.configSelected});this.cfg.addProperty("title",{value:"",handler:this.configTitle});this.cfg.addProperty("close",{value:false,handler:this.configClose});this.cfg.addProperty("iframe",{value:true,handler:this.configIframe,validator:this.cfg.checkBoolean});this.cfg.addProperty("mindate",{value:null,handler:this.configMinDate});this.cfg.addProperty("maxdate",{value:null,handler:this.configMaxDate});this.cfg.addProperty("MULTI_SELECT",{value:false,handler:this.configOptions,validator:this.cfg.checkBoolean});this.cfg.addProperty("START_WEEKDAY",{value:0,handler:this.configOptions,validator:this.cfg.checkNumber});this.cfg.addProperty("SHOW_WEEKDAYS",{value:true,handler:this.configOptions,validator:this.cfg.checkBoolean});this.cfg.addProperty("SHOW_WEEK_HEADER",{value:false,handler:this.configOptions,validator:this.cfg.checkBoolean});this.cfg.addProperty("SHOW_WEEK_FOOTER",{value:false,handler:this.configOptions,validator:this.cfg.checkBoolean});this.cfg.addProperty("HIDE_BLANK_WEEKS",{value:false,handler:this.configOptions,validator:this.cfg.checkBoolean});this.cfg.addProperty("NAV_ARROW_LEFT",{value:null,handler:this.configOptions});this.cfg.addProperty("NAV_ARROW_RIGHT",{value:null,handler:this.configOptions});this.cfg.addProperty("MONTHS_SHORT",{value:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],handler:this.configLocale});this.cfg.addProperty("MONTHS_LONG",{value:["January","February","March","April","May","June","July","August","September","October","November","December"],handler:this.configLocale});this.cfg.addProperty("WEEKDAYS_1CHAR",{value:["S","M","T","W","T","F","S"],handler:this.configLocale});this.cfg.addProperty("WEEKDAYS_SHORT",{value:["Su","Mo","Tu","We","Th","Fr","Sa"],handler:this.configLocale});this.cfg.addProperty("WEEKDAYS_MEDIUM",{value:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],handler:this.configLocale});this.cfg.addProperty("WEEKDAYS_LONG",{value:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],handler:this.configLocale});var refreshLocale=function(){this.cfg.refireEvent("LOCALE_MONTHS");this.cfg.refireEvent("LOCALE_WEEKDAYS");};this.cfg.subscribeToConfigEvent("START_WEEKDAY",refreshLocale,this,true);this.cfg.subscribeToConfigEvent("MONTHS_SHORT",refreshLocale,this,true);this.cfg.subscribeToConfigEvent("MONTHS_LONG",refreshLocale,this,true);this.cfg.subscribeToConfigEvent("WEEKDAYS_1CHAR",refreshLocale,this,true);this.cfg.subscribeToConfigEvent("WEEKDAYS_SHORT",refreshLocale,this,true);this.cfg.subscribeToConfigEvent("WEEKDAYS_MEDIUM",refreshLocale,this,true);this.cfg.subscribeToConfigEvent("WEEKDAYS_LONG",refreshLocale,this,true);this.cfg.addProperty("LOCALE_MONTHS",{value:"long",handler:this.configLocaleValues});this.cfg.addProperty("LOCALE_WEEKDAYS",{value:"short",handler:this.configLocaleValues});this.cfg.addProperty("DATE_DELIMITER",{value:",",handler:this.configLocale});this.cfg.addProperty("DATE_FIELD_DELIMITER",{value:"/",handler:this.configLocale});this.cfg.addProperty("DATE_RANGE_DELIMITER",{value:"-",handler:this.configLocale});this.cfg.addProperty("MY_MONTH_POSITION",{value:1,handler:this.configLocale,validator:this.cfg.checkNumber});this.cfg.addProperty("MY_YEAR_POSITION",{value:2,handler:this.configLocale,validator:this.cfg.checkNumber});this.cfg.addProperty("MD_MONTH_POSITION",{value:1,handler:this.configLocale,validator:this.cfg.checkNumber});this.cfg.addProperty("MD_DAY_POSITION",{value:2,handler:this.configLocale,validator:this.cfg.checkNumber});this.cfg.addProperty("MDY_MONTH_POSITION",{value:1,handler:this.configLocale,validator:this.cfg.checkNumber});this.cfg.addProperty("MDY_DAY_POSITION",{value:2,handler:this.configLocale,validator:this.cfg.checkNumber});this.cfg.addProperty("MDY_YEAR_POSITION",{value:3,handler:this.configLocale,validator:this.cfg.checkNumber});};YAHOO.widget.Calendar.prototype.configPageDate=function(type,args,obj){this.cfg.setProperty("pagedate",this._parsePageDate(args[0]),true);};YAHOO.widget.Calendar.prototype.configMinDate=function(type,args,obj){var val=args[0];if(typeof val=='string'){val=this._parseDate(val);this.cfg.setProperty("mindate",new Date(val[0],(val[1]-1),val[2]));}};YAHOO.widget.Calendar.prototype.configMaxDate=function(type,args,obj){var val=args[0];if(typeof val=='string'){val=this._parseDate(val);this.cfg.setProperty("maxdate",new Date(val[0],(val[1]-1),val[2]));}};YAHOO.widget.Calendar.prototype.configSelected=function(type,args,obj){var selected=args[0];if(selected){if(typeof selected=='string'){this.cfg.setProperty("selected",this._parseDates(selected),true);}}
+if(!this._selectedDates){this._selectedDates=this.cfg.getProperty("selected");}};YAHOO.widget.Calendar.prototype.configOptions=function(type,args,obj){type=type.toUpperCase();var val=args[0];this.Options[type]=val;};YAHOO.widget.Calendar.prototype.configLocale=function(type,args,obj){type=type.toUpperCase();var val=args[0];this.Locale[type]=val;this.cfg.refireEvent("LOCALE_MONTHS");this.cfg.refireEvent("LOCALE_WEEKDAYS");};YAHOO.widget.Calendar.prototype.configLocaleValues=function(type,args,obj){type=type.toUpperCase();var val=args[0];switch(type){case"LOCALE_MONTHS":switch(val){case"short":this.Locale.LOCALE_MONTHS=this.cfg.getProperty("MONTHS_SHORT").concat();break;case"long":this.Locale.LOCALE_MONTHS=this.cfg.getProperty("MONTHS_LONG").concat();break;}
+break;case"LOCALE_WEEKDAYS":switch(val){case"1char":this.Locale.LOCALE_WEEKDAYS=this.cfg.getProperty("WEEKDAYS_1CHAR").concat();break;case"short":this.Locale.LOCALE_WEEKDAYS=this.cfg.getProperty("WEEKDAYS_SHORT").concat();break;case"medium":this.Locale.LOCALE_WEEKDAYS=this.cfg.getProperty("WEEKDAYS_MEDIUM").concat();break;case"long":this.Locale.LOCALE_WEEKDAYS=this.cfg.getProperty("WEEKDAYS_LONG").concat();break;}
+var START_WEEKDAY=this.cfg.getProperty("START_WEEKDAY");if(START_WEEKDAY>0){for(var w=0;w";html[html.length]="