Keyword

Item Title h2 to h1

  • UnSourCeR
  • UnSourCeR's Avatar Topic Author
  • Offline
  • New Member
More
12 years 11 months ago #57834 by UnSourCeR
Item Title h2 to h1 was created by UnSourCeR
Hello, as i can see an k2 item makes the item title to h2 tag. How can i make k2 to makes item titles to h1?

Also i have one more question, is there an easy way to remove from url the word "item", as far i know i can use redirect 301 but i want to know if there is an easier way than make so many 301 redirects.

Thanks in advance for your help!

Please Log in or Create an account to join the conversation.

More
12 years 11 months ago #57835 by GWDLV
Replied by GWDLV on topic Re: Item Title h2 to h1
If you go to components > com_k2 > templates > default open item.php and look for <!-- Item title --> there you can change it to H1.

You can do it to the other files like category.php if you want H1 tags there too.

Please Log in or Create an account to join the conversation.

More
12 years 11 months ago #57836 by Jiliko.net
Replied by Jiliko.net on topic Re: Item Title h2 to h1
Hi,

@Adem Martin del Campo

You solution is good, but always think to make a template override instead of modifying the default template files :

getk2.org/documentation/tutorials/item/174-templating-with-k2-and-the-concepts-of-sub-templates

Olivier

Please Log in or Create an account to join the conversation.

More
11 years 6 months ago #57837 by Michael Mason
Replied by Michael Mason on topic Re: Item Title h2 to h1
Hi guys.

I have a similar issue and the edit above works for most sites I work on but now and again doesn't, strange.

Here's what I have done thus far...

I have edited the file in question and changed the "<h2 class="itemTitle">" to "<h1 class="itemTitle">" (and of-course the closing tag) but no joy.

So I created my own template files and sure enough the header converts to H1 but the image file is then not aligned properly so I'm stuck.

I use the following CSS to right align the default image and have the text wrap around:
.itemImageBlock {
	float: right;
}

That CSS works perfectly for the default template but not when I use my template, for some strange reason the image looks as though it has a massive right margin but when I inspect the code it does not.

FYI: I am loading a custom CSS file in the template.

Any suggestions...?

Please Log in or Create an account to join the conversation.

More
11 years 4 months ago - 8 years 4 months ago #57838 by Chandan Kumar
Replied by Chandan Kumar on topic Re: Item Title h2 to h1
You can use Header Tags Plugin and that will do your job. You don't have to modify any code.

I tested with Joomla and K2 articles, it works great.

geekflare.com/change-title-header-to-h1-joomla/
Last edit: 8 years 4 months ago by Chandan Kumar.

Please Log in or Create an account to join the conversation.

More
11 years 4 months ago #57839 by Vendreplus
Replied by Vendreplus on topic Re: Item Title h2 to h1
Did you try to make the change in templates/yourtheme/html/com_k2/templates/team/item.php or templates/yourtheme/html/com_k2/templates/portfolio/category.php if those files exist in your theme ?

To be shure, the best way for me is to make a multiple search on "h2" in a backup of the com_k2 directory of your template ( templates/yourtheme/html/com_k2/) because the files in it will overide on any change you should have done in more generic files like /components/com_k2 files.

Please Log in or Create an account to join the conversation.

More
11 years 1 month ago #57840 by David Willox
Replied by David Willox on topic Re: Item Title h2 to h1

Chandan Kumar wrote: You can use Header Tags Plugin and that will do your job. You don't have to modify any code.

I tested with Joomla and K2 articles, it works great.

www.chandank.com/cms/joomla/change-title-header-to-h1


Chandan - This plugin should be incorporated into K2!

Well done for finding it and thank you for posting it!

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum