I have added custom fields on every page type so I can easily add my own title and description tags so they are customisable on each and every page. The code I have used for that is here:
Pulling in the custom fields and displaying them in the header of my pages.
The trouble I am having is that, when I look at the source code of a page, Wordpress seems to add it's own tag. So my site has two tags. I would prefer to keep my own customised ones and get remove the Wordpress version.
From your theme files I can't see where the general Wordpress title tags are being pulled in from - Could you point this out please? :)
Thanks for the reply :) I'm aware of Yoast and I was hoping to avoid It to be honest, I'm doing everything customised so I can properly control my SEO efforts on each page without a plugin adding lots of unnessesary bits.
So, if you could let me know where the <title> tag comes from, I can edit this and customise it :)
I have tried to delete this area of cod you pointed out to see if it makes any difference - unfortunately it doesn't... I delete the code but the <title> tag still appears...
if you deleted it doesn't change yes, cause this function hooks the core function inside wordpress core functions, basically you have to work inside that function or set your setting.
P.S: If you like our theme, it would help us a lot if you could give us five star rating on themeforest from your Downloads tab, (if you don't know how, just open this link).
A huge thank you from Laborator in advance, wishing you a great week!
I have added custom fields on every page type so I can easily add my own title and description tags so they are customisable on each and every page. The code I have used for that is here:
Pulling in the custom fields and displaying them in the header of my pages.
The trouble I am having is that, when I look at the source code of a page, Wordpress seems to add it's own tag. So my site has two tags. I would prefer to keep my own customised ones and get remove the Wordpress version.
From your theme files I can't see where the general Wordpress title tags are being pulled in from - Could you point this out please? :)
Thanks
Hi shan_2000_uk
This would be easy if you use Yoast Plugin, it i will fix any issue it's popular and works great.
hello,
Thanks for the reply :) I'm aware of Yoast and I was hoping to avoid It to be honest, I'm doing everything customised so I can properly control my SEO efforts on each page without a plugin adding lots of unnessesary bits.
So, if you could let me know where the <title> tag comes from, I can edit this and customise it :)
Thanks,
Shaun
Hi shan_2000_uk
Can you try to edit the function 'kalium_wp_head_open_graph_meta' file location is : themes/kalium/inc/laborator_actions.
Good Luck.
Hello,
Thanks for this, I may be mistaken, but this function looks like it controls the og: tags and not the <title> tag?
The title tag can be seen highlighted in the screenshot I have attached with the og: tags below it...
Any ideas where the title tag is generated from? (or indeed, if I'm wrong, which part of that function generates the <title> tag?).
Thanks a lot :)
Shaun.
Hi shan
This is the code generates title tag, you can read about it on wp_title
file location is : themes/kalium/inc/laborator_filters.
Thanks again Eroll, I really appreciate the help, I think we're getting closer...
I managed to find the code below initially, but I'm having trouble just disabling the <title> tag.
I think I need to delete or overwrite it in my child theme, otherwise when I update the theme, it will overwrite my changes.
Would I just copy the file and directory into my child theme and make the changes there?
Thanks,
Shaun.
Hi again Eroll,
I have tried to delete this area of cod you pointed out to see if it makes any difference - unfortunately it doesn't... I delete the code but the <title> tag still appears...
Hi there
if you deleted it doesn't change yes, cause this function hooks the core function inside wordpress core functions, basically you have to work inside that function or set your setting.
Tried by taking simple changes to see difference.
I don think I understand - I'm currently trying to remove the <title> tag with this code inside my functions.php in the child theme:
add_action( 'after_setup_theme', 'remove_head_title', 0 );
function remove_head_title() {
remove_filter( 'wp_title', 'kalium_wp_title_parts', 10 );
But it doesn't work and now you're saying I shoujnldnt remove it? - Could you help please?
Is there another way I can remove the <title> tag? or if I wanted to change it from my child theme, how would i go about doing so?
Hi,
The title is automatically added via "add_theme_support( 'title-tag' );" so here is you can remove the title:
Can you please add the following code in functions.php (end of file):
That works perfectly, thanks so much :)
Glad to hear that it worked,
P.S: If you like our theme, it would help us a lot if you could give us five star rating on themeforest from your Downloads tab, (if you don't know how, just open this link).
!
A huge thank you from Laborator in advance, wishing you a great week
Best regards,
Laborator Team