“Cannot modify header information – headers already sent by” while using get_stylesheet_directory_uri()
“Cannot modify header information – headers already sent by” while using get_stylesheet_directory_uri()
“Cannot modify header information – headers already sent by” while using get_stylesheet_directory_uri()
Best practice when a theme already has a parent theme (so can’t create child theme)
I fixed the issue. From error_log in public_html/wp-admin I found: I looked some to see whether it was specific to my livesite, something like indexing, but the error was that I closed my functions.php with a “?>” and there may have been whitespace afterwards that was attempted to be sent which caused conflict. I erased … Read more
I see that both icon arrays ($ui_icons and $social_icons) in Twenty Nineteen can be accessed publicly, so I managed to replace any icon via the init hook in a child theme. An example: function child_init() { TwentyNineteen_SVG_Icons::$social_icons[‘instagram’] = ‘<svg>… Insert new Instagram icon SVG code here …</svg>’; } add_action( ‘init’, ‘child_init’ );
Best way to edit/change comment-template.php without changing the core
You had the right idea, but made an unfortunate typo: . ‘./custom/navbar.css’. Removing the additional fullstop should correct the URL, otherwise you were succesfully enqueing a stylesheet, the code just enqueued the wrong URL due to the typo
Child theme stylesheet not reflecting the changes
This looks like google font imports via the theme options, are you sure that this font is not selected anywhere inside the theme’s options, a page template, a plugin or the themes’ functions.php file? It MUST be in one of those locations. If you can’t find it, use this (you gotta find out the handle … Read more
Uploading a new zip package should work the same way as updating themes or plugins. Please not however that it will only add new files and overwrite existing ones. If you upload a new package without some files (eg. unnecessary CSS or JS), these files will remain on server. So, it is good to take … Read more
The 500 error comes from the missing function – which I presume is included in the missing included file – check your file paths to ensure you are calling the include_once in the correct place.