Permalink
Browse files

API CHANGE Deprecated ImageFormAction, use FormAction with setAttribu…

…te('src', 'myimage.png')
  • Loading branch information...
1 parent d535847 commit b4d7e51da3ec8901cf25bdba2904df7f98013013 @chillu chillu committed Dec 22, 2011
Showing with 5 additions and 1 deletion.
  1. +5 −1 forms/ImageFormAction.php
@@ -1,6 +1,8 @@
<?php
/**
- * Action that uses an image instead of a button
+ * Action that uses an image instead of a button.
+ *
+ * @deprecated 3.0 Use FormAction with setAttribute('src', 'myimage.png') and custom JavaScript to achieve hover effect
* @package forms
* @subpackage actions
*/
@@ -16,6 +18,8 @@ class ImageFormAction extends FormAction {
* @param form The parent form, auto-set when the field is placed inside a form
*/
function __construct($action, $title = "", $image = "", $hoverImage = null, $className = null, $form = null) {
+ Deprecation::notice('3.0', "Use FormAction with setAttribute('src', 'myimage.png') and custom JavaScript to achieve hover effect");
+
$this->image = $image;
$this->hoverImage = $hoverImage;
$this->className = $className;

0 comments on commit b4d7e51

Please sign in to comment.