Ok I am in the process of updating a theme in Magento 1.8 and have everything set except the products are still showing the old theme. The store has about 1800 products and would take me forever to change the theme for every one manually. Is there a query to change them on all of the products at once?
The setting can be found in the admin panel:
Catalog -> Manage products -> select product -> design -> custom design dropdown
(see image below)
what I would like to change it to, you can see from the image below
Any help with this will be greatly appreciated.
Thanks in advance,
jmituzas
Best Answer
First, Magento is manage
custom layout
usingcustom_design attribute
which isvarchar
attribute and save attibute value at tablecatalog_product_entity_varchar
First i have check custom_design attibute id and this id 103 using
Step1: get load product eav attribute
step2: get Attibute id using below code
$custom_design->getAttributeId()
.step3: get table of this attribute using code
$custom_design->getBackend()->getTable();
Alternative process to get
custom_design
attribute idGet custom_design attibute id using below code:
Just goto
admin>Catalog>Attribute>Maange Attribute>
Select attributecustom_design
from grid and click on it and in this attribute view page urlyou can see attribute id
admin/catalog_product_attribute/edit/attribute_id/
103/key/e88df75c6ef10d0be06f2aa52b99afef/
Now that mean you update this eav value using below query
and you will have some fields
1)
entity_id
isproduct id
.You can putproduct id
at your condition of update query2)
store_id
is import whenever you havemultiple store view or website
.As custom_design is store_view scope attibuteHow to get list OF templates
Just to open
any product at admin
and goto itDesign tab inspect custom design drop down
get
list of option values of this attribute
From here you will chose your
template
likebase/default
ordefault/modern
orrwd/default
Note:
You will update value with NULL
that means italways design from your Store current design template and package
.Most of cases
product design
it take fromCurrent store design template
,so it showing NULLFinal Query Look like: