WordPress.org

Ready to get started?Download WordPress

Forums

Hacks -- must be redone with each version? (5 posts)

  1. ThatAdamGuy
    Member
    Posted 10 years ago #

    Help me understand WP hacks, please.
    With MT, for the most part, hacks (or plugins) are pretty convenient. Drop a file into a directory, and that's pretty much it most of the time.
    But with WP, it seems like you're changing the actual program code. Doesn't this mean that you'd have to redo all your hacks each time there's a WP program update?
    Thanks in advance for helping me get my head around the whole hacks concept :)

  2. Laughinglizard
    Member
    Posted 10 years ago #

    TAG: That would really depend on the hack or modification being implemented. Most of the hacks that you see on here do not necessarily need to be completely redone. Starting with 1.0, there is the concept of a my-hacks.php file which contains all the new code of the hacks. In order to add the hack to your WordPress, copy the included function(s) into your my-hacks.php This file is never included in the installation and thus never gets overwritten or updated in case of a complete WP application update. In order for the added hack to work (after you have put it in your my-hacks.php), you have to add very small function calls inside the index.php (or other files). On performing a complete update of the program, these function calls will have to be put back in. and the hacks will work again, my-hacks.php stays intact. (Unless there is major file and/or function renaming, which should not happen for a long time)
    Peace

  3. ThatAdamGuy
    Member
    Posted 10 years ago #

    Ah, that makes sense! Thanks for helping me understand how that works :)

  4. ThatAdamGuy
    Member
    Posted 10 years ago #

    Ack, just realized that this means that downloading, installing, and hacking nightly builds is probably not for the un-busy. Bummer.

  5. Nick Momrik
    Member
    Posted 10 years ago #

    Yeah, I used to do that, but since 1.0.1 Miles was released I haven't downloaded a nightly or from the CVS. Everything is running smoothly for now and I am not wishing for any features that I don't have, so 1.0.1 Miles will do until the next full release is made available.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.