Planning for a free/premium plugin


I’m an old Delphi programmer who’s writing php plugins for WordPress. In Delphi I could write code for both a free and premium version in the same code using IFDEF.

    Do this if the version is pro.
    Do this if the free version.

I understand because Delphi creates a compiled executable that something like this isn’t possible in PHP. But, this is what I’m trying to accomplish instead of having to go back and rip the pro version apart and create an entirely separate project.

How is this best handled to reduce the amount of code needed to be maintained?

I’m using NetBeans.


uPrompt 2 months 0 Answers 12 views 0

Leave an answer