[TYPO3-dev] ExtJS date pickers and date ranges (working prototype maybe for Core?)
Stefano Cecere
scecere at krur.com
Mon Nov 15 11:51:57 CET 2010
ok i could make it work with this (the className is like this:
class="tceforms-textfield tceforms-datefield lower-100000- " )
if (element.dom.className.match(/lower/)) {
strmindate = element.dom.className.match(".+lower-(.+?)-.+");
minDate = new Date(strmindate[1] * 1000);
} else {
minDate = null;
}
if anybody has better solutions, welcome! :)
On Mon, 15 Nov 2010 10:37:22 +0100, Stefano Cecere <scecere at krur.com>
wrote:
> hi
>
> i have quite finished my patch for this feature, BUT i would need some
> help with RegExp (i'm not good with it!)
>
> to simply everything i pass the lower and upper date limits in the input
> classes, like
>
> class="tceforms-textfield tceforms-datefield lower-100000 upper-2000000"
>
> i can easily check the presence of those params within JS (with .. . if
> (element.dom.className.match(/upper/)) {
>
> QUESTION: qhat is the easiest way to get the parameter (100000 for
> example?)
> i'd like to extract the "lower-100000" token, and then split by '-'
>
> any help?
>
> thank you!
> stefano
--
____ ___ __ _ ______________________
Stefano Cecere
KRUR.com - humanmedia
More information about the TYPO3-dev
mailing list