[pmwiki-users] Changes to markup
Peter Bowers
pbowers at pobox.com
Fri Jun 8 07:51:44 CDT 2012
On Mon, Jun 4, 2012 at 7:40 PM, Ryan Varick <rvarick at gmail.com> wrote:
> 1. Is there a way to add HTML5 attributes to form elements
> (http://www.pmwiki.org/wiki/PmWiki/Forms)? I want to use things like
> autocomplete and email/number input types to make data entry easier on
> mobile devices.
>From scripts/forms.php:
===(snip)===
SDV($InputAttrs, array('name', 'value', 'id', 'class', 'rows', 'cols',
'size', 'maxlength', 'action', 'method', 'accesskey', 'tabindex', 'multiple',
'checked', 'disabled', 'readonly', 'enctype', 'src', 'alt'));
===(snip)===
I've never messed around with HTML5 forms, but (assuming that they are
just additional attributes) I *think* you can just create a more
complete list for $InputAttrs and then you would be able to specify
those attributes.
Of course be aware of whatever security ramifications may come with
allowing these attributes...
If you're successful please document it on pmwiki.org as a new recipe
so others can take advantage of it...
-Peter
More information about the pmwiki-users
mailing list