“Multi-Thumbs v1.2.2” Documentation by Nikola Radojevic v1.1


“Multi-Thumbs”

Version: 1.1
Created: Mar 3rd 2014
By: Nikola Radojevic
Email: support@diwave-coders.com

Thank you for purchasing this WordPress plugin! If you have any questions that are beyond the scope of this help file, please feel free to email me via contact form here. Thanks so much!


Table of Contents

  1. Installation
  2. Basic Use
    1. Adding images to posts and pages
    2. Shortcodes
  3. For Developers
    1. Integration (API)
    2. Shortcode Customization
  4. Compatibility
  5. Frequently Asked Questions (FAQ)
  6. Sources and Credits

A) Installation - top

To add a WordPress Plugin using the built-in plugin installer:

  1. Go to Plugins > Add New.
  2. Under Upload tab, click on "Choose File" and choose di-multi-thumbs.zip from your hard drive.
  3. Click Install Now to install the di-multi-thumbs.
  4. A popup window will ask you to confirm your wish to install the Plugin.
  5. If this is the first time you've installed a WordPress Plugin, you may need to enter the FTP login credential information. If you've installed a Plugin before, it will still have the login information. This information is available through your web server host.
  6. Click Proceed to continue with the installation. The resulting installation screen will list the installation as successful or note any problems during the install.
  7. If successful, click Activate Plugin to activate it, or Return to Plugin Installer for further actions.

To add a WordPress Plugin using FTP:

  1. Login to your hosting via your FTP client.
  2. Navigate to your WordPress plugin directory (usually it's wp-content/plugins)
  3. Extract di-multi-thumbs.zip and copy di-multi-thumbs folder to plugin directory on your host.
  4. Login to your WordPress Admin dashboard and go to Plugins page.
  5. You should now see Multi-Thumbs in the list of plugins. Click Activate Plugin to activate it.

B) Basic Use - top

1) Adding images to posts and pages

Adding Multi-Thumbs images to your post or page could not be simpler. All you have to do is to click "Add New" button in "Multi-Thumbs" box once you are in post edit page and simply add as many images as you want.
You can select multiple images at once by holding CTRL key while selecting images you want to add. Drag images to re-order them. Once you display them in front-end, they will be listed in that order.

2) Shortcodes - top

We have built few shortcodes that can be used in templates for easier integration and customization, such as:

[dimt_slider] - top Display a nice slider with Multi-Thumbs images.
Example:
[dimt_slider active=4 showThumbs=true]
will produce something like this:
[dimt_carousel] - top Display carousel with Multi-Thumbs images.
Example:
[dimt_carousel fluid=true visible=5 showNav=true]
will produce something like this:
[dimt_grid] - top Display multipurpose grid of Multi-Thumbs images for many purposes such as gallery grid, portfolio etc.
Example:
[dimt_grid per_row=5 thumbnailSize='thumbnail']
will produce something like this:
[dimt_thumb] - top Display <img> element of one image from Multi-Thumbs.
Example:
[dimt_thumb size='full']
will produce something like this:
[dimt_thumb_src] OR [dimt_thumb_url] - top Return source url of one image from Multi-Thumbs. You can use any of above shortcodes, whatever is easier to remember.
Example:
[dimt_thumb_src size='thumbnail']
will return something like this:
http://your_domain/wp-content/uploads/2014/03/71-80x80.jpg

B) For Developers - top

1) Integration

We built this plugin mainly to give developers fast and easy solution for manipulating with specific post images that can be used in every situation. With that being said, we are providing you with simple, but powerful API that will ease your work.

Below you will find Multi-Thumbs PHP functions that you can use in your templates:

FunctionReturns
Check if post has at least 1 Multi-Thumbs image attached
If post_id is not provided, current post ID will be used instead.
dimt_post_has_thumbs(
    int post_id = null
);
bool
Get Multi-Thumbs array of images
If post_id is not provided, current post ID will be used instead.
dimt_get_thumbs(
    string size = 'thumbnail',
    int post_id = null
);
If thumbs were found, an multidimensional array will be returned:
array(
    0=>array(
        'id'=>int,
        'url'=>string,
        'caption'=>string,
        'title'=>string,
        'description'=>string,
        'alt'=>string
    ),
    ...
);
        
If nothing was found, bool FALSE will be returned.
Get single Multi-Thumbs image
If post_id is not provided, current post ID will be used instead.
dimt_get_thumb(
    int index = 0,
    string size = 'thumbnail',
    int post_id = null
);
If thumb was found, an key=>value array will be returned:
array(
    'id'=>int,
    'url'=>string,
    'caption'=>string,
    'title'=>string,
    'description'=>string,
    'alt'=>string
);
        
If nothing was found, bool FALSE will be returned.

2) Shortcode Customization - top

You can edit shortcode templates by simply copying shortcode template files into your theme directory. Once you start editing template files, you can refer to useful comments in files to apply your changes easier.

Modifying template files:

  1. Slider - [dimt_slider]
    To edit dimtSlider template, go to plugin template directory (wp-content/plugins/di-multi-thumbs/templates/shortcodes) and copy slider.php to wp-content/themes/your_theme/di-multi-thumbs/slider.php
  2. Grid - [dimt_grid]
    To edit grid template, go to plugin template directory (wp-content/plugins/di-multi-thumbs/templates/shortcodes) and copy grid.php to wp-content/themes/your_theme/di-multi-thumbs/grid.php
You will find customCycle and customPrettyPhoto in shortcode templates. This is where you can add custom settings for jQuery.cycle and jquery.prettyPhoto plugins.

Filters

[dimt_thumb] You can apply 2 filters to this shortcode:


D) Compatibility - top

Multi-Thumbs was made using PHP 5.3 and WordPress 3.8 , but since it uses common WordPress API and PHP functions, it might work on older versions as well, but there's no guarantee.

Recommended requirements for Multi-Thumbs v1.0:


E) Frequently Asked Questions (FAQ) - top

Here you can find all frequently asked questions and their answers:

  1. "Multi-Thumbs" box is not present in post editing page?
    Please make sure you have "Multi-Thumbs" option checked in "Screen Options" tab found at the top-right corner of the page.

Your question is not in the list? Feel free to create new ticket on our website.


Once again, thank you so much for purchasing this plugin. As I said at the beginning, I'd be glad to help you if you have any questions relating to this plugin. No guarantees, but I'll do my best to assist. If you have a more general question relating to the plugins on CodeCanyon, you might consider visiting the forums and asking your question in the "Item Discussion" section.

Nikola Radojevic ( DiWave )

Go To Table of Contents