Porting a website to Joomla: How do I deal with Javascript menus? - joomla

I am porting an existing site to Joomla 1.5. The menus on the existing site use rollover images and inline Javascript. How can I make the menus look the same in Joomla and use the Joomla menus, without rewriting the menu code?

It ended up being rather simple, actually. Joomla renders menus as <UL><LI><A> tags. All I had to do was extract the background from one of the menu images (both in selected and unselected state), set a images as the background in each of the styles in the Joomla CSS, and voila, it almost looks exactly like the old site (minus a slightly different font, since the text is no longer part of the image).

To show a menu item as an image, edit your menu item and select an image under the Parameters (System) heading (This list automatically populates with the images in the images/stories folder).
You will also need to set the module for the menu to display the images you set. Go to Extensions > Modules, then select the module for your menu (for instance, Main Menu). From there, select Other Parameters and then set Show Menu Images and Menu Image Link to Yes.
The rollovers will be a bit trickier. You won't be able to add inline JavaScript, but you might be able to use JavaScript to find your menu and assign rollovers to each item. Joomla ships with MooTools, or you can use jQuery if you're more comfortable wit hit. Use the Menu Tag ID field under Advanced Parameters to give your menu ul element an HTML id.

Related

How to attach ItemID to joomla footermenu

I am don't know joomla, but familiar with wordpress & PHP & wants to change some links in my clients existing project.
I have a menu which is a link like http://www.smarti.com.sa/index.php?option=com_content&view=article&id=6&Itemid=107 while calling it from top navigation menu.
developer has taken same link in footer but it redirects to
http://www.smarti.com.sa/index.php?option=com_content&view=article&id=6
Now i want ItemID in footer link also.
My Site URL is http://www.smarti.com.sa/
In that please Products > Microsoft.
Please give solution
As per your post, Your menu link for now is : http://www.smarti.com.sa/index.php?option=com_content&view=article&id=6 .
But, you want to use this like : http://www.smarti.com.sa/index.php/your_menu_name.
You can use aliases of menu links.
You can find aliases here, When you create/edit a menu link from backend of joomla you can see an alias associated with it. You can also find Aliases of menu link from grid screen of you menu type.
For showing Menu in front end you have to create CUSTOM HTML module, You can find how to create Custom HTML module here : http://vinaora.com/2012/09/how-to-add-custom-html-to-your-joomla-site-2/
Now, How can you find HTML to write in thst Custom HTML Module? So, for this you can go the page of front-end where that menu is visible. Now prss CTRL+U, you will see the HTML of that page. Here, you have to find the HTML of those menus.
In this HTML, you will find the links like : index.php?option=com_content&view=article&id=6
Now, you have to replace these links with index.php/alias_of_your_menu.
Now paste the edited HTML in Custom HTML module and save it by selecting a proper Position.
You can use joomla menu module in the footer.
Joomla also has the option to display second level menu items in a menu module.
To do this:
Set the Start Level to "1" and the End Level to "1".
That's all. Good Luck.

Create a childpage in Joomla without showing it in a menu

I would like to create a page in Joomla without showing it in a menu.
That would be easy when the URL could be from the root, e.g.
www.mysite.com/hiddenpage
I would just make a menu without module to show it and assign a menulink to that hidden menu.
However the url should be
www.mysite.com/parentpage/hiddenpage
So the page should be linked to another existing page as a childpage but without showing in the menu.
So far this seems not possible?
Am I overlooking a feature in Joomla which would allow me to simply deactivate visibility in the menu without preventing the page from being accessed from the internet?
Or perhaps is it possible to edit or override a core component to force Joomla to allow this behaviour?
UPDATE:
Too much thinking in one direction...
The solution to do this is to edit the menu-item > linktype > css give it class "hide" (integrated bootstrap class) to just block visibility in the menu...
It's possible but a litle bit tricky. Try these steps :
Create a new two articles, name it as you wish (for example Article A and Article B )
Create a new menu group (from your administrator page go to : Menus > Menu Manager > Add new menu, name it as 'Hidden Menu'
Create a new Single Article menu item (under the 'Hidden Menu'), choose 'Article A' as as the article source and type 'parentpage' in the Menu Title field
Create a new Single Article menu item (under the 'Hidden Menu'), choose 'Article B' as the article source, choose 'parentpage' menu as the parent item and type 'hiddenpage' in the Menu Title field.
Now both of urls www.mysite.com/parentpage and www.mysite.com/parentpage/hiddenpage should be accessible now
As others have mentioned you can find extensions to modify URLs or hide the menu items using CSS, but these can require quite a bit of work especially if this is a one-off or once in a while situation.
However, there is one way to do this with Joomla as-is and will work with any type of menu items, not just articles. These instructions assume you already have a 'hidden' menu setup.
In a hidden menu, create menu items (or move them if they already exist) for parentpage and hiddenpage.
Set parentpage as the 'Parent Item' option in the hiddenpage menu item. Basically, create the page/subpage structure you'd like to see in the URL.
On your visible menu, create a 'Menu item Alias' (under 'System Links') menu item. Set the 'Menu item' option to the parentpage (listed under the hidden menu).
Enjoy. Parentpage is a visible menu item. hiddenpage is available at www.mysite.com/parentpage/hiddenpage
-Nick
No this is not possible with Joomla.
There are several options for you to achieve the same result, I list them in order of ease.
Use joomla redirect component. Simply tell the user to surf to the url he wants, he will then find it in the administrator - components - redirect, where she can insert the non-sef url.
Tell them to use a different prefix: i.e. create a hidden menu where they will add the direct links;
Additionally, in order to remove the id from the url you can:
Install simplecustomrouter extension, it should do the job out of the box but some coding may be required on your part in order for it to work properly; extremely lightweight.
Go for a blasoned SEF extension such as sh440sef, this will add some overhead and may require a lot of work in configuration.
FOR JOOMLA 3.X:
While editing the childmenu just set (under "Linktype") "Display in menu" to "no"... it's simple like that!
Here's a reference to the joomla.docs site
https://docs.joomla.org/images/6/6f/Help-3x-menus-menu-manager-new-menu-item-link-type-en.png
if link is broken just search for "edit menu linktype joomla 3" in future.
I'm glad I can return the many saved searchtime to y'all stackpeople. Go on Community!

Joomla! 3 menu drop-down behavior without showing new article possible?

The Joomla! 3 administrative console in my installed version (Joomla! 3.1.5 Stable) plus at least a Joomla! demo web site showcase menus that don't switch to an article if you press them, but present only the drop-down menu at first. The rendered article (i.e. the content below the menu) only changes once a menu-item is selected/clicked.
For instance, visit demo.joomla.org. The content below the menu reads "Joomla! is a free, open source content management system ..." Now if you press e.g. "Joomla!" inside the menu, a drop-down list appears, but the cited text does not change yet. Only if you press a particular menu item it changes (currently e.g. to "Joomla! 2.5.16 Released ...").
I would like to accomplish the same behavior in a Joomla! 3-powered web site but haven't yet been able to do so. On my site (sorry, not yet available to the public) clicking a menu of this kind brings up the article, and so far I have found no way to prevent that. I'm referring to articles because my menus are of type "Single Article". I've looked at other menu item types too but they did not seem to offer a solution either.
So can the behavior the demo site's menus be accomplished (without installing further extensions), and if so how? After all, the demos are surely hosted on Jooma! servers :) Perhaps this is a matter of choosing an appropriate template? But then, the solution does not seem obvious and googling reveals different opinions as to whether this is/was possible at all.
UPDATE The following is a depiction of what I get when changing the menu item type for "Open Source" from "Articles | Single Article" to "System Links | Text Separator": it now looks odd and no longer seems to function as a menu (no drop-down effect). In the HTML source the CSS classes assigned to the three menu items are "item-x current active", "item-y divider parent", and "item-z parent" respectively. (Why isn't "Open Source" marked active?)
UPDATE I am using the protostar template (marked as Default for Site under Extensions | Type Manager).
Create the top-level menus as System - Separator; this means they have no link attached, but only serve the purpose of organizing (sub)menu links.
Then when you click them, based on the setup of your menu module, they will show the sub-items. Beware, the most common behaviour is not to wait until clicked, but simply show the submenu items when hovered (when you bring the mouse over them). But the event they respond to depends on the module (mod_menu), its template override, and other scripts your template may load.
Update:
If you're using mod_menu, in the module list it will be listed as Menu; if you were using another menu module, I guess you would remember installing it :-)
I am not a protostar / twitter bootstrap fan so I can't help you much on it, but dropdown menus are definitely supported, I just tried putting the menu in the position navigation, with
"Menu Class Suffix" = " nav-pills nav-dropdown"
and it worked correctly with dropdowns on hover. As per having dropdowns on click instead of hover, look at this guide

joomla 3.1 ajax module

ok so I have a main horizontal menu that appears on all pages, (company, products, about us) and I want another menu, (vertical accordion on the left side of the page) inside products:
phone
--samsung galaxy s4
--iphone 4
pc
--hp pavilion
--toshiba
and when I clic on any of the sections of the accordion menu the information about each product appears on the right using ajax. I have made the accordion menu as a custom html module and the same with the content that its supposed to appear on the right side (I used modules instead of articles).
Now I'm thinking that its probably better to create another menu for the accordion and that the content should be articles, but I dont know how to make it look like an accordion, and I still need help using ajax to show the content of each product.
the main thing is, I want to use ajax to replace one module for another when I clic on any section of the accordion menu. is there any way to do it, all I could find in google its how to change the main article of the page, for that i have to replace
jdoc:include type="component" and add an event with the url but that replaces everything and I just want to change the right module/article
something like this
I dont know if I explained myself well.
I used shaper helix 2 template
Any help would be appreciated.
Check for some extensions here: http://extensions.joomla.org/extensions/structure-a-navigation/menu-systems/accordion-menus
An advice... you better forget ajax to load the catalog because as it used on the example the product pages are missed by search engines, as spiders and crawlers doesn't execute javascript. Try to search for that domain... results don't have any product.
Good luck!

Rename Menus in Magento 1.7

Have a Magento 1.7 template with three left side vertical menus, Accordion, CSS and Mega and all menus are respectively named instead of Categories. I can rename CSS menu easily via its phtml file, but the other two seem to be impossible to rename. Their phtml look nothing like the CSS menu and appear to have hash data, my guess from the template developer. I have done a search on my entire site and database and I can't figure out where it is pulling the name from (I have spent an embarrassing amount of time on this). I have asked the developer, but they refuse to answer a “Magento” question. The Accordion menu is also the only menu I can get to work where the products show on the home page and when you click on a category the page displays correctly. If I use CSS menu it will display products on the home page, but when you click on the category it doesn’t appear to be pulling the CSS formatting.
Any help would be appreciated.
/app/design/frontend/default//locale/en_US/translate.csv
Enter as: "Accordion Menu","Categories"

Resources