[Resolved] Using custom field to overwrite default H1
Firstly, just want to say how great your theme is. I’m familiar with WordPress but new to actually building a site with it, so it’s been really handy having a lightweight yet powerful theme to work with.
I’ve got a couple of questions I’m having trouble with but I’ll spread them into separate posts as they might help others in future.
I’d like to change the default H1 heading that appears on a page (i.e. the page title) by using a custom field. By default WordPress puts whatever I put as the Page Title as an H1 Heading. I’d like to swap this out for a keyword optimised heading instead. I know I could add the desired content as a page title, manually amend the slug and create a custom menu, but that’s messy for the page admin.
I’ve read that you can use a custom field and amend the Pages.php file to display the custom field in place of the H1 heading. However, I can’t work out how to do this with the Quark theme. I’ve read elsewhere that I’d need to edit Functions.php, but I can’t fathom that either!
Here’s the links I’ve been trying to work from. Any ideas?
Using pages.php: http://www.getwpress.com/seo/h1-hack-for-wordpress-pages/
Using functions.php: http://halgatewood.com/wordpress-function-check-for-h1-custom-field/
- The topic ‘[Resolved] Using custom field to overwrite default H1’ is closed to new replies.