[jira] [Commented] (WW-4150) Support attributes with hyphens in tag dynamic attributes
[ https://issues.apache.org/jira/browse/WW-4150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14059779#comment-14059779 ] Jasper Rosenberg commented on WW-4150: -- Yes, that looks good. Support attributes with hyphens in tag dynamic attributes - Key: WW-4150 URL: https://issues.apache.org/jira/browse/WW-4150 Project: Struts 2 Issue Type: Improvement Components: Other Affects Versions: 2.3.15.1 Reporter: Jasper Rosenberg Priority: Minor Fix For: 2.3.18 A lot of CSS/JS frameworks look for attributes on html elements that include a hyphen to do their magic (JQuery Mobile, Bootstrap, etc). For example, in my JQuery Mobile app, I'd like to be able to say: {code} @s.form ... data-ajax=false /@s.form {code} Unfortunately, this doesn't work because Freemarker doesn't allow hyphens in macro parameter names. I entered an enhancement request for this here: https://sourceforge.net/p/freemarker/bugs/395/ I'm not sure when or if that might be fixed, so perhaps a work around would be to allow explicit dynamic attributes through some kind of parameter convention. {code} @s.form ... @s.param name=dyn:data-ajax value=false/ /@s.form {code} -- This message was sent by Atlassian JIRA (v6.2#6252)
[jira] [Commented] (WW-4150) Support attributes with hyphens in tag dynamic attributes
[ https://issues.apache.org/jira/browse/WW-4150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14059277#comment-14059277 ] Lukasz Lenart commented on WW-4150: --- Is that ok? https://cwiki.apache.org/confluence/display/WW/Freemarker+Support#FreemarkerSupport-Dynamicattributessupport Support attributes with hyphens in tag dynamic attributes - Key: WW-4150 URL: https://issues.apache.org/jira/browse/WW-4150 Project: Struts 2 Issue Type: Improvement Components: Other Affects Versions: 2.3.15.1 Reporter: Jasper Rosenberg Priority: Minor Fix For: 2.3.18 A lot of CSS/JS frameworks look for attributes on html elements that include a hyphen to do their magic (JQuery Mobile, Bootstrap, etc). For example, in my JQuery Mobile app, I'd like to be able to say: {code} @s.form ... data-ajax=false /@s.form {code} Unfortunately, this doesn't work because Freemarker doesn't allow hyphens in macro parameter names. I entered an enhancement request for this here: https://sourceforge.net/p/freemarker/bugs/395/ I'm not sure when or if that might be fixed, so perhaps a work around would be to allow explicit dynamic attributes through some kind of parameter convention. {code} @s.form ... @s.param name=dyn:data-ajax value=false/ /@s.form {code} -- This message was sent by Atlassian JIRA (v6.2#6252)
[jira] [Commented] (WW-4150) Support attributes with hyphens in tag dynamic attributes
[ https://issues.apache.org/jira/browse/WW-4150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13724284#comment-13724284 ] Jasper Rosenberg commented on WW-4150: -- FYI, you need to leave off the quotes to have it work: {code} @s.form dynamicAttributes={'data-ajax':'false'} ... /@s.form {code} (You can also leave the single quotes from false if you want) Support attributes with hyphens in tag dynamic attributes - Key: WW-4150 URL: https://issues.apache.org/jira/browse/WW-4150 Project: Struts 2 Issue Type: Improvement Components: Other Affects Versions: 2.3.15.1 Reporter: Jasper Rosenberg Priority: Minor Fix For: 2.3.17 A lot of CSS/JS frameworks look for attributes on html elements that include a hyphen to do their magic (JQuery Mobile, Bootstrap, etc). For example, in my JQuery Mobile app, I'd like to be able to say: {code} @s.form ... data-ajax=false /@s.form {code} Unfortunately, this doesn't work because Freemarker doesn't allow hyphens in macro parameter names. I entered an enhancement request for this here: https://sourceforge.net/p/freemarker/bugs/395/ I'm not sure when or if that might be fixed, so perhaps a work around would be to allow explicit dynamic attributes through some kind of parameter convention. {code} @s.form ... @s.param name=dyn:data-ajax value=false/ /@s.form {code} -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WW-4150) Support attributes with hyphens in tag dynamic attributes
[ https://issues.apache.org/jira/browse/WW-4150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13724655#comment-13724655 ] zhouyanming commented on WW-4150: - thanks,patch of dynamic attributes for freemarker template was submitted by me. Support attributes with hyphens in tag dynamic attributes - Key: WW-4150 URL: https://issues.apache.org/jira/browse/WW-4150 Project: Struts 2 Issue Type: Improvement Components: Other Affects Versions: 2.3.15.1 Reporter: Jasper Rosenberg Priority: Minor Fix For: 2.3.17 A lot of CSS/JS frameworks look for attributes on html elements that include a hyphen to do their magic (JQuery Mobile, Bootstrap, etc). For example, in my JQuery Mobile app, I'd like to be able to say: {code} @s.form ... data-ajax=false /@s.form {code} Unfortunately, this doesn't work because Freemarker doesn't allow hyphens in macro parameter names. I entered an enhancement request for this here: https://sourceforge.net/p/freemarker/bugs/395/ I'm not sure when or if that might be fixed, so perhaps a work around would be to allow explicit dynamic attributes through some kind of parameter convention. {code} @s.form ... @s.param name=dyn:data-ajax value=false/ /@s.form {code} -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WW-4150) Support attributes with hyphens in tag dynamic attributes
[ https://issues.apache.org/jira/browse/WW-4150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13717806#comment-13717806 ] zhouyanming commented on WW-4150: - workaround @s.form dynamicAttributes={'data-ajax':'false'} ... /@s.form Support attributes with hyphens in tag dynamic attributes - Key: WW-4150 URL: https://issues.apache.org/jira/browse/WW-4150 Project: Struts 2 Issue Type: Improvement Components: Other Affects Versions: 2.3.15.1 Reporter: Jasper Rosenberg Priority: Minor Fix For: 2.3.17 A lot of CSS/JS frameworks look for attributes on html elements that include a hyphen to do their magic (JQuery Mobile, Bootstrap, etc). For example, in my JQuery Mobile app, I'd like to be able to say: {code} @s.form ... data-ajax=false /@s.form {code} Unfortunately, this doesn't work because Freemarker doesn't allow hyphens in macro parameter names. I entered an enhancement request for this here: https://sourceforge.net/p/freemarker/bugs/395/ I'm not sure when or if that might be fixed, so perhaps a work around would be to allow explicit dynamic attributes through some kind of parameter convention. {code} @s.form ... @s.param name=dyn:data-ajax value=false/ /@s.form {code} -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WW-4150) Support attributes with hyphens in tag dynamic attributes
[ https://issues.apache.org/jira/browse/WW-4150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13717861#comment-13717861 ] Jasper Rosenberg commented on WW-4150: -- Thanks [~quaff], that's a great tip. Should add that to the docs too... Support attributes with hyphens in tag dynamic attributes - Key: WW-4150 URL: https://issues.apache.org/jira/browse/WW-4150 Project: Struts 2 Issue Type: Improvement Components: Other Affects Versions: 2.3.15.1 Reporter: Jasper Rosenberg Priority: Minor Fix For: 2.3.17 A lot of CSS/JS frameworks look for attributes on html elements that include a hyphen to do their magic (JQuery Mobile, Bootstrap, etc). For example, in my JQuery Mobile app, I'd like to be able to say: {code} @s.form ... data-ajax=false /@s.form {code} Unfortunately, this doesn't work because Freemarker doesn't allow hyphens in macro parameter names. I entered an enhancement request for this here: https://sourceforge.net/p/freemarker/bugs/395/ I'm not sure when or if that might be fixed, so perhaps a work around would be to allow explicit dynamic attributes through some kind of parameter convention. {code} @s.form ... @s.param name=dyn:data-ajax value=false/ /@s.form {code} -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira