radio/select-fields & pre selecting

More
13 years 2 months ago #31281 by weCombine
hi there,

is it possible to create a radio/select field and "pre-select" one of the values?

we can "fake" it with a select-field, deactivating "use first field", so the first value will be pre-selected.
but... we need to preselect a value in the middle.

we use flexicontent 2.0.0 RC9a r1551 & joomla 2.5.8.

tnx for feedback,
afberlin

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #31289 by ggppdk
This is currently not available, try this:


1. Set a default value into the field "Default value" parameter

2. change in select.php:

lines:
Code:
// initialise property if($item->version < 2 && $default_value) {

to:
Code:
// initialise property if( !isset($field->value[0]) && $default_value) {

This will preselect default value if a value is not set


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #31293 by weCombine
ok, thanks for this fast feedback & workaround.

will this be a feature for later?

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #31296 by ggppdk
Hello, did you test it?


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #31302 by weCombine
yes, i did a quick test and it works perfect

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #31303 by ggppdk
I guess what happened is that you added a new select field in existing items , right?

and default value by default was used (selected) only for new items , right?


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #31317 by weCombine
indeed, we added the select field in for existing items and the default value is only used for the new items.

i guess, here is no workaround (except going into phpmyadmin)

Please Log in or Create an account to join the conversation.

More
13 years 2 months ago #31319 by ggppdk
Actually for text field there is a parameter

"Default usage"

in which you can define that value is to be used instead of empty (when the field's display is created)

i guess this parameter could be added to select field too, but currently it is not available


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Save