COMMUNITY FORUM
- Forum
- K2 Community Forum
- English K2 Community
- k2fields - providing you additional extra fields and extended select
k2fields - providing you additional extra fields and extended select
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
In your above example each row corresponds to one k2fields. So what you should do is paste each of those row in the Name field of an extra field of the type Text Field. So breaking it down as follows and also aided by the attached picture visualizing whats written below:
Example 1. if you create a Text Field with the name containing the following k2fields syntax:
k2f---valid=datetime:::low=+0:::high=+3:::required=true---Datum
it would give you one editable datetime k2fields with current year as least available and current year + 3 years forward as maximum available and where the field name is Datum
Example 2. If you again create another extra field of the type Text Field and paste the following in the name of the field
k2f---block=true:::valid=number:::interval=[200,10000]:::list=conditional:::listmax=5---Text test
it would give you a number field (with the name "Text test") which allows entry of values between 200 and 10000. Having list enabled on this field (list=conditional) user would be able to add 5 varying values (listmax=5). Besides since the is conditional (list=conditional) user would be able to give conditions for each value as well. Since block=true k2fields checks if given values for this particluar field are of valid type and if not it will not allow submission of the item form.
Example 3. In case of this third example, lets skip it for a while as it have to do with extending the stock K2 select list so that user can add values
Example 4. k2f---valid=number:::interval=[200,10000]:::list=conditional:::listmax=5:::conditions=Daily%%Weekly%%Monthly%
%Yearly---Rent
If you again create a new K2 extra field with the type Text Field with the above k2fields syntax in the name field you would get a field which allows values between 200 and 10000. As example 2 above the user is allowed to enter 5 different values and this time the field have fixed conditions, with drop down and the values avialable for selection are those given in conditions=Daily%%Weekly%%Monthly%%Yearly. Each condition separated by "%%", thus Daily, Weekly, Monthly and Yearly being those available as conditions
In the attached picture you will be able to see how it all works out
Good luck and let me know if you have any further ideas or questions
Please Log in or Create an account to join the conversation.
- FeSys
-
- Offline
- Elite Member
- Posts: 262
it shows only the code.
..You may help!
Gobezu Sewu said:@Followeyes here comes some more detailed examples In your above example each row corresponds to one k2fields. So what you should do is paste each of those row in the Name field of an extra field of the type Text Field. So breaking it down as follows and also aided by the attached picture visualizing whats written below:
Example 1. if you create a Text Field with the name containing the following k2fields syntax:
k2f---valid=datetime:::low=+0:::high=+3:::required=true---Datum
it would give you one editable datetime k2fields with current year as least available and current year + 3 years forward as maximum available and where the field name is Datum
Example 2. If you again create another extra field of the type Text Field and paste the following in the name of the field
k2f---block=true:::valid=number:::interval=[200,10000]:::list=conditional:::listmax=5---Text test
it would give you a number field (with the name "Text test") which allows entry of values between 200 and 10000. Having list enabled on this field (list=conditional) user would be able to add 5 varying values (listmax=5). Besides since the is conditional (list=conditional) user would be able to give conditions for each value as well. Since block=true k2fields checks if given values for this particluar field are of valid type and if not it will not allow submission of the item form.
Example 3. In case of this third example, lets skip it for a while as it have to do with extending the stock K2 select list so that user can add values
Example 4. k2f---valid=number:::interval=[200,10000]:::list=conditional:::listmax=5:::conditions=Daily%%Weekly%%Monthly%
%Yearly---Rent
If you again create a new K2 extra field with the type Text Field with the above k2fields syntax in the name field you would get a field which allows values between 200 and 10000. As example 2 above the user is allowed to enter 5 different values and this time the field have fixed conditions, with drop down and the values avialable for selection are those given in conditions=Daily%%Weekly%%Monthly%%Yearly. Each condition separated by "%%", thus Daily, Weekly, Monthly and Yearly being those available as conditions
In the attached picture you will be able to see how it all works out
Good luck and let me know if you have any further ideas or questions
Please Log in or Create an account to join the conversation.
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
Please Log in or Create an account to join the conversation.
- FeSys
-
- Offline
- Elite Member
- Posts: 262
Gobezu Sewu said:@Followeyes may I start by asking, is the k2fields plugin you installed enabled?
Please Log in or Create an account to join the conversation.
- Tamas Darvas
-
- Offline
- New Member
- Posts: 10
Gobezu Sewu said:fellow k2ists, thanks for the feedback, a maintenance update with the above issues addressed is uploaded
Please Log in or Create an account to join the conversation.
- Tamas Darvas
-
- Offline
- New Member
- Posts: 10
Please Log in or Create an account to join the conversation.
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
@Tamas I sincerely hope its not b/c of me ;), I am as well looking at jSeblod, but not as replacement of K2 b/c they all have their place and I will definitely continue to use K2 in contexts that doesn't require the so called "extra fields" within K2, good luck
Please Log in or Create an account to join the conversation.
- FeSys
-
- Offline
- Elite Member
- Posts: 262
Just wondering..
I installed the core K2 one by Fotis.
Where can i see the K2 plug-ins been installed & enabled, including yours?
Maybe then I will figure my mistake anywhere.
Gobezu Sewu said:@Followeyes is there anyway I can access your setup and look at the issue?
@Tamas I sincerely hope its not b/c of me ;), I am as well looking at jSeblod, but not as replacement of K2 b/c they all have their place and I will definitely continue to use K2 in contexts that doesn't require the so called "extra fields" within K2, good luck
Please Log in or Create an account to join the conversation.
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
Btw, I didn't understand your reference to Fotis plugin?
Followeyes said:Sorry "Gobezu Sewu", it's a local setup for now. Just wondering.. I installed the core K2 one by Fotis. Where can i see the K2 plug-ins been installed & enabled, including yours?
Maybe then I will figure my mistake anywhere.
Gobezu Sewu said:@Followeyes is there anyway I can access your setup and look at the issue? @Tamas I sincerely hope its not b/c of me ;), I am as well looking at jSeblod, but not as replacement of K2 b/c they all have their place and I will definitely continue to use K2 in contexts that doesn't require the so called "extra fields" within K2, good luck
Please Log in or Create an account to join the conversation.
- FeSys
-
- Offline
- Elite Member
- Posts: 262
Gobezu Sewu said:
Btw, I didn't understand your reference to Fotis plugin?
I mean there is a plug-in by JoomlaWorks team (shown by Fotis) which too i installed, enabled and didn't konw where located in my K2 admin area.
Thanks for replay.
Gobezu Sewu said:@Followeyes ok, as I said on the download site, this was meant to be part of a larger project but have abandoned K2 for that specific project thus have not implemented it on any live site. It looks like I would need to setup a demo site. Will post here as soon as its done!
Btw, I didn't understand your reference to Fotis plugin?
Followeyes said:Sorry "Gobezu Sewu", it's a local setup for now. Just wondering.. I installed the core K2 one by Fotis. Where can i see the K2 plug-ins been installed & enabled, including yours? Maybe then I will figure my mistake anywhere.
Gobezu Sewu said:@Followeyes is there anyway I can access your setup and look at the issue? @Tamas I sincerely hope its not b/c of me ;), I am as well looking at jSeblod, but not as replacement of K2 b/c they all have their place and I will definitely continue to use K2 in contexts that doesn't require the so called "extra fields" within K2, good luck
Please Log in or Create an account to join the conversation.
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
I have also added a front end demo
So do head over to the site and have a look
Please Log in or Create an account to join the conversation.
- FeSys
-
- Offline
- Elite Member
- Posts: 262
Gobezu Sewu said:I have found the issues @Followeyes and other users have commented on and have now released an upgrade version with the issues addressed as well as added a support for the excellent Googlemaps plugin
I have also added a front end demo
So do head over to the site and have a look
Please Log in or Create an account to join the conversation.
- FeSys
-
- Offline
- Elite Member
- Posts: 262
Thank youuuuuuuuuuuuuuuuuuuuu ""Gobezu Sewu"".
Please Log in or Create an account to join the conversation.
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
Best!
Please Log in or Create an account to join the conversation.
- Line Wied
-
- Offline
- New Member
- Posts: 3
Im using it for a date extra field. Works fine in item view and in category lists, but when items are displayed by tag, it shows the "k2f---valid=datetime---Dato" instead of the name.
Please Log in or Create an account to join the conversation.
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
Great to hear that it is been useful.
Thanks for letting me know about this issue and I had never used the tag view. Now that I have looked into it you are indeed correct.
But unfortunately whenever the task is tag K2 doesn't seem to load the k2 plugins (which k2fields is) nor call necessary events (which this plugin requires in order to function properly and w/o having K2 core hacks in play). So atm there is not much we can do.
If you wouldn't mind putting a K2 core hack in place I would be able to provide you such modification or if you would like to do it yourself open components/com_k2/models/item.php and look at row # 332 and change one of the clauses currently looking as follows:
($view=='itemlist' && ($task=='' || $task=='category') && $item->params->get('catItemK2Plugins')) ||
to
($view=='itemlist' && ($task=='' || $task=='category' || $task=='tag') && $item->params->get('catItemK2Plugins')) ||
Let me know how this works out for you...
Line Wied said:Thank you very much for this plugin.
Im using it for a date extra field. Works fine in item view and in category lists, but when items are displayed by tag, it shows the "k2f---valid=datetime---Dato" instead of the name.
Please Log in or Create an account to join the conversation.
- scyllar
-
- Offline
- Senior Member
- Posts: 60
Please Log in or Create an account to join the conversation.
- Line Wied
-
- Offline
- New Member
- Posts: 3
Thanks again,
Line
Please Log in or Create an account to join the conversation.
- Gobezu Sewu
-
Topic Author
- Offline
- Senior Member
Just checked your examples and works fine for me.
May I ask, have you enabled the plugin.
What is the result you see when editing the item.
Would you mind posting a screen cap of the extra field tab when editing an item in a category to which you assigned the extra field group which contains those extra fields.
Thank you!
Toni said:hi,
k2f---valid=url---Link
and k2f---valid=email---Mail
don´t work -.-
Please Log in or Create an account to join the conversation.
- Markus Thiel
-
- Offline
- Premium Member
- Posts: 149
Please Log in or Create an account to join the conversation.
- Forum
- K2 Community Forum
- English K2 Community
- k2fields - providing you additional extra fields and extended select