My personal opinion is that this doesn't seem like a useful feature - first, because I've never seen such a thing on a web date input; and second, because the SF date input already presets the current month and year, so (unless you're on the 1st of the month) it just saves you the trouble of writing the day. If anyone disagrees, feel free to chime in.

Having to maintain a patch for an extension is not good, though, so, if you want to keep this functionality even if it doesn't get added to SF, I would suggest creating a new mini-extension that defines this as a new form input, using SF's hook to add it to the system.


On Wed, Jul 22, 2009 at 5:47 AM, Patrick Nagel <> wrote:

I brought this up before on the old Semantic Forms list [1]. At the time I
thought it was a viable solution to put my own custom made buttons into the
forms where I need them, and I used the HTMLets extension for that.

The problem with this solution is, that it's quite unmaintainable. I have to
specify the ID numbers of the HTML input elements, and as soon as I change the
form, those change, and have to be adjusted in the files that get included via
the HTMLets extension. So I thought it would be much better to have that
functionality directly in Semantic Forms (where the ID numbers are known).

Today I got around adding this to Semantic Forms, the patch against a recent
SVN checkout is attached. It adds a button titled "Today" and a button titled
"Yesterday" next to each date input. In our SMW/SF application it is desirable
to have this for all date input fields, but I guess in others, where the dates
are historical ones, or otherwise never "today" or "yesterday", they would be
useless. So this should probably be configurable, or maybe there should be two
new input types, 'date_buttons' and 'datetime_buttons', or something like that.

Or is this feature so useless to anyone else, that it should not be included in
Semantic Forms? Yaron, what do you think?



Key ID: 0x86E346D4  
Fingerprint: 7745 E1BE FA8B FBAD 76AB 2BFC C981 E686 86E3 46D4


Semediawiki-devel mailing list