Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 2.4.0

Request #8626 new subtype: ximage for <img ....>
Submitted: 2006-09-03 19:16 UTC
From: b_j at tar dot hu Assigned: avb
Status: Closed Package: HTML_QuickForm2 (version 3.2.6)
PHP Version: Irrelevant OS:
Roadmaps: 0.6.0    
Subscription  


 [2006-09-03 19:16 UTC] b_j at tar dot hu (Barczi József)
Description: ------------ HTML/QuickForm/ximage.php: <?php require_once 'HTML/QuickForm/element.php'; class HTML_QuickForm_ximage extends HTML_QuickForm_element { function HTML_QuickForm_ximage($elementName = null, $src='', $attributes = null){ $this->HTML_QuickForm_element($elementName, null, $attributes); $this->setSource($src); $this->setType('ximage'); } function setType($type){ $this->_type = $type; //$this->updateAttributes(array('type'=>$type)); } // end func setType function setSource($src){ $this->updateAttributes(array('src' => $src)); } // end func setSource function setBorder($border){ $this->updateAttributes(array('border' => $border)); } // end func setBorder function setAlign($align){ $this->updateAttributes(array('align' => $align)); } // end func setAlign function setHeight($height){ $this->updateAttributes(array('height' => $height)); } function setWidth($width){ $this->updateAttributes(array('width' => $width)); } function freeze(){ return false; } //end func freeze function toHtml(){ $this->setType(null); return '<IMG' . $this->getAttributes(true) . ' />'; } function getFrozenHtml(){ return $this->toHtml(); } function setName($name){ $this->updateAttributes(array('name' => $name)); } function getName(){ return $this->getAttribute('name'); } } ?> HTML/QuickForm.php: .... //Hungarian translation: var $_jsPrefix = 'Rossz adat'; var $_jsPostfix = 'Javítani kell ezt az adatot'; var $_requiredNote = '<span style="font-size:80%; color:#ff0000;">*</span>'. '<span style="font-size:80%;"> Kötelezõ mezõ</span>'; .... $GLOBALS['HTML_QUICKFORM_ELEMENT_TYPES'] = array( 'group' =>array('HTML/QuickForm/group.php','HTML_QuickForm_group'), 'hidden' =>array('HTML/QuickForm/hidden.php','HTML_QuickForm_hidden'), 'reset' =>array('HTML/QuickForm/reset.php','HTML_QuickForm_reset'), 'checkbox' =>array('HTML/QuickForm/checkbox.php','HTML_QuickForm_checkbox'), 'file' =>array('HTML/QuickForm/file.php','HTML_QuickForm_file'), 'image' =>array('HTML/QuickForm/image.php','HTML_QuickForm_image'), 'password' =>array('HTML/QuickForm/password.php','HTML_QuickForm_password'), 'radio' =>array('HTML/QuickForm/radio.php','HTML_QuickForm_radio'), 'button' =>array('HTML/QuickForm/button.php','HTML_QuickForm_button'), 'submit' =>array('HTML/QuickForm/submit.php','HTML_QuickForm_submit'), 'select' =>array('HTML/QuickForm/select.php','HTML_QuickForm_select'), 'hiddenselect' =>array('HTML/QuickForm/hiddenselect.php','HTML_QuickForm_hiddenselect'), 'text' =>array('HTML/QuickForm/text.php','HTML_QuickForm_text'), 'textarea' =>array('HTML/QuickForm/textarea.php','HTML_QuickForm_textarea'), 'link' =>array('HTML/QuickForm/link.php','HTML_QuickForm_link'), 'advcheckbox' =>array('HTML/QuickForm/advcheckbox.php','HTML_QuickForm_advcheckbox'), 'date' =>array('HTML/QuickForm/date.php','HTML_QuickForm_date'), 'static' =>array('HTML/QuickForm/static.php','HTML_QuickForm_static'), 'header' =>array('HTML/QuickForm/header.php', 'HTML_QuickForm_header'), 'html' =>array('HTML/QuickForm/html.php', 'HTML_QuickForm_html'), 'hierselect' =>array('HTML/QuickForm/hierselect.php', 'HTML_QuickForm_hierselect'), 'autocomplete' =>array('HTML/QuickForm/autocomplete.php', 'HTML_QuickForm_autocomplete'), 'xbutton' =>array('HTML/QuickForm/xbutton.php','HTML_QuickForm_xbutton'), //BJ 'ximage' =>array('HTML/QuickForm/ximage.php','HTML_QuickForm_ximage') ); ....

Comments

 [2006-09-04 16:22 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2011-05-27 15:10 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!