Hi all, in HtmlHelper::tag() (line 728) we found this code:

if ($text === null) {
        $tag = 'tagstart';
} else {
        $tag = 'tag';
}

So, if you do the call

    echo $html->tag('input', 'name', 'value');

It's output: <input class='value'>name</input>
I except: <input type='text' name='name' value='value'/>

Other way:

    echo $html->tag('input', 'name', array('value' => 'thevalue',
class='miclass'));

output: <input value='thevalue' class='miclass'>name</input>
excepted: <input type='text' name='name' value='thevalue'
class='miclass'/>

In documentation, you can find that HtmlHelper->tags has an array with
preformatted tags (wich uses sprintf). That functionality doesn't
works.

i have no time to explain, but i think that addition can fix the
problem:

if ($text === null) {
        $tag = 'tagstart';
}elseif( array_key_exists($name, $this->tags) ){
        $tag = $name;
} else {
        $tag = 'tag';
}

Thans to all, and excuse my bad english, i'm spanish.

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to