How about: $.meta.cre = /((?!\[)(.*)(?=\]))/;
This will fail if you use class="foo [required: true]" but should be fine with class="[required: true] foo" For it to work like it does with {} (class names before and after are ignored), the meta data plugin would probably be have to be modified. On Aug 28, 1:25 pm, "Olivier Percebois-Garve" <[EMAIL PROTECTED]> wrote: > Thanks for your answers. > > Emil you are right at saying that it is not a jquery issue. > Its even more a formsess issue than a smarty issue, and thats why your > solution > wont work.Because of the formsess filters it produces something like: > > ##FS_SMARTY_LDELIM##ldelim##FS_SMARTY_RDELIM##required: > true##FS_SMARTY_LDELIM##rdelim##FS_SMARTY_RDELIM## > > So I'm looking more for a jquery solution. > Sam your solution goes in the direction I'm looking for, but it > produces an error: > > I tried with class="[required: true]" > and added $.meta.cre = /(\[.*\])/; in the jQuery(document).ready( > > Firebug says : invalid property id > > https://xxx.nondisclosabledomainname.com/subscription_new/js/jquery.m... > Line 98 > > in green: data = {[required: true]} > > -Olivier > > On 8/28/07, Sam Collett <[EMAIL PROTECTED]> wrote: > > > > > You could try adding this in $(document).ready, before calling the > > validate plugin: > > > $.meta.cre = /(\[.*\])/; > > $("#foo").validate(); > > > Although that is not documented in the meta data plugin (maybe there > > should be an option in it to do that). > > > On Aug 28, 9:05 am, "Olivier Percebois-Garve" <[EMAIL PROTECTED]> > > wrote: > > > Hi > > > > I'm having an issue with the validation plugin. It conflicts with a > > > smarty-based php class named formsess. > > > It does not allow signs such as "{" in form tags. > > > Sounds like hell to go modify formsess, so I hope to find a way to > > change > > > that in the validation plugin. > > > Could it be possible to replace class="{required: true}" with > > > class="[required: true]" ? > > > > thanks > > > > -Olivier