8

When you are creating "static" pages with a single article menu item, the page will get its title from the menu item. At this point you have an option to override the page title, in the Menu Item settings -> Page Display. Actually the same applies, for every page of almost every front-end component, that you can create pages with their menu items. So, you ...


6

I believe you'll need to use SQL statements such as below. But be CAREFUL - BACKUP THE TABLE FIRST to be sure that you can restore it if there are more considerations than you've realized at this point. This could be combined into a single SQL statement, but for clarity of what you're doing, run each of them UPDATE xxx_menu SET params = REPLACE( ...


5

I won't give you code on how to create a such menu, but I will give you an idea that will allow you to create a similar end result. You can create a "Split-Menu", by using 2 menu modules. At the First Menu Module (main first-level module) you will set to show only up to level 1 menu-items, in the: Module settings -> Start Level & End Level At the ...


5

I'm assuming your using JQuery. If your using Mootools let me know, and I'll update this. Your AJAX call can look something like this: $.ajax({ url : urlToSend, contentType : "application/json; charset=utf-8", type : 'get', cache : false, success : function(data) { successFunction(...


4

You could use menu parameters. They are similar to the component parameters but can be set up different for each menu item. Menu parameters can be defined in your view's template XML file (e.g. /components/com_yourcomponent/views/yourview/tmpl/default.xml) Tutorial: https://docs.joomla.org/J3.x:Developing_a_MVC_Component/...


4

The External URL menu item also has an XML file (like all backend forms in Joomla). You can find it inside: administrator/components/com_menus/models/forms/item_url.xml So inside this file (or the corresponding override for it), you could add something like (within the <fields> </fields>: <fieldset name="custom" label="custom"> <...


3

If your template is not in the list of the non-compatible templates/frameworks of this extension, I would suggest you to go with the Regular Labs Advanced Template Manager. Advanced Template Manager is an extension that changes the way your Template manager works. With Joomla you can normally only assign template styles to certain menu items. ...


3

Try removing the blank spaces in fields name and fieldset name attributes <fields name="RouteSettings"> <fieldset name="RouteSettings"> <field name="route_id" type="sql" label="Select a route" description="Select a route previously created in the backend." query="SELECT id AS value, route_name AS route_id FROM #__cddir_routes ...


3

you need add a "request" fields group, something like: <fields name="request"> <fieldset name="request"> <field name="format" type="hidden" default="raw"/> <field name="task" type="hidden" default="start"/> </fieldset> </fields>


3

No, there isn't. The amount of articles is defined by multiple params. See ContentModelCategory line 189: $limit = $params->get('num_leading_articles') + $params->get('num_intro_articles') + $params->get('num_links');


2

Turns out menu items are processed with a Content Plugin as well, so this can add custom options using a specified XML form: // no direct access defined ( '_JEXEC' ) or die ( 'Restricted access' ); class plgContentMyPlugin extends JPlugin { function onContentPrepareForm($form, $data) { $option = JFactory::getApplication()->input->get('...


2

A view can have several layouts in the tmpl view directoy, and layouts can be overriden at template level.


2

You will handle most of this in your JavaScript. In Joomla!, set a custom CSS class on the menu item in question. This is done with the Link CSS Style option in the Link Type Options of your menu item. You can then listen for a click on that link by referencing the style you set in your JavaScript. Remember to use event.preventDefault(); to ensure your ...


2

Use the following: $menu =& JSite::getMenu(); $activeMenu = $menu->getActive(); $Itemid = $activeMenu->id; or $menu =& JSite::getMenu(); $activeMenu = $menu->getActive(); $Itemid = $activeMenu->query['Itemid']; To get your message being passed you need to retrieve it from the application input $...


2

After some testing, I was able to replicate the issue: **A form redirects to a view without a menu item or redirects to itself relatively to a url like this one: component/mycomponent/myview (It doesn't matter if the view has a menu item or not, this is just stupid Joomla routing.)** Therefore the following has to be done to prevent the error: 1) the ...


2

If you have your articles arranged in sub-categories they will be ordered by category first then by date. If this is the case, in your menu item set Category order: No ordering, Article Order: Oldest first.


2

You can get the current menu item alias like so: $alias = JFactory::getApplication()->getMenu()->getActive()->alias; Update: $active = JFactory::getApplication()->getMenu()->getActive(); var_dump($active); or //(int)$id - the actual itemid you want to get; $specificMenuItem = JFactory::getApplication()->getMenu()->getItem($id); ...


1

I don't think you should be trying to set the parameter through the JApplication object, but instead via the component helper, like so: $menuParams = JComponentHelper::getParams('com_menus'); $menuParams->set('pageclass_sfx', $pageClass);


1

Just in case it helps anyone, this is how I achieved it: $menu = $app->getMenu(); $active_item = $menu->getActive(); $loader = function ($menu_type) { $db = \JFactory::getDbo(); $result = null; $query = $db->getQuery(true) ->select('m.id, m.menutype, m.title, m.description') ->where("m.menutype = '{$menu_type}'") ...


1

There's a few ways you could do this. Here are two options: Option 1: Using a category blog. If we use the news example, do you require the parent category to be a list view (which uses a different template, and listing each article in it's view), with a separate layout view for each article? To customise the default layout for a category blog in Joomla, ...


1

Addendum: OP wants the menu item params accessible in the view, but he tries to override the component params var ($this->params) with the menu item params object/class. Which is unnecessary complicated. In the core article component, the component and the menu item params are merged (in the view.html.php), which is cool if you are trying to override some ...


1

You are getting $params from $state $state = $this->get('State'); This means the state must have $params populated in your model. Check if you are populating the $state with $params in your model's populateState function protected function populateState($ordering = null, $direction = null) { $params = JComponentHelper::getParams('com_mycomponent');...


1

It looks like you are trying to get the menu parameters for your current active menu. Try the following code, this hasn't been tested, I am giving you this reference from memory. $app = JFactory::getApplication(); $params = $app->getMenu()->getActive()->getParams(); That may work for the current active menu parameters. If not you may have to pass ...


1

I solved the problem by using (2) - Params Method . I was taking the Please select option value to be 0 in default.xml. The solution was to set it null as follows and it is worked: <fields name="params"> <fieldset name="advanced"> <field name="gid" type="sql" label="FIELDLABEL" description="FIELDDESC" query="SELECT * FROM #...


1

For anyone else who runs into this problem: Technically FFrewin's response was what I was looking for, but it was not the solution to the problem. You can't override those xml files like you can for most other components. I ended up using the plugin that was suggested and it works perfectly for me. http://extensions.joomla.org/extensions/extension/...


1

I had the same issue. Found an answer here: https://stackoverflow.com/questions/24417351/joomla-3-3-1-cant-edit-and-create-new-menus-in-menu-manager It seems after all, that the solution is just clearing your browser's cache.


1

To get Menu Params This one is perfect I was searching few hrs and this solve my issue of Joomla 3.6.5 & PHP 7.1 0: Using $this when not in object context Solution: $app = JFactory::getApplication(); $menu = $app->getMenu(); $active = $menu->getActive(); $itemId = $active->id; $menuparams = $menu->getParams($itemId);


1

If you run this controller file directly you can't get the the active menu item because the application is not rendered yet. You only init the application by using $mainframe->initialise(); but to start it you need to use $mainframe->execute();, however running this will render the whole application and the code below this call will not be called at ...


1

Solved. Problem was caused by JoomSEF component. Alias had wrong Itemid...


1

Assuming you are modifying the mod_menu's default.php template, then to access the "Link CSS Style" param, all you need is $item->anchor_css. But the above answer would be valid only for the mod_menu and only in the context of: $list = ModMenuHelper::getList($params); foreach ($list as $i => &$item) { $class = $item->anchor_css; } Update ...


Only top voted, non community-wiki answers of a minimum length are eligible