Check out Balbo's Chess, our featured variant for October, 2024.


[ Help | Earliest Comments | Latest Comments ]
[ List All Subjects of Discussion | Create New Subject of Discussion ]
[ List Earliest Comments Only For Pages | Games | Rated Pages | Rated Games | Subjects of Discussion ]

Single Comment

Asylum Chess. 3 new unique pieces: fire-through rooks, double-capture knights, leaping bishops. (10x10, Cells: 100) [All Comments] [Add Comment or Rating]
🕸Fergus Duniho wrote on Fri, Nov 25, 2022 10:05 PM UTC in reply to H. G. Muller from 08:35 AM:

Since your own edits also broke the Game Courier forms, I figured it might not be my use of htmlspecialchars and htmlspecialchars_decode. I determined the problem to be that CkEditor was putting extra whitespace in front of each line, and this was affecting how it processed the variable passed in the TEXTAREA. So, I modified Game Courier to remove the whitespace from each line of this variable. Then I used htmlspecialchars on the appropriate variables before displaying them in editmsitem.php, and I used htmlspecialchars_decode on them before copying them to the database in editmsitem2.php.

But one problem remained. The Game Courier forms included lots of extra whitespace before each line of text in the TEXTAREA. To eliminate this, I wrote a function to trim whitespace off each line of text in a string, and I used this function on the data before sending it to the database in editmsitem2.php. This will have the extra advantage of saving space in the database. However, this will make difficulty for PRE text, but I figure PRE text is no longer as useful as it once was, since most people don't use text-based browsers like Lynx, and because CkEditor reformats text, it makes using PRE text difficult anyway.

Unless people believe there is a need to still accommodate PRE text, I'll start making these same changes to other scripts for editing page content.