Support Forum
When switching between my theme and the default in the Admin dashboard I get the following message:
Fatal error: Cannot redeclare spdefault_textdomain() (previously declared in /problem-with-post-edit-buttonome/gruzcom1/public_html/ABF_Test/wp-content/sp-resources/forum-themes/cTheme/templates/spFunctions.php:18) in /problem-with-post-edit-buttonome/gruzcom1/public_html/ABF_Test/wp-content/sp-resources/forum-themes/default/templates/spFunctions.php on line 19
Despite this error the switch seems to be successful, I have checked the sPFunctions.php file and it looks the same as the one in the default theme, any ideas what this might be?
Conrad
It is simply the name of the function setting the localisation in the theme spFunctions.php file. If you copied it from one iof ours then it will have the same function name. For that brief period when you switch themes, both are loaded causing the duplicate function name warning. Not sure there is anything we can do about this other than to recommend people use a unique function name for that call - preferably including the theme name in the function name as we have done.
YELLOW
SWORDFISH
|
It is this code:
add_action('init', 'spDefault_textdomain');
# load the theme textdomain for tranlations function spDefault_textdomain() { sp_theme_localisation('spDefault'); }
This is from the spDefault theme. The name is in the add_action and then is the name of the function. They both need changing and as I say, we would recommend changing them to match the theme name chosen.
YELLOW
SWORDFISH
|
I never did sort this out can you be really specific and tell me exactly what to do? My theme has been named Riverbed 1.0, I think that I have done this correctly as this is how it appears in the available Themes panel. It also works fine I just get the message when switching. Yes I did copy your default theme initially and the 2 spFunctions files are identical. Where and what exactly should I rename?
Sorry I'm feeling particularly dense this week I've been running simulations of antennas for weeks at work and my brain is totally fried!
Conrad
1 Guest(s)