Give me a bit to poke around - I somehow managed to install your premium plugin with the "other" one that had no integrated payment and somehow they still work together.
My first guess at it would be to hook in to the "enable theme for one user" kind of function, attaching it to a new sort of package. (stating the obvious there, probably)
Does that function have a hook? I looked at it earlier, and since I last played with themes they've changed several things.
There used to be an additional field that would get picked up when loading a theme, but it seems that isn't the case any more. It makes me wonder if it wasn't some wp.com kinda code, as it wasn't exactly something that would be valuable in wp by itself.
7430 pointsLike some sort of WPMU DEV GodMindblowingly helpful memberLifetime member
Erstwhile founder
—
22nd January 2008 (4 years ago)
#
Looks like the magic function is "wpmu_get_blog_allowedthemes" in wp-admin/includes/mu.php. Apparently the blog option "allowedthemes" is what we need to be playing with.
Responses (4)
Erstwhile founder — 22nd January 2008 (4 years ago) #
I'm more than happy to code this one if someone has any ideas on how it could be done.
Thanks,
Andrew
— 22nd January 2008 (4 years ago) #
Give me a bit to poke around - I somehow managed to install your premium plugin with the "other" one that had no integrated payment and somehow they still work together.
My first guess at it would be to hook in to the "enable theme for one user" kind of function, attaching it to a new sort of package. (stating the obvious there, probably)
Member — 22nd January 2008 (4 years ago) #
Does that function have a hook? I looked at it earlier, and since I last played with themes they've changed several things.
There used to be an additional field that would get picked up when loading a theme, but it seems that isn't the case any more. It makes me wonder if it wasn't some wp.com kinda code, as it wasn't exactly something that would be valuable in wp by itself.
Erstwhile founder — 22nd January 2008 (4 years ago) #
Looks like the magic function is "wpmu_get_blog_allowedthemes" in wp-admin/includes/mu.php. Apparently the blog option "allowedthemes" is what we need to be playing with.
Thanks,
Andrew
Become a member