Some questions about prefixes and global variables


My item was soft rejected because this:

  1. All global variables should be within a function or class.

  2. Please use a unique prefix for all function names, custom images sizes, classes, hooks, public/global variables, and database entries to avoid conflict issues with plugins and other themes. For example, themename_ OR frameworkname_ OR authorname_themename_.

I had found some little prefix issues at my own code (already fixed it) but I am wondering this:

I am using TGMPA to active some plugins so:
Do I need to add my authorname_themename_ prefixes over the TGMPA prefix or this is enough

Is this a problem ?

Also I am using Envato Theme Updater which is made by @Pixelentity same questions like TGMPA is this enough :

I will be really grateful if someone shares his opinion about those problems.


Have you got your answers from the review team? Would be so kind and share with us if you have the answers? Thanks in advance!

authorname and themename

these words are a like variables
you can use your author name not the word authorname and you can use your theme name not themename word

if you did this, i think this is the best solution for you

@bbioonThemes This wasn’t my question but I found the problem anyway :slight_smile: it was a small mistake in authorname

1 Like