Setting different XML blocks based on Magento storefront ID -


I am currently trying to install a multi store version of Magento, which will be local in different countries.

I am trying to specify different XML blocks on which the store front is in use. For example, on British version, show British images, French one, French images show.

I have the following in a local.xml file, but this does not seem to change the item, although the tags are working, for example if I delete a header tag then that Remove the header block from the storefront.

  & lt ;? XML version = "1.0" encoding = "UTF-8"? & Gt; & Lt; Layout version = "0.1.0" & gt; & Lt; Default & gt; & Lt; / Default & gt; & Lt; Cms_index_index & gt; & Lt; Reference Name = "Basic" & gt; & Lt; Block type = "banner / banner" name = "banner_home_main" template = "unibanner / banner-file.phtml" & gt; & Lt; Action Method = "SetData" & gt; & Lt; Name & gt; Banner_group_code & lt; / Name & gt; & Lt; Price & gt; Home_page_main & lt; / Pricing & gt; & Lt; / Action & gt; & Lt; / Block & gt; & Lt; / References & gt; & Lt; / Cms_index_index & gt; & Lt; STORE_name_uk & gt; & Lt; Cms_index_index & gt; & Lt; Reference Name = "Basic" & gt; & Lt; Action Method = "Unset Chilled" & gt; & Lt; Name & gt; Banner_home_man & lt; / Name & gt; & Lt; / Action> & Lt; Block type = "banner / banner" name = "banner_home_main" template = "unibanner / banner-file.phtml" & gt; & Lt; Action Method = "SetData" & gt; & Lt; Name & gt; Banner_group_code & lt; / Name & gt; & Lt; Price & gt; Home_page_main_uk & lt; / Pricing & gt; & Lt; / Action & gt; & Lt; / Block & gt; & Lt; / References & gt; & Lt; / Cms_index_index & gt; & Lt; / STORE_name_uk & gt; & Lt; / Layout & gt;  

To do this, You do not need to delete the block, you override them in the STORE_ handles XML.

Then your main local. In Xml (one from the main store), type something like this:

  & lt; STORE_name_uk & gt; & Lt; Reference Name = "Basic" & gt; & Lt; Block type = "banner / banner" name = "banner_home_main" template = "unibanner / banner-template.phtml" & gt; & Lt; Action Method = "SetData" & gt; & Lt; Name & gt; Banner_group_code & lt; / Name & gt; & Lt; Price & gt; Home_page_main_uk & lt; / Pricing & gt; & Lt; / Action & gt; & Lt; / Block & gt; & Lt; / References & gt; & Lt; / STORE_name_uk & gt;  

For some reason, I had to set the "Like" value on the initial block declaration


Comments

Popular posts from this blog

java - Can't add JTree to JPanel of a JInternalFrame -

javascript - data.match(var) not working it seems -

javascript - How can I pause a jQuery .each() loop, while waiting for user input? -