× This forum has been locked. Please submit new Feature Requests on GitHub: github.com/Jensen-Technologies/component-creator-issues/issues

item id in menu

7 года 9 мес. назад #1388 от Soteha Srl
Soteha Srl создал тему: item id in menu
It's possible to modify the xml generated in menu item in this :

<?xml version="1.0" encoding="utf-8"?>
<metadata>
<layout title="TITLE" option="View">
<message>
<![CDATA[DESC]]>
</message>
</layout>
<fields name="params">
<fieldset
name="basic"
label="LABEL">
<field
name="item_id"
query="SELECT null as id UNION SELECT `id` FROM #__mycomp_table ORDER BY `id`"
type="sql"
key_field="id"
value_field="id"
label="LABEL"
require="true"
description="JGLOBAL_SHOW_TITLE_DESC">
</field>
</fieldset>
</fields>
</metadata>

So we can create "hidden" menu voices and override the id creating custom link with the id..

Example:

index.php?option=mycom&view=myview&id=12&Itemid=123

without the Union select the componet will ignore the id=12 and use every time the id specified in the menu.

Пожалуйста Войти или Регистрация, чтобы присоединиться к беседе.

Время создания страницы: 0.131 секунд
Работает на Kunena форум

We use cookies so that you can place orders and we can provide a better service. You can control the use of cookies at the individual browser level. If you reject cookies, you may still use our website, but your ability to use some features or areas of our website may be limited.