[Solved] Between functions.php (theme), widgets, and plugins, which is loaded first?

The plugins are loaded right before theme (yes, I’ve been looking for excuse to use this): However it is wrong to think about either as point of code execution. For most cases everything should be hooked and executed no earlier than init hook. According to Codex widget registration with register_widget() should be hooked to widget_init. … Read more

[Solved] Where to put my code: plugin or functions.php?

I would start with this question: Is the functionality related to presentation of content, or with generation/management of content, or of the site, or of the user identity? If the functionality is not related specifically to presentation of content, then it is squarely within Plugin Territory. This list is long: Modifying core WP filters (wp_head … Read more