Changeset 1173
- Timestamp:
- 11/19/08 16:20:20 (2 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/lib/jelix/plugins/jforms/html/html.jformsbuilder.php
r1167 r1173 4 4 * @subpackage forms 5 5 * @author Laurent Jouanneau 6 * @contributor Julien Issler 6 * @contributor Julien Issler, Dominique Papin 7 7 * @copyright 2006-2008 Laurent Jouanneau 8 * @copyright 2008 Julien Issler 8 * @copyright 2008 Julien Issler, 2008 Dominique Papin 9 9 * @link http://www.jelix.org 10 10 * @licence http://www.gnu.org/licenses/lgpl.html GNU Lesser General Public Licence, see LICENCE file … … 97 97 'helpDecorator'=>'jFormsJQHelpDecoratorAlert', 'method'=>'post'), $params); 98 98 99 $url = jUrl::get($this->_action, $this->_actionParams, 2); // retourne le jurl correspondant 100 echo '<form action="',$url->getPath(),'" method="'.$this->options['method'].'" id="', $this->_name,'"'; 99 100 if (preg_match('/^http:\/\//',$this->_action)) { 101 $urlParams = $this->_actionParams; 102 echo '<form action="',$this->_action,'" method="'.$this->options['method'].'" id="', $this->_name,'"'; 103 } else { 104 $url = jUrl::get($this->_action, $this->_actionParams, 2); // retourne le jurl correspondant 105 $urlParams = $url->params; 106 echo '<form action="',$url->getPath(),'" method="'.$this->options['method'].'" id="', $this->_name,'"'; 107 } 101 108 if($this->_form->hasUpload()) 102 109 echo ' enctype="multipart/form-data">'; … … 114 121 115 122 $hiddens = ''; 116 foreach ($url ->params as $p_name => $p_value) {123 foreach ($urlParams as $p_name => $p_value) { 117 124 $hiddens .= '<input type="hidden" name="'. $p_name .'" value="'. htmlspecialchars($p_value). '"'.$this->_endt. "\n"; 118 125 } … … 586 593 $displayedControls = true; 587 594 echo ' <span class="jforms-item-controls">'; 588 // we remove readonly status so when a user change the choice and 595 // we remove readonly status so when a user change the choice and 589 596 // javascript is deactivated, it can still change the value of the control 590 597 $ro = $c->isReadOnly(); trunk/lib/jelix/plugins/jforms/htmllight/htmllight.jformsbuilder.php
r1167 r1173 4 4 * @subpackage forms 5 5 * @author Laurent Jouanneau 6 * @contributor Julien Issler 6 * @contributor Julien Issler, Dominique Papin 7 7 * @copyright 2006-2008 Laurent Jouanneau 8 * @copyright 2008 Julien Issler 8 * @copyright 2008 Julien Issler, 2008 Dominique Papin 9 9 * @link http://www.jelix.org 10 10 * @licence http://www.gnu.org/licenses/lgpl.html GNU Lesser General Public Licence, see LICENCE file … … 96 96 'helpDecorator'=>'jFormsHelpDecoratorAlert', 'method'=>'post'), $params); 97 97 98 $url = jUrl::get($this->_action, $this->_actionParams, 2); // retourne le jurl correspondant 99 echo '<form action="',$url->getPath(),'" method="'.$this->options['method'].'" id="', $this->_name,'"'; 98 if (preg_match('/^http:\/\//',$this->_action)) { 99 $urlParams = $this->_actionParams; 100 echo '<form action="',$this->_action,'" method="'.$this->options['method'].'" id="', $this->_name,'"'; 101 } else { 102 $url = jUrl::get($this->_action, $this->_actionParams, 2); // retourne le jurl correspondant 103 $urlParams = $url->params; 104 echo '<form action="',$url->getPath(),'" method="'.$this->options['method'].'" id="', $this->_name,'"'; 105 } 100 106 if($this->_form->hasUpload()) 101 107 echo ' enctype="multipart/form-data">'; … … 113 119 114 120 $hiddens = ''; 115 foreach ($url ->params as $p_name => $p_value) {121 foreach ($urlParams as $p_name => $p_value) { 116 122 $hiddens .= '<input type="hidden" name="'. $p_name .'" value="'. htmlspecialchars($p_value). '"'.$this->_endt. "\n"; 117 123 } … … 585 591 $displayedControls = true; 586 592 echo ' <span class="jforms-item-controls">'; 587 // we remove readonly status so when a user change the choice and 593 // we remove readonly status so when a user change the choice and 588 594 // javascript is deactivated, it can still change the value of the control 589 595 $ro = $c->isReadOnly();
