Codex describes add_action(‘init’ but PHP Debug says this will cause future prob
-
I got the following in debug.log
PHP Warning: Use of undefined constant ‘init’ – assumed ‘‘init’’ (this will throw an Error in a future version of PHP)
In my functions.php file, I have
// // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // Add RSS news feed // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // add_action(‘init’, ‘customRSS’); function customRSS(){ add_feed(‘competitionfeed’, ‘customRSSFunc’); } function customRSSFunc(){ get_template_part(‘rss’, ‘competitionfeed’); }
What should add_action(‘init’ be replaced with?
The page I need help with: [log in to see the link]
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Codex describes add_action(‘init’ but PHP Debug says this will cause future prob’ is closed to new replies.