powered by Jive Software

File upload with Candy 2.2

I cannot find out how to add the the file upload to candy. I have seen it done, and I have the plugin for httpupload, but how do i get the icon on my candy installation and make if functional?

Anyone done this?

I have not tried this myself yet, but if I read Dele’s post correctly, you need two plugins:

Yes I have it working by adding these lines to my index.html (as well as the supporting files):

       <script type="text/javascript" src="candyshop/colors/candy.js"></script>
       <link rel="stylesheet" type="text/css" href="candyshop/colors/candy.css" />
       <script type="text/javascript" src="candyshop/upload/candy.js"></script>
       <link rel="stylesheet" type="text/css" href="candyshop/upload/candy.css" />

And the inits:


I added the colors also, because, why not? :slight_smile:

1 Like



I just wanted to be more explicit for others trying to add this plugin to their installs…

I use Ubuntu so my instructions will be for this, for Windows, it will be much easier.

  1. cd /usr/share/openfire/plugins/candy/classes
  2. mkdir candyshop
  3. mkdir candyshop/upload
  4. cd candyshop/upload
  5. nano candy.css

Copy the contents of this file into the one you just made.

  1. Save the file candy.css

  2. nano candy.js
    Copy the contents of this file into the one you just made.

  3. Save the file candy.js

  4. wget ‘https://raw.githubusercontent.com/igniterealtime/Pade/master/extension/groupchat/candyshop/upload/paperclip.png

  5. cd /usr/share/openfire/plugins/candy/classes

  6. sudo chown -R www-data:www-data candyshop

  7. nano index.html

  8. Add these two lines of code:

  1. Also add CandyShop.Upload.init(); below Candy.init( config.endpoint, config); Looks like this:
        $( document ).ready( function()
            var config = {};
            $.getJSON( 'config.json', function ( config )
                Candy.init( config.endpoint, config);

  1. Save the file index.html
  2. Restart openfire: sudo service openfire restart