]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
use - instead of _ for forms, and unique ids for submits
authorEvan Prodromou <evan@status.net>
Wed, 7 Mar 2012 20:46:58 +0000 (14:46 -0600)
committerEvan Prodromou <evan@status.net>
Wed, 7 Mar 2012 20:46:58 +0000 (14:46 -0600)
ActivitySpamPlugin.php
trainhamform.php
trainspamform.php

index b62401ce1ba816d191b26c4f9d6d34200969e1f3..3efa92c935ec5827b3c7885c6d2397ac0f384b31 100644 (file)
@@ -218,8 +218,8 @@ class ActivitySpamPlugin extends Plugin
     function onEndShowStyles($action)
     {
         $action->element('style', null,
-                         'form_train_spam input.submit { background: url("'.$this->path('icons/bullet_black.png').'") no-repeat 0px 0px } ' . "\n" .
-                         'form_train_spam input.submit { background: url("'.$this->path('icons/exclamation.png').'") no-repeat 0px 0px } ');
+                         '.form-train-spam input.submit { background: url("'.$this->path('icons/bullet_black.png').'") no-repeat 0px 0px } ' . "\n" .
+                         '.form-train-ham input.submit { background: url("'.$this->path('icons/exclamation.png').'") no-repeat 0px 0px } ');
         return true;
     }
 
index 410b3206b8e94bfcb6affcda117d2f36f3ffa89f..05cadaa95398cf553a7e3f11695be976d53e0171 100644 (file)
@@ -92,7 +92,7 @@ class TrainHamForm extends Form {
 
     function formActions()
     {
-        $this->submit('submit',
+        $this->submit('train-ham-submit-' . $this->notice->id,
                       _('Train ham'),
                       'submit',
                       null,
@@ -110,7 +110,7 @@ class TrainHamForm extends Form {
 
     function id()
     {
-        return 'train_ham_' . $this->notice->id;
+        return 'train-ham-' . $this->notice->id;
     }
 
     /**
@@ -141,6 +141,6 @@ class TrainHamForm extends Form {
 
     function formClass()
     {
-        return 'form_train_ham ajax';
+        return 'form-train-ham ajax';
     }
 }
index ecf7b04190c5c501a1d3d7fc4427cf7d88e27f7b..ee1ecd2a74fac1fd320408552606cbbfeed66ff4 100644 (file)
@@ -92,7 +92,7 @@ class TrainSpamForm extends Form {
 
     function formActions()
     {
-        $this->submit('submit',
+        $this->submit('train-spam-submit-' . $this->notice->id,
                       _('Train spam'),
                       'submit',
                       null,
@@ -110,7 +110,7 @@ class TrainSpamForm extends Form {
 
     function id()
     {
-        return 'train_spam_' . $this->notice->id;
+        return 'train-spam-' . $this->notice->id;
     }
 
     /**
@@ -141,6 +141,6 @@ class TrainSpamForm extends Form {
 
     function formClass()
     {
-        return 'form_train_spam ajax';
+        return 'form-train-spam ajax';
     }
 }