Author Topic: Trouble editing templates containing <textarea>  (Read 3633 times)

0 Members and 1 Guest are viewing this topic.

Offline Chris

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.487
  • Did u ever stop to think and then forget to start?
    • View Profile
Trouble editing templates containing <textarea>
« on: June 15, 2002, 10:11:55 PM »
This problem exists in 1.5 final.  I think I verified this correctly with a clean, unmodified, version of 4images and the default template set.

The following html template files contain the <textarea> tag and are affected:

comment_form.html
member_mailform.html
member_uploadform.html
member_uploadform.html
postcard_create.html

Here is a screen shot to show the problem:


As you can see, half the template is "cut off" from the edit box and I have two strange buttons.

Anyone else have this problem?

Offline Jan

  • Administrator
  • 4images Guru
  • *****
  • Posts: 5.024
    • View Profile
    • 4images - Image Gallery Management System
Trouble editing templates containing <textarea>
« Reply #1 on: June 16, 2002, 11:25:28 AM »
Hi,

change in "admin/templates.php" this line:

Code: [Select]
echo "<textarea name=\"content\" cols=\"60\" rows=\"30\" wrap=\"off\" class=\"template_textarea\">".$content."</textarea>";

to
Code: [Select]
echo "<textarea name=\"content\" cols=\"60\" rows=\"30\" wrap=\"off\" class=\"template_textarea\">".htmlspecialchars($content)."</textarea>";

Greets Jan
Your first three "must do" before you ask a question:
1. Forum rules
2. FAQ
3. Search

Offline Chris

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.487
  • Did u ever stop to think and then forget to start?
    • View Profile
That did it
« Reply #2 on: June 17, 2002, 03:32:57 AM »
Superb!  Many thanks Jan.  You always impress me with your ability to pinpoint these little problems and produce the appropriate fix.