only the category title or every title?
for every title
catalog/view/theme/*yourtheme*/stylesheet/stylesheet.css
find and add after
for category title Only
open catalog/view/theme/*yourtheme*/template/product/category.tpl
and replace with
then in catalog/view/theme/*yourtheme*/stylesheet/stylesheet.css add this at the bottom...or whatever..
for every title
catalog/view/theme/*yourtheme*/stylesheet/stylesheet.css
find
Code: Select all
h1, .welcome {
Code: Select all
text-align: center;
for category title Only
open catalog/view/theme/*yourtheme*/template/product/category.tpl
and replace
Code: Select all
<h1><?php echo $heading_title; ?></h1>
Code: Select all
<h1 class="categorytitle"><?php echo $heading_title; ?></h1>
Code: Select all
.categorytitle { text-align: center; }
Opencart Templates, Modules, Themes & Custom Development | ShopThemer
Wow thanks! That totally worked!Xyph3r wrote:only the category title or every title?
for every title
catalog/view/theme/*yourtheme*/stylesheet/stylesheet.css
findand addCode: Select all
h1, .welcome {
afterCode: Select all
text-align: center;
for category title Only
open catalog/view/theme/*yourtheme*/template/product/category.tpl
and replacewithCode: Select all
<h1><?php echo $heading_title; ?></h1>
then in catalog/view/theme/*yourtheme*/stylesheet/stylesheet.css add this at the bottom...or whatever..Code: Select all
<h1 class="categorytitle"><?php echo $heading_title; ?></h1>
Code: Select all
.categorytitle { text-align: center; }
I forgot there's a text-align property.. my bad
By the way, Can I add some short description below the Title?
how? some short description from the existing one(let's say first 50 characters)..or you want to add a custom field in admin for each product(more difficult)?
Opencart Templates, Modules, Themes & Custom Development | ShopThemer
Hmm the one I want is short description exactly below the h1 title (which mean Category and Sub-Category Title), and I want each category / sub to have a different description.Xyph3r wrote:how? some short description from the existing one(let's say first 50 characters)..or you want to add a custom field in admin for each product(more difficult)?
Is that possible?
Thank You!
You move the category description unde the h1...
Opencart Templates, Modules, Themes & Custom Development | ShopThemer
A strictly theoretical Solution for centered Category and Product Page Titles in OC v.3.0.2 Versions:
in:
OC v.3.0.2.0 theme/default/template/product/category.twig LINE Number ~17
change:
to:
then, add:
above the content below: (OC 3 default Theme stylesheet view)
to make it look like:
into your...theme/default/stylesheet/stylesheet.css file.
---
and this one should match a default Product Page Code in OC v.3.0.2 Versions:
in:
OC v.3.0.2.0 theme/default/template/product/product.twig LINE Number ~123
change:
to:
in addition to adding the:
to the stylesheet.css File as mentioned above. Only use one single
.categorytitle {text-align: center;} Line Entry in the stylesheet.css file,
if you use this 'Center Title' Function in both Category and Product Pages.
---
Untested, good Luck!
And don't forget, to clear out all of your CACHE Systems in OC-3, after you made the changes,
and clear out Browser Cache too, or better don't expect it to show up anywhere, as it should...
Ernie
---
Imagelink: (OC v.1.5.6.5_rc/OC v.2.0.3.1 Theme)
download/file.php?mode=view&id=35600
in:
OC v.3.0.2.0 theme/default/template/product/category.twig LINE Number ~17
change:
Code: Select all
<h2>{{ heading_title }}</h2>
Code: Select all
<h2 class="categorytitle">{{ heading_title }}</h2>
Code: Select all
.categorytitle {text-align: center;}
Code: Select all
h1, h2, h3, h4, h5, h6 {
color: #444;
}
Code: Select all
.categorytitle {text-align: center;}
h1, h2, h3, h4, h5, h6 {
color: #444;
}
---
and this one should match a default Product Page Code in OC v.3.0.2 Versions:
in:
OC v.3.0.2.0 theme/default/template/product/product.twig LINE Number ~123
change:
Code: Select all
<h1>{{ heading_title }}</h1>
Code: Select all
<h1 class="categorytitle">{{ heading_title }}</h1>
Code: Select all
.categorytitle {text-align: center;}
.categorytitle {text-align: center;} Line Entry in the stylesheet.css file,
if you use this 'Center Title' Function in both Category and Product Pages.
---
Untested, good Luck!
And don't forget, to clear out all of your CACHE Systems in OC-3, after you made the changes,
and clear out Browser Cache too, or better don't expect it to show up anywhere, as it should...
Ernie
---
Imagelink: (OC v.1.5.6.5_rc/OC v.2.0.3.1 Theme)
download/file.php?mode=view&id=35600
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Who is online
Users browsing this forum: No registered users and 69 guests