Hide shop-by from left navigation on only one page - magento

We have a Brands page http://www.topdogdies.com/brands.html where our main 'categories' are 'Brands', but we also have a shop by Brands lower on the page, because we need that shop-by for our other tabs.
How can I hide the lower Brand shop-by from only this page in Magento?

Each of this left column components are blocks. You can define which block should appear by layout (*.xml) files. You can find them in /app/design/frontend/base/default/layout/. Usually you have to edit catalog.xml to load in the page the blocks you wish.
This is a different case. Both Product Type and Brand are under the same block. You have to edit .phtml files to fit your needs.
In catalog.xml you can find the load order of the blocks, and the path to their .phtml files (maybe catalog/navigation here). Look at the section of "Category with Anchor" of layout files (category pages with filters links), with reference name="left" (that is the left column).
Track the right file and place an if clause to skip the Brand section at this page (maybe while the page category id is equal to the Brand's id or - easier but worse - when the current url contains brand.html).
While editing a file, always work on a copy. Place your copy in /app/design/frontend/default/YOURTHEMENAME/ and Magento will use the copy.

Related

Cant modify sales_email_order_items

We are using HTML tags in our options on products. The problem is, that the HTML is shown in the order confirmation email.
where can I find the PHTML file to change the option items?
app\design\frontend\our-template\default\layout\sales.xml
app\design\frontend\our-template\default\template\sales\order\items.phtml
I thought this would be the right files but nothing changes.
The template sales\order\items.phtml renders everything around the order items.
As you can see inside it there is this line <?php echo $this->getItemHtml($_item) ?>. That one renders the item row itself.
And the template for each item depends on the product type.
These are the templates used:
email/order/items/order/default.phtml - for simple, configurable and virtual products (grouped products are rendered as simple products).
bundle/email/order/items/order/default.phtml - for bundle items.
downloadable/email/order/items/order/downloadable.phtml - for downloadable items.
If you want to change the way the items look in invoices shipments and creditmemos you will find the templates in the same place. Just replace the folder order with the entity type (invoice, shipment, creditmemo).

Different product page layouts on different stores with magento multi-store

So here is my quandry..
I have three stores all with seperate themes.
I want the actual layout of the product page to vary between stores. So for instance I would like to include full description on one and only short descitopn on the other and would like to add a tag line field in another. Basically all three will need complete sepearate layouts.
I think the product page layout is drawn from app/design/front/base (as a standard layout).
Can I include the relevant files (and directories) from base into app/design/frontend/default/theme to allow me to achieve the above?
I think the file I need to edit/copy is the view.phtml? Can you confirm this also?
You need to also copy catalog.xml to related theme of store. If want to remove description or add other details of products.
you have to copy view.phtml to related theme of your store and modify/add/delete the code in view.phtml
to remove anything just comment the code in view.phtml file.

Make a new page in joomla 2.5

i have done the home page with 8 custom html module . Now i have to make new pages like contact us, about, services ect. but it different from the home page. i need to use only two module other are not useful for other pages.
I am new in joomla would like to how could i make new pages in joomla.
Create a new page in the article manager and a menu item to that page. Then go into the module manager and enable those two modules for that menu item. You'll now have the new page and those 2 modules will appear.
Depending on what template you are using they may need to be in a different "position", e.g, below the content, to the side, etc. In that case use the duplicate function in the module manager to make a clone of those modules and place in the appropriate positions.
Note: If you want the modules to appear in the actual content area you can use the loadposition plugin, e.g. if you create a blank article you can then enter {loadposition mynewmoduleposition} to place the module in the page. Just remember to select that page in the module manager and put set the module to that position.
Just a note that joomla is "menu related" site where pages mean menu itemID, when you say "pages" i believe you have experience in wordpress...
All "pages" in a Joomla website are created with the single index.php file in the template you are using. In order to alter what displays from one page to another there are a few things to consider.
First, Joomla uses menu items to determine what a page is. When you create a menu item, it is assigned an itemID. In the case of menu items that have child items (an article within a category menu), then the child items inherit the parent itemID. You can then select to display modules on that menu item. In the module parameters there are options to display a module on all menu items, no menu items, selected menu items, and exclude menu items. You would change these selections to fit what you want displayed.
The second thing to consider is the template itself. It sounds like you have created a custom template so you will likely need to alter that. The index.php file should contain all of the possible module positions that you would may want to use. In order to hide the positions that are not being used on a particular page, you need to make those positions collapsible. You do this by not displaying any module position that is not populated on a particular page using this code:
<?php if ($this->countModules('top')) : ?><jdoc:include type="modules" name="top" style="xhtml" /><?php endif; ?>
You would want to use similar code for each module position on the page. This allows you to have a sidebar position that is not displayed on the home page, but is displayed on other interior pages that include a module in that position.
Ideally, if you plan the template properly, you will have many module positions that will allow you to add content in many different positions without having to touch the template once it is coded.

how to create a right sidebar in magento which will be visible only on product view page

I am new to magento .
I want to create a right sidebar on product view page such that this is visible only on product view page not on other pages.
How can I do this.Please Help.
Thanks.
To have a right sidebar only on the product page you need to to a few things:
in the admin panel set the product pages to have 2 columns with right sidebar
create a block and template file (or just edit one that is available)
in catalog.xml (this is in your themes's layout folder) find the handle called and within that section find in there you can add your block / template file.
For more info on how you can create blocks and templates see here.
In magento almost every postion is handled by catalog.xml, (if you go the proper way) You can place any static block , in catalog.xml you will find the postioning of blocks for every page (be it category, product or home page) just you need to place the block in the right reference.

URLs in module not pointing the correct category from index page

I have 2 modules on my home page. One lists most popular, one lists most recent k2 items from 2 different categories, video and blog. The links to the blog entires go to /blog/item/, so the side bar modules are being displayed correctly. But for some reason the video entries are linking to /component/k2/item/, and on that page the modules that are supposed to on the right do not show up at all. The content area takes up the entire width of the site.
What is further confusing about this situation is that i have duplicates of those modules running on certain interior pages, with the same settings, that link to the items correctly. The only reason i have 2 of the same module is because i need that same module to display below the content on index page, and in the side bar on select interior pages.
I do not have a menu item that links to the video category. The main category is Education, and there are 3 sub categories. blog, video, article. There are only menu items for Blog, and for Education. I already have that same module in the some of the interior pages, and it works fine.
what am i doing wrong?
The solution is pretty simple, the explanation is rather complicated. Here is the solution -
Create a new menu, call it hidden links or something. Doesn't matter what is it called, you will not display this menu on the site.
Create a new menu item for the video category.
Assign your modules to that hidden menu item.
If you don't care about what is happening, just know that you can always create hidden menu items to control layout on pages.
If you do care, get a cold drink and get comfortable...
Menu items in Joomla server several different purposes other than providing links for users to get to content. If you are using the core SEF URLs, this is the first place Joomla looks to create those URLs. In general a URL is built like this - joomla install/parent menu item alias/sub menu item alias/content item/article alias.html. Since your video category does not have a corresponding menu item to use for building URLs, it uses the default URL scheme.
The menu item is also the source for the itemID that every page uses. If a particular page does not have a related menu item, it will inherit the itemID from the previous page usually or in the case of k2 items/joomla article it will inherit the itemID from the menu item that links to the parent category of the content. The itemID is used to determine module menu assignment. This is why getting to a particular page that does not have a menu item 2 different ways will often give you pages that look different, different itemIDs were inherited resulting in different modules being displayed.
Since Joomla really counts on the itemID, you should always specify a menu item for any content you are diplaying, even if you do not want to display a link in the menu. By creating a menu that does not appear in a module, you still get the itemID you need for the content, but the menu never appears anywhere. Usually, a link to a category will be enough since child content will pick up that itemID, but in some cases it makes sense to create menu items to specific content items/articles. You would do this any time you want a specific URL for an item. For example, if you wanted to create a URL like your-site.com/special-offer, you could create the content item for the special offer, then make a menu item with the alias special-offer to get the correct URL.
Joomla also uses the menu item for browser titles and page titles. Your question is not related to that so I'll stop here, but as you can tell it is pretty important to know when to create a menu item for your content.

Resources