summaryrefslogtreecommitdiff
path: root/framework/Web/UI/WebControls/TImageButton.php
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Web/UI/WebControls/TImageButton.php')
-rw-r--r--framework/Web/UI/WebControls/TImageButton.php3
1 files changed, 1 insertions, 2 deletions
diff --git a/framework/Web/UI/WebControls/TImageButton.php b/framework/Web/UI/WebControls/TImageButton.php
index 669e517e..33dfde75 100644
--- a/framework/Web/UI/WebControls/TImageButton.php
+++ b/framework/Web/UI/WebControls/TImageButton.php
@@ -96,8 +96,7 @@ class TImageButton extends TImage implements IPostBackDataHandler, IPostBackEven
if($this->getEnabled(true))
{
- $onclick='';
- $onclick=$this->hasAttribute('onclick')?$this->getAttributes()->remove('onclick'):'';
+ $onclick=$this->removeAttribute('onclick');
$onclick=THttpUtility::trimJavaScriptString($onclick).THttpUtility::trimJavaScriptString($this->getOnClientClick());
$onclick.=$page->getClientScript()->getPostBackEventReference($this,'',$this->getPostBackOptions(),false);
if(!empty($onclick))