repeatable form field problem...

瀏覽次數:65 次
跳到第一則未讀訊息

Troy Hall

未讀,
2016年5月2日 晚上10:36:522016/5/2
收件者:joomla-dev-general
I've got a repeatable form field with default values for each param.  When its initially called it shows the string but when that exact string is run through json_decode it returns null.  What is it that I'm doing wrong?
Here is the default I'm setting ..
default="{'Elements':['body','h1','h2','h3','h4','h5','h6','p','a','i','ol','ul','li','span.company-name','span.company-slogan'],'Function':['Body','h1','h2','h3','h4','h5','h6','Paragraph','links','i','Ordered lists','Unordered Lists','List Element','Company Name','Company Moniker'],'Size':['','','','','','','','','','','','','','',''],'Weight':['','','','','','','','','','','','','','',''],'Style':['','','','','','','','','','','','','','',''],'Color':['','','','','','','','','','','','','','',''],'hoverColor':['','','','','','','','','','','','','','',''],'linkColor':['','','','','','','','','','','','','','',''],'hoverlinkColor':['','','','','','','','','','','','','','','']}"
and the attached image show's the output.
I appreciate any advice.. I tried searching the docs but there isn't really anything that I could find showing how to get the code back out...
php says json must be in double quotes not singles.  But changing it to ..
default='{"Elements":["body","h1","h2","h3","h4","h5","h6","p","a","i","ol","ul","li","span.company-name","span.company-slogan"],"Function":["Body","h1","h2","h3","h4","h5","h6","Paragraph","links","i","Ordered lists","Unordered Lists","List Element","Company Name","Company Moniker"],"Size":["","","","","","","","","","","","","","",""],"Weight":["","","","","","","","","","","","","","",""],"Style":["","","","","","","","","","","","","","",""],"Color":["","","","","","","","","","","","","","",""],"hoverColor":["","","","","","","","","","","","","","",""],"linkColor":["","","","","","","","","","","","","","",""],"hoverlinkColor":["","","","","","","","","","","","","","",""]}'
doesn't solve the problem either...
Bear


Walt Sorensen

未讀,
2016年5月4日 中午12:32:552016/5/4
收件者:Joomla! General Development
Generally speaking, I think most developers are not using Repeatable fields with Joomla right now.
Repeatable fields currently can not have JS. Essentially, it's a useless tool for anything but basic text fields (and even that is highly questionable). There has been some discussion in the mailing list about whether the documentation is correct and if the default values should have single or double quotes. 

Here is the reference issue about the field type being broken.

Troy Hall

未讀,
2016年5月4日 晚上8:22:512016/5/4
收件者:joomla-de...@googlegroups.com
thanks walter... sadly its exactly what I need :(
Bear
--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-gene...@googlegroups.com.
To post to this group, send email to joomla-de...@googlegroups.com.
Visit this group at https://groups.google.com/group/joomla-dev-general.
For more options, visit https://groups.google.com/d/optout.

Walt Sorensen

未讀,
2016年5月5日 上午11:45:252016/5/5
收件者:Joomla! General Development
For 3.7 (formerly 3.6) there is a new option for a New field Subform proposed that has an ability to be repeatable.

It needs volunteers to help test and write documentation so that it can be included in the release.
https://github.com/joomla/joomla-cms/pull/7829

brian teeman

未讀,
2016年5月5日 中午12:44:182016/5/5
收件者:Joomla! General Development


On Thursday, 5 May 2016 16:45:25 UTC+1, Walt Sorensen wrote:
For 3.7 (formerly 3.6) there is a new option for a New field Subform proposed that has an ability to be repeatable.


It can still go in 3.6 if it gets tested in time

Walt Sorensen

未讀,
2016年5月5日 晚上9:01:062016/5/5
收件者:Joomla! General Development
Brian, I thought the 3.5.2→3.6.0 change was restricted such that "The features that originally were planned to ship with 3.6 (for example the refactored routing system and the custom fields component) will now be made in a 3.7 release."
and the new 3.6.0 would be to just "release the improvements to the Joomla Update Component, containing a reinstall button and reinstating the ability to update Joomla via file upload, as soon as possible."

Are we really going to be able to get other features into the new 3.6.0? https://developer.joomla.org/news/644-version-number-shifting.html


brian teeman

未讀,
2016年5月6日 凌晨1:56:312016/5/6
收件者:Joomla! General Development
If they are ready then it is possible

Walt Sorensen aka photodude

未讀,
2016年5月11日 上午11:45:072016/5/11
收件者:Joomla! General Development
Glad to see the New field Subform is merged with the recent sprint. It's definitely a big advancement that's been long overdue.
回覆所有人
回覆作者
轉寄
0 則新訊息