Make WordPress Core

Opened 17 years ago

Closed 16 years ago

Last modified 16 years ago

#5374 closed defect (bug) (worksforme)

"Write page/post" > "code" textarea is to right

Reported by: cacycleworks's profile cacycleworks Owned by:
Milestone: Priority: normal
Severity: minor Version: 2.3.1
Component: General Keywords:
Focuses: Cc:

Description

This seems similar to Ticket #s 3684 and 3540 however it's not exactly like them.

On the "Write page/post" the "code" textarea is far to the right of the center working pane, so that a portion gets cut off. The box's left edge is perfectly aligned to the end of the "code" tool buttons. I thought it was a touch odd with the out-of-box install, but the problem made the page unusable when I applied a theme.

I'm certain my methodology goes against the WP coding style/ ethos, as I found a quick CSS <DIV> hack that changed the behavior in wp-includes/general-template.php ...

original source:

wp-includes/general-template.php
906   </script>
907   <?php
908
909   $the_editor = apply_filters('the_editor', "<div><textarea class='mceEditor' $rows cols='40' name='$id' tabindex='2' id='$id'>%s</textarea></div>\n");
910   $the_editor_content = apply_filters('the_editor_content', $content);
911
912   printf($the_editor, $the_editor_content);
913
914   ?>
915   <script type="text/javascript">

a workaround I used which fixed the symptom:

wp-includes/general-template.php
907   <div style="float:left; width:100%;">
908   <?php
909
910   $the_editor = apply_filters('the_editor', "<textarea class='mceEditor' $rows cols='40' name='$id' tabindex='2' id='$id'>%s</textarea>\n");
911   $the_editor_content = apply_filters('the_editor_content', $content);
912
913   printf($the_editor, $the_editor_content);
914
915   ?></div>

Note that I did try to change apply_filters('the_editor', "<div><textarea

to: apply_filters('the_editor', "<div style=\"float:left; width:100%;\" ><textarea

and: apply_filters('the_editor', "<div style='float:left; width:100%;' ><textarea

however these caused errors as print_r complained about the numbers of arguments passed. I did initially try only 'style='float:left' and that worked, but then the text area was only about 100px wide, so I wanted to add the width, too.

I figure someone familiar with the code and the CSS of this area may be able to incorporate the change or implement a more simple solution. :)

version: wordpress-2.3.1.tar.gz
OS: kubuntu gutsy 7.10 amd64
browser: FF
served by LAMP install on same machine.

Change History (2)

#1 @ninjaWR
16 years ago

  • Resolution set to worksforme
  • Status changed from new to closed

can't replicate with r9840, guessing it was fixed along the way

#2 @ninjaWR
16 years ago

  • Milestone 2.9 deleted
Note: See TracTickets for help on using tickets.