• I decided to learn building theme, have the ability to make modifications to themes i use, or even write plugins later. Basically to do anything necessary to make wordpress do what I want whatsoever.

    Now a very general question. When doing such things, we do not ever mess with the core wordpress code in the wp-admin and wp-includes folders right? Almost nobody does that except those wizard guys who keep updating wordpress itself right? All we are doing is under wp-content folder correct? Would there be any reason to try to learn the core wordpress code under wp-admin and wp-includes folders and to modify them? I also mean do we need to understand how that code works to write themes or plugins?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hi,

    Wordpress already has a training section for learning building themes and plugins. You can simply refer to this link for learning building themes they have amazing articles there for this ( https://github.com/wptrainingteam/learn-theme-beta ). You can also refer to this code for more topics related to building themes and plugins ( https://github.com/wptrainingteam ).

    Thread Starter ketanco

    (@ketanco)

    this is not answer to my questions though… I didnt ask where to look to build themes. My questions were exactly as I wrote. please can someone read my questions and answer?

    You wouldn’t normally mess with the WordPress core files but…

    You might extend and /or enhance what core does through plugins and/or theme functions. Quite often code and functions suggested by plugins and sometimes theme functions will find its way into the core WordPress to enhance the system.

    That said, you might find the WordPress core perfect for building something else upon or a different CMS with your philosophies driving its capabilities. Being a GPL licensed Open Source CMS system you might one-day ‘fork’ WordPress into something totally different.

    Rewriting the WordPress core will make your system vulnerable to reversions during updates but there are ways to mitigate that problem if you need to do so.

    WordPress is yours to use, extend, and enhance as you see fit.

    The documentation referenced by @ritikasolanki and the rest of the documentation written by the users of WordPress are guides to some of the considerations you might find and present the philosophy behind Open Source and WordPress. Reading and referring to those guides as you go might help you as you proceed with making WordPress your own.

    Thread Starter ketanco

    (@ketanco)

    Thanks,
    When you said:
    Quite often code and functions suggested by plugins and sometimes theme functions will find its way into the core WordPress to enhance the system.

    you did not mean, when we write plugin or theme we must modify or even know the core wordpress code correct?

    What do you mean exactly by “find its way”?

    All we are doing is under wp-content folder correct?

    Yes

    Would there be any reason to try to learn the core wordpress code under wp-admin and wp-includes folders and to modify them? I also mean do we need to understand how that code works to write themes or plugins?

    The reason you might want to learn how the core code works is so that your theme or plugin can integrate well with it, not to modify core code. You can write code that works externally and then adapt it to be called by WordPress. You have to learn which actions and filters to use to make things happen, and the order in which events fire so that your code is executed at the right time.
    Themes are easier, and mostly have a small set of functions to use to output the front end pages, but there are several actions and filters even in themes that need to be right or the theme doesn’t work.
    Plugins can do pretty much whatever they want, but they are only loaded at a certain point in the page request, so there is still coordination needed.

    What do you mean exactly by “find its way”?

    What Jeff meant was that some enhancements are explored in a plugin that is then incorporated into the core code. Some things are coded for years in themes and then someone realizes that it would be better for core to handle that instead. The core code evolves, and some of it comes from the community of plugin and theme authors.

    • This reply was modified 4 years, 11 months ago by Joy.
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Where to focus when building theme or making changes’ is closed to new replies.