MyBB Community Forums

Full Version: generate_text_area ignores cols attribute
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Can anyone else get generate_text_area to read the cols attribute?

If I do

$content_options = array(
			"id" => "1",
			"cols" => 100,
			"rows" => 30

content_box = $form->generate_text_area('main_content', $result["main_content"], $content_options);
		$form_container->output_row('Content', "", $content_box, 'content');

Then the columns are still stuck at about 50. No matter what value I try this does not work, however the rows attribute is being read.


EXTRA INFO: It is printing it out to the page with the cols attribute but still wont print it out. Is there some JS restriction in the admin panel?

SOLVED: this was caused by the default CSS for the textarea in admin/styles/main.css being set to 400px

I fed a style with width: 800px and all worked how I expected.