Designer changes field type Text --> Textarea

stycer 12 Feb, 2014
Hi all,
I have a strange behaviour of the Designer in CF V5.
I try to add TEXT fields with only 1 row Input (as I have done it several times before in the same form), but since yesterday the field type changes after editing the label.
After changing the field type is an TEXTAREA with height > 1 row.
Even putting 1 in the parameter list via Custom Code, the Text area remains with a height >1 row.

Any ideas, what is happening here?

My form includes so far:
6 text fields, among them an email style
2 checkboxes
2 radio buttons
and additional 4 text areas (which I would like to be text fiels with a height of 1 row...)

Best regards,
Stycer
GreyHead 12 Feb, 2014
Hi stycer,

I cant' replicate this, and, off the top of my head, I find it hard to work out how it would happen. By all means email or PM me the site URL, the form name, and a SuperAdmin login and I'll take a quick look.

Bob
stycer 12 Feb, 2014
Done by PM - any results so far? :-)
GreyHead 12 Feb, 2014
Hi Stycer,

Yes, I see the same as you do, I took a back-up copy and restored it on my test site and get the same result there. I wondered if there is some code in the form that is breaking it but I don't see anything (I did try removing the dashes '-' from the input names to no effect.

Please Contact Max using the Contact Us link above and link to this thread. This is one for him.

Bob
Max_admin 12 Feb, 2014
Answer
Hi,

This is a weird issue, but I found a fix:

At this file: /administrator/components/com_chronoforms5/chronoforms/chronoforms.php

At the end of the "edit" function, please add the following code:

foreach($this->data['Form']['extras']['fields'] as $f_k => $f_info){
			if(strpos($f_k, '{N}') !== false){
				unset($this->data['Form']['extras']['fields'][$f_k]);
			}
		}


Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
stycer 13 Feb, 2014
Yes , it works.
I am not a php coder - but I tried to put it right after
$this->set('chronoforms_settings', new \GCore\Libs\Parameter($this->data['Chronoforms']));

before the closing brace of edit function.
And it worked :-)

Thanks a lot to both of you!

I do not see the answered button,
but Its all OK :-)

Greets,
stycer
This topic is locked and no more replies can be posted.