• Newbie coder wanting some advice!

    I want to make a plugin.
    I thought I would take inspiration by looking at existing plugin code…
    I chose something fairly simple.
    I looked at 2 plugins. OMG.
    There’s a TON of code in there!!

    I’m guessing the developers coded using an IDE that gave them loads of files and folders when they made a new project.

    Just wanted some general advice on how I can read and understand the code and ignore unnecessary files and folders? Or… is that a ‘how long is a piece of string question‘?

    I’m a jack of all trades – plenty of coding experience behind me… but not hard core and never mastered any one language.

    The plugins that I looked at… I honestly would be better off starting from scratch and writing my own spec and developing myself with the help of a more experienced coder maybe. But then I thought… surely not… surely I should have plenty to learn from existing code?

    QUESTION: What IDE’s would be used to develop PHP plugins?

    Just looking for advice? 🙂

    Thanks.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    Start poking around in the developer docs at https://developer.wordpress.org/

    I started my plugins journey with this plugin:
    https://wordpress.org/plugins/wp-csv-to-database/ Author: Ruhul Amin

    Thread Starter OM2

    (@om2)

    Thanks guys for both replies
    I’ll follow up those links
    Seems as though my course of action is to:

    – Learn WP
    – Make my own code! 🙂

    Moderator bcworkz

    (@bcworkz)

    – Learn WP
    – Make my own code!

    It’s not a sequential process IME. You’ll go back and forth between the two. Learn a little more of WP. Extend your coding knowledge. Rinse and repeat.

    A lot of plugins are very structured. Good for maintenance, less useful as a learning device. I suggest pushing your own efforts as far as you can without worrying about other plugin code. Only when you get stuck and aren’t sure how to do something is when studying other plugins becomes most useful. Then your task is to find the relevant code among all the other structure. Once found you can maybe make sense of that one segment without needing to understand the rest of the plugin.

    Thread Starter OM2

    (@om2)

    @bcworkz thanks for the reply.
    I can ‘hack’ a plugin and find or change something or some functionality.

    My big gripe was trying to understand code of plugins that I assumed would be super simple. I’ll follow your excellent advice though. 🙂
    Thanks.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Need help reading code’ is closed to new replies.