User tests: Successful: Unsuccessful:
Status | New | ⇒ | Pending |
Labels |
Added:
?
|
Category | ⇒ | Modules Multilanguage |
I have tested this item successfully on d8bdf8b
Successful test - just wondering if it should use the flags
@infograf768 just want to ask a question. Why does Joomla uses chosen
instead of select2
.
i think select2 does everything chosen does and, among many other improvements, allows to add image (flags), It would be perfect for this case (also other select boxes that uses languages).
More info https://select2.github.io/examples.html#templating
I have tested this item successfully on d8bdf8b
works as described.
Status | Pending | ⇒ | Ready to Commit |
Labels |
Added:
?
|
Milestone |
Added: |
just want to ask a question. Why does Joomla uses chosen instead of select2.
Don't ask me...
Select2 is MIT license, so I guess we could use it indeed. It would have to ship with core. Not sure this can be done in the 3.x series.
There are ways to include images in dropdown btw, see my patch using chosen.
#9095
The problem in this menuitem field is the use of JHtml::_('select.option', etc.
I could not find a way to tweek it to get images.
I can get the right image fine with
// Create a new query object.
if ($link->language !== '*')
{
$db = JFactory::getDbo();
$query = $db->getQuery(true)
->select($db->quoteName('image'))
->where($db->quoteName('lang_code') . '=' . $db->quote($link->language))
->from($db->quoteName('#__languages'));
$db->setQuery($query);
$image = $db->loadResult();
}
Then I tried using:
$lang = '<span>' . JHtml::_('image', 'mod_languages/' . $image . '.gif', $link->language, array('title' => $image), true). '</span>';
but it would not show using
$groups[$menu->menutype][] = JHtml::_('select.option',
$link->value, $levelPrefix . $link->text . $lang,
'value',
'text',
in_array($link->type, $this->disable)
);
Maybe you have an idea?
If not, let's make this RTC as it is better than nothing.
IMO this stays RTC. But we should investigate the flags in the select boxes question further for future.
It would be a nice usability improvement.
I set it RTC while you were typing ;)
On 5 April 2016 at 11:08, andrepereiradasilva notifications@github.com
wrote:
IMO this stays RTC. But we should investigate the flags in the select
boxes question further for future.
It would be a nice usability improvement.—
You are receiving this because you commented.
Reply to this email directly or view it on GitHub
#9735 (comment)
Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/
at 97 pending RTC
As soon as 351 is released they will be merged ;)
BTW, I am now preparing a similar PR for the category
field.
Category | Modules Multilanguage | ⇒ | Multilanguage |
@Devportobello
One can start creating content languages and assigning languages to items (including menu items) before even enabling the language filter plugin.
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2016-04-12 20:25:57 |
Closed_By | ⇒ | rdeutz |
Labels |
Removed:
?
|
Milestone |
Removed: |
Milestone |
Added: |
Milestone |
Added: |
Milestone |
Removed: |
I have tested this item successfully on d8bdf8b
This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/9735.