/docs/MyDocs

To get this branch, use:
bzr branch http://darksoft.org/webbzr/docs/MyDocs

« back to all changes in this revision

Viewing changes to Administration/Linux.Soft/web/squirrelmail/gpg-ds-jserror.diff

  • Committer: Suren A. Chilingaryan
  • Date: 2009-04-09 03:21:08 UTC
  • Revision ID: csa@dside.dyndns.org-20090409032108-w4edamdh4adrgdu3
import

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
diff -dPNur gpg.old/gpg_hook_functions.php gpg/gpg_hook_functions.php
 
2
--- gpg.old/gpg_hook_functions.php      2007-06-11 10:36:16.000000000 +0000
 
3
+++ gpg/gpg_hook_functions.php  2007-06-11 10:46:54.000000000 +0000
 
4
@@ -983,6 +983,9 @@
 
5
 if ($debug) { echo "<p>no_encrypt_on_setup: $no_encrypt_on_setup<br>gpg_export: $gpg_export<br>pubring: $pubring<br>secring: $secring<br>"; }
 
6
 
 
7
 
 
8
+    global $gpg_flag_js_installed;
 
9
+    $gpg_flag_js_installed = false;
 
10
+    
 
11
 /**
 
12
  * Some people may choose to disable javascript even though their
 
13
  * browser is capable of using it. So these folks don't complain,
 
14
@@ -1037,6 +1040,7 @@
 
15
 
 
16
     if ((file_exists($secring)) and (filesize($secring)>0) and ($GLOBALS['GPG_SYSTEM_OPTIONS']['allowprivatekeys']=='true') and ($use_signing_key_id=='true')){
 
17
         if (!$no_encrypt_on_setup) {
 
18
+           $gpg_flag_js_installed = true;
 
19
             echo <<<TILLEND
 
20
 <script type='text/javascript'>
 
21
 <!--
 
22
diff -dPNur gpg.old/setup.php gpg/setup.php
 
23
--- gpg.old/setup.php   2007-06-11 10:37:57.000000000 +0000
 
24
+++ gpg/setup.php       2007-06-11 10:47:17.000000000 +0000
 
25
@@ -147,7 +147,10 @@
 
26
  * @return void
 
27
  */
 
28
 function gpg_compose_form () {
 
29
-    echo 'onsubmit="return gpg_composeSubmit(this);"';
 
30
+    global $gpg_flag_js_installed;
 
31
+    if ($gpg_flag_js_installed) {
 
32
+       echo 'onsubmit="return gpg_composeSubmit(this);"';
 
33
+    }
 
34
 }
 
35
 
 
36