HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

How to install a plugin/addon/theme

R_JR_J Ex-FanboyMunich Admin

There are several reasons why installing a new plugin/addon/theme can fail. I don't think there is a comprehensive overview of what an admin can do when problems arise...

1. Target Folder Structure

Plugins

Note: in some older plugins the main plugin file might be named default.php. That is perfectly okay and no reason for any worries.

When you download a plugin you have to unzip it and move its content to the /plugins folder.
The file structure afterwards must read: /plugins/somePluginsName/class.somepluginsname.plugin.php

When you end up with /plugins/class.somepluginsname.plugin.php or /plugins/somePluginsName-1.0.0/somePluginsName/class.somepluginsname.plugin.php you have done something wrong and you will never be able to enable the plugin.

Addons

Addons must be unzipped to the /applications folder. Check if you can find /applications/someApplicationsName/settings/about.php

If there is one more folder or one folder less in that structure, you've messed something up.

Themes

All files must be directly unzipped to the /themes folder and all themes have an about.php file in their root folder. So you can check if you have unzipped it correct if the path to the new theme looks like that /themes/someFancyTheme/about.php

2. Target Folders Name

Note: upper-/lower case is important!

Although most plugins/addons/themes can be enabled even if the folder isn't named correct, they most probably can not be disabled when the folder isn't spelled exactly how it has to be. CSS and JavaScript files might not be loaded correct, so it is really important that the plugin/addons folders name is written 100% correct.

If you unzip what you have downloaded, the folder name will in almost all cases already match, so this paragraph is only useful for trouble shooting.

Open the plugin/the about.php file. Depending on what you look at, one of the first lines of code would look like that

  • $PluginInfo['somePluginName'] = array(
  • $ApplicationInfo['someAddonName'] = array(
  • $ThemeInfo['someThemeName'] = array(

The key of the array (the "someName" part) is how you would have to name the folder. If it is all lower case, your folder must be all lower case, if it is all mixed case, the folder must reflect that, too.

3. Enabling

Uploading a plugin/addon/theme doesn't change your forum. You have to enable it first in the dashboard.

3.1 Errors When Enabling

Enabling a plugin/addon/theme ("extension") throws an error. There are some things you could solve by yourself, but normally you are lost:

  • If the extension requires another extension, enable that extension first.
  • If the extension throws a "Vanilla version x.y required" error, you can try to change a line in the PluginInfo array that begins with "RequiredApplications", but there is no guarantee that it will work
  • Try to disable all other plugins, addons and revert to the default theme and retry to enable ths extension
  • Visit the addon page here at the community and click on the "Ask a Question" button. Describe your problem as good as you can and give information which theme and plugins you are using and what you have tried by now to solve the problem. Afterwards wait patiently...
  • If enabling a theme fails, make sure the folder of the current theme is spelled correct

3.2 Plugin/Addon/Theme is Not Visible

Although an extension has been uploaded to the correct path, it might not be included in the list of available plugins/addons/themes in the dashboard. The reason is, that the info in the header of an extension is cached. The only thing you have to do is to invalidate the cache so that it is renewed and the new extension will be included in the list.

But invalidating that cache isn't always easy.

  • If you are using memcached, restart the memcached service. If you don't know if you are using memcached, I'm convinced you do not use it.
  • Look in the /cache folder. There should be a file called addon.php which caches information about plugins and addons and a theme-index.php file which holds information about the available themes. Delete the file you need (or even both if you are unsure) and refresh the plugins/addons/themes list

If something unpredictable is going on, your extension still might not be included in the list. There is one thing you can do, but it could temporarily create an error message in your forum, for a few seconds only and it is not said that there really would be an error message, but at least it could happen. Nevertheless the process itself isn't dangerous.

  • Make a backup of the /conf/config.php file
  • Open that file in an editor
  • If you have a problem with a plugin, search for a line like $Configuration['EnabledPlugins']['somePluginsName'] = false;. If you find that line, you simply have been too dumb to see the plugin in the list. Go and open the list again. The plugin is contained in the list. You just have to search harder.
  • If the entry is not present in the config file, add it to the bottom. Change false to true and quickly(!) do the next steps.
  • Open your forums dashboard, go to the plugins page, refresh it and you would see the plugin now. Disable it! Yes, that is an important step, disable it. Now you can enable it the normal way. The reason why you should disable and re-enable it is, that some plugins do some extra actions when they are enabled through the dashboard. When you enable them manually they skip this extra step and might not work correct

4. Disabling Fails

Check "2. Target Folders Name"

Comments

  • whu606whu606 I'm not a SuperHero; I just like wearing tights... MVP

    Thanks again, @R_J for your continued generosity in sharing your knowledge in a clear and helpful way. :awesome:

  • Where and how can i upload a theme to my forum?

  • Thanks for this amazing job!

  • Goods for all.

    i hope all of you can help me.


    i have self host for vanilla 3.3 forum

    i installed by softaculos

    i already start

    my biggest problem is that i cant install a new theme or an extra addon


    can you explain me if i was a donkey how can i install a new addon and how install a new theme


    i want but the system doesnt help.




    thank you a lot

  • i doesnt understand the turturial

    can anyone helps me

  • R_JR_J Ex-Fanboy Munich Admin

    If you describe what you did, I can try to tell you where you need to change something to make it work.

  • I dont do nothing, simply doesnt soprar da options to install new addons...

    Can you help me or Antone help me explain to me the process, step by step

    Thanks you

  • R_JR_J Ex-Fanboy Munich Admin

    Process depends a little bit on what you donwload: a plugin, an addon or a theme.

    1. download that zip
    2. extract it to a folder
    3. copy that folder to your web host


    Given that you want to install a plugin and that plugin you have downloaded is in a zip file called "example.zip" and includes a file "class.example.plugin.php". That plugin file should then be in a folder structure:

    "/plugins/example/class.example.plugin.php"

  • why is so hard to install a simple plugin , i dont even know how to install a new language

Sign In or Register to comment.