[pmwiki-devel] Edit Form Attributes (width\height)
Michael Elliott
melliott42 at yahoo.com
Wed Feb 3 12:43:05 PST 2021
Thank you Petko.
On Wednesday, February 3, 2021, 2:27:41 AM EST, Petko Yotov <5ko at 5ko.fr> wrote:
On 02/02/2021 23:17, Michael Elliott wrote:
> In PMWiki where is the appropriate place to change\set the Edit
> TextArea Width (AKA cols) and height (AKA rows)?
> I saw some obsolete Cookbooks and also tried editing Site.EditForm
> page adding properties to (:input e_textarea :) without success.
Some skins use a separate edit form page, not Site.EditForm -- check the
skin documentation.
To set it by default for all users, add to config.php:
$XL['en']['e_cols'] = 90;
$XL['en']['e_rows'] = 12;
If you're loading a different language via XLPage(), change the key 'en'
with the key for your language e.g. 'fr' for French. If you're using
multiple languages, add them as new lines.
Independently of the above, you and other users can set their own
preferences for this, see the pages:
https://www.pmwiki.org/wiki/PmWiki/SitePreferences
https://www.pmwiki.org/wiki/Site/Preferences
They need to create on your own wiki a page Group.MyPrefs with the
settings and follow a link like ?setprefs=Group.MyPrefs. Then their
preferences page is remembered in a cookie and will be parsed to get the
numbers when they edit a page.
Also note that some skins may use a different edit form, and/or set the
textarea width and height via CSS (which overrides the cols and rows
attributes). The PmWiki-responsive skin for example sets the textarea
width. In that case, you can set the width and height in the file
pub/css/local.css (which normally overrides the skin's CSS file):
#wikiedit textarea {
width: 99.5%;
max-width: 99.5%;
max-height: 60vh;
}
If it is a core skin, or one from the cookbook, this allows you to keep
the original skin and is easier to update the skin to a new version
without losing your customization.
(The selector "#wikiedit textarea" should be standard for most skins but
some skins may use their own CSS classes and identifiers. If you have
difficulties, ask the maintainer of the skin -- or here on the mailing
list.)
Petko
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pmichaud.com/pipermail/pmwiki-devel/attachments/20210203/03c3c28b/attachment.html>
More information about the pmwiki-devel
mailing list