[TYPO3-project-formidable] CAPTCHA: HowTo Remove <br>-tags between Input and reload Image
Luc Muller
"l.muller[no]" at [spam]ameos.com
Tue Feb 24 18:08:20 CET 2009
Your idea is correct.
making the display in full CSS.
but I can't do :
> In Line 83 you have to add these lines, so that the function is the same
> (if $sCopy has a value the <br>-Tags are set, otherwise they aren't):
> if ($sCopy) {
> $sCopy = "<br/>".$sCopy."<br/>";
> }
as <br /> are going to be rendered in template mode.
see htmlbag=>copylabel
$aHtmlBag = array(
"__compiled" => $sLabel .$aCaptcha["img"].$aCaptcha["reload"]."<br
/>".$sCopy."<br />". $sInput,
"label" => $this->oForm->_getLLLabel($this->aElement["label"]),
"image"=>$aCaptcha["img"],
"reload"=>$aCaptcha["reload"],
"copylabel"=>$sCopy,
"input" => $sInput,
);
I think that __compiled, should not be used in template mode.
You'd better make your custom html structure and explode your captcha
element using the template engine.
basiccaly, if I used <br />
it's to have the possibily to write something like this in the template :
<p>{firstfield}</p>
<p>{secondfield}</p>
<p>{captcha}</p>
<p>{submit}</p>
as this html should remain w3c valid, it can only be with <br /> or
<span> or other inline tags in the compiled.
from this, the only tag I can add to have line break without using
specific css style is a <br />.
I Don't know if you got another idea for this ?
I'll appreciate any point of you :)
thanks a lot
Luc Muller =:0)
Hauke Hain a écrit :
> Hallo,
>
> Between the reload image and the input field are two <br>-Tags.
> These tags should be removed.
>
> function _render() in class.tx_rdtcaptcha.php: Line 85 has to be changed
> from
> "__compiled" => $sLabel .$aCaptcha["img"].$aCaptcha["reload"]."<br
> />".$sCopy."<br />". $sInput,
> to
> "__compiled" => $sLabel
> .$aCaptcha["img"].$aCaptcha["reload"].$sCopy.$sInput,
>
> In Line 83 you have to add these lines, so that the function is the same
> (if $sCopy has a value the <br>-Tags are set, otherwise they aren't):
> if ($sCopy) {
> $sCopy = "<br/>".$sCopy."<br/>";
> }
>
> The position of the input field may be adjusted with CSS.
>
> I would appreciate it, if this change would be made in the svn too, so I
> do not have to change this file after every update. At least this
> functionality should be implemented (only <br> Tags if needed). How it
> is realised doesn't matter.
>
> Sincerely,
> Hauke
More information about the TYPO3-project-formidable
mailing list