- This topic has 8 replies, 3 voices, and was last updated 3 years, 4 months ago by David.
May 9, 2018 at 5:32 am #571355keyaziz
I am guessing this has been caused by an update but this is extremely frustrating as it took me ages to work out how to do it the first time round.
Since the update I have lost:
1. Yoast breadcrumbs on the site – they no longer show but were showing before updates (They will show if I activated another theme)
2. I have a small round author image below titles on posts only and in between “by” and the “author name” on my post pages..this has vanished too.
I haven o idea why they have disappeared but would appreciate a quick way of rectifying it without having to go through all the styling issues with the 2nd problem.
Also could someone suggest why this would happen and why they disappeared? I have not messed with any styling to have triggered something.
Thanks for the help.
Thanks for the help.GeneratePress 2.1.1May 9, 2018 at 6:20 am #571386DavidStaffCustomer Support
Hi, i can’t see what would have changed in the update to have caused this issue.
The only error i can see in the console is the google tag manager is 404’ing. I would first try temporarily removing that script.
If not please can you try point 1 here:
If not we may require backend access to resolve.May 9, 2018 at 8:46 am #571582TomLead DeveloperLead DeveloperMay 10, 2018 at 1:40 am #572131keyaziz
I followed the thread that was on here about the author image. It was not in the hooks, it was in functions I believe. The yoast I just put in my single post file. It was very easy to activate – maybe I just need to reintroduce the code?
Will try following the debugging tips. Thansk for the help…I really wish I had written down exactly what I did before this happened so I could rectify it quickly.May 10, 2018 at 4:38 am #572226DavidStaffCustomer Support
Hi Keyaziz, did you use a child theme? If not making any edits to the theme function or template files will get overwritten when the theme updates. Alternatively you can use Hooks for some codes or a plugin such as Code Snippets to add the functions.
If you have a backup of the site then maybe roll back and extract the codes you have added.May 10, 2018 at 4:43 am #572230keyaziz
No child theme being used just generatepress and the generatepress plugin.
I just added some code to functions which has brought back the author image. I am guessing like you saay I should move this code to hooks because it;s being overwrriten for some reason when the theme updates?
If so then we can say this is solved and I will just put code in there from now on?
Thanks for the help.
EDIT: Only problem with adding the yoast code there is that instead of just being on the single post pages it shows in the category pages under the titles too which I didn’t want.May 10, 2018 at 4:47 am #572232DavidStaffCustomer Support
Hi Kayaziz, yes you should never edit the parent theme function files directly, when an update happens those files are overwritten.
Yes GP Hooks are a good option they will never be replaced on an update, here also are the other methods of adding PHP:
DavidMay 10, 2018 at 4:55 am #572240keyaziz
Thank you!May 10, 2018 at 4:59 am #572246
- You must be logged in to reply to this topic.