Geeklog provides a very rich set of integration API's (application programming interface) that Media Gallery takes advantage of to create a truly integrated system which offers a tremendous flexibility for the web site administrator. The Geeklog Development team did an excellent job of building a foundation that plugin authors can use to both simplify the coding process and provide a tightly integrated solution. The following section will detail some of these integrations in more detail.
Media Gallery takes full advantage of the Geeklog comment engine, allowing your site users to leave comments on your media items (if you have enabled comments in the album attributes). Since Media Gallery uses the Geeklog comment engine, all the protections provided by the Spam-X plugin to prevent comment spam are also enforced in Media Gallery. Also, the speed limit restriction (only allowing comments to be posted every XX seconds) is used in Media Gallery.Media Gallery takes full advantage of the Geeklog comment engine, allowing your site users to leave comments on your media items (if you have enabled comments in the album attributes). Since Media Gallery uses the Geeklog comment engine, all the protections provided by the Spam-X plugin to prevent comment spam are also enforced in Media Gallery. Also, the speed limit restriction (only allowing comments to be posted every XX seconds) is used in Media Gallery.
Media Gallery fully supports Geeklog's auto tag feature. These are tags that are embedded in an article / story that are processed when the article / story is displayed. Auto tags are one of the most talked about features of Geeklog / Media Gallery. They can be used to give simple integration of audio and visual components to your Geeklog stories, static pages, forum posts, etc.
All auto tags are immediately followed by either a media ID or an album ID. Many auto tags support additional parameters to help you control the look and feel of the resulting integration.
Auto tags also honor album permission settings. If a user does not have the permission to view an album, any auto tags referencing that album or its contents will not be displayed to that user. The only exception to this rule is the global Login Required setting. If you have enabled the Login Required setting, all auto tags will display even though an anonymous user cannot view the album.
Media Gallery also supports a couple of special features when it comes to auto tags. By default, Media Gallery will alternate the alignment of the thumbnails from left to right throughout your articles. If you prefer to specify a right, left or no alignment, you can use the align: parameter to force the alignment to your preference.
The album auto tag will create a thumbnail image using the album cover. This auto tag can only use the thumbnail image.
| Parameter | Description |
|---|---|
| width:## | sets the width of the thumbnail image to ## px wide |
| height:## | sets the height of the thumbnail image to ## px high |
| align:left, right, auto or none | Determines the alignment for the auto tag, valid options are left to align left, right to align right, auto to have Media Gallery alternate alignment right/left and none for no align. |
| linkid:## | If linkid: is specified, the album auto tag will link to the media item specified with the linkid: parameter. Omit the linkid: parameter to have the album auto tag link to the album view. |
| border:0/1 | 1 places a border (frame) around the thumbnail 0 will disable the border |
| link:0/1 | 1 enables the thumbnail having a link to the album. 0 disables the hot-link, instead the album cover thumbnail will be displayed with no link. |
| caption | any text before the closing ] will be used as the caption for the image |
Example:
[album:8 width:200 height:200 align:auto border:1 link:1 A sample album auto tag]
This example will place the album cover thumbnail in the story using a height/width of approximately 200×200 pixels. Media Gallery will preserve the aspect ratio of the image, so the size may not be exactly 200×200 but it will not be any larger than 200×200. The alignment of the thumbnail will be automatically alternated between right and left depending on the other auto tags in the story, it will have a small border around it and will be hotlinked to the album view. The caption will display below the thumbnail.
The media auto tag is the general purpose auto tag, it will work with each any of media. For audio and video media, it will display the attached thumbnail or the generic media thumbnail if there is no attached thumbnail. For image media, it will display the media items thumbnail.
| Parameter | Description |
|---|---|
| width:## | sets the width of the thumbnail image to ## px wide |
| height:## | sets the height of the thumbnail image to ## px high |
| border:0/1 | 1 places a border (frame) around the thumbnail 0 will disable the border |
| align:left, right, auto or none | Sets the alignment for the auto tag, valid options are left to align left, right to align right, auto to have Media Gallery alternate alignment right/left and none for no align. |
| src:orig, disp or tn | Specifies which image to use as the source, the original image (full size), the display image or the thumbnail. If no src option is given, the thumbnail image is used by default. |
| alt:0/1 | 1 will use the alternate URL of the media item for the href link 0 will link directly to the media item - set the alternate URL in the Media Edit Screen |
| caption | any text before the closing ] will be used as the caption for the image |
Creates a raw <img> tag of the media item with an optional link to that media item. The img: auto tag does not support any formatting beyond the thumbnail size and alignment. The purpose of this auto tag is to give you the ability to place a raw HTML <img> tag in your story. Also, the img: auto tag does not provide a link to the original image.
| Parameter | Description |
|---|---|
| width:## | sets the width of the thumbnail image to ## px wide |
| height:## | sets the height of the thumbnail image to ## px high |
| align:left, right, auto or none | Sets the alignment for the auto tag, valid options are left to align left, right to align right, auto to have Media Gallery alternate alignment right/left and none for no align. |
| src:orig, disp or tn | Specifies which image to use as the source, the original image (full size), the display image or the thumbnail. If no src option is given, the thumbnail image is used by default. |
This places a MP3 jukebox into your story. It will contain a playlist of all the MP3 media in the album.
| Parameter | Description |
|---|---|
| align:left, right, auto or none | Sets the alignment for the auto tag, valid options are left to align left, right to align right, auto to have Media Gallery alternate alignment right/left and none for no align. |
| autoplay | If set to 1 the video will automatically begin playing, if set to 0, the user will need to press the play button to begin playing. |
Places a small (200×200) video player in the article/story for media_id= and auto starts the video playing. The video auto tag can be used to embed any video item from Media Gallery into a story. This includes remote video such as YouTube videos.
| Parameter | Description |
|---|---|
| width:## | Specifies the width of the video player in pixels |
| height:## | Specifies the height of the video player in pixels |
| align:auto, right, left, none | Specifies the alignment of the video player in the content. - auto will use MG's automatic alignment - right will be right aligned - left will be left aligned - none will not use any alignment (the content will not wrap around the video player |
| autoplay:0/1 | If set to 1 the video will automatically begin playing, if set to 0, the user will need to press the play button to begin playing. |
NOTE: You cannot change the width / height of embedded remote video files, the size is controlled by the embed string you specified when the video was added to Media Gallery. In this case, the width / height parameters are ignored.
Places a small (15×200 no thumbnail or 200×200 with thumbnail) audio player in your story. If there is an attached thumbnail to the audio item, it will be displayed above the player controls.
| Parameter | Description |
|---|---|
| align:auto, right, left, none | Specifies the alignment of the audio player in the content. - auto will use MG's automatic alignment - right will be right aligned - left will be left aligned - none will not use any alignment (the content will not wrap around the audio player |
| autoplay:0/1 | If set to 1 the audio will automatically begin playing, if set to 0, the user will need to press the play button to begin playing. |
Allows for media items or any item stored in an album to be downloaded by the user.
| Parameter | Description |
|---|---|
| caption | any text before the closing ] will be used as the caption for the image |
Places a text link to a media item - No thumbnail is used.
| Parameter | Description |
|---|---|
| alt:0/1 | 1 - use the media items alternate URL if defined. 0 - Link directly to the media item. Set the alternate URL in the Media Edit screen. |
| href text | any text before the closing ] will be used as the href text |
Places a thumbnail image of the specified media item (using media id ). This does not put a link, only the image. The caption, if specified, will display below the image.
The use of the image: auto tag is depreciated, please use the media: auto tag instead.
| Parameter | Description |
|---|---|
| width:## | sets the width of the thumbnail image to ## px wide |
| border:0/1 | 1 places a border (frame) around the thumbnail 0 will disable the border |
| align:left, right, auto or none | Sets the alignment for the auto tag, valid options are left to align left, right to align right, auto to have Media Gallery alternate alignment right/left and none for no align. |
| src:orig, disp or tn | Specifies which image to use as the source, the original image (full size), the display image or the thumbnail. If no src option is given, the thumbnail image is used by default. |
| link:0/1 | 1 places a link to the display image, 0 will disable linking to the original image. |
| caption | any text before the closing ] will be used as the caption for the image |
Creates an 'original' image, this will use the originally uploaded image so the size can be much larger than the standard thumbnail.
The use of the oimage: auto tag is depreciated, please use the media: auto tag.
| Parameter | Description |
|---|---|
| width:## | sets the width of the thumbnail image to ## px wide |
| border:0/1 | 1 places a border (frame) around the thumbnail 0 will disable the border |
| align:left, right, auto or none | Sets the alignment for the auto tag, valid options are left to align left, right to align right, auto to have Media Gallery alternate alignment right/left and none for no align. |
| caption | any text before the closing ] will be used as the caption for the image |
The Album ID is displayed (only for Administrators only unless you enable Enable Media ID Display) on the Album View page in the lower left hand corner. The Album ID is also displayed in the URL, it is the aid parameter passed in the URL when you are viewing an album. Look in your browsers address bar to see it or look at your browsers status bar when you mouse over an album from the main album page.
The Media ID is displayed (only for Administrators only unless you enable Enable Media ID Display) on the Image Detail page in the left footer.
If you do not like the box drawn around the images, or what to tweak the look and feel to better fit your site, you can edit the autotag.thtml template file in the plugins/mediagallery/templates/ directory. This controls how the embedded image will look.
Media Gallery v1.5 fully supports Geeklog's auto link features. This allows you to embed auto tags from other plugins into the title and descriptions of any album or media item. Auto link support is automatic and there are no configuration options necessary.
Media Gallery is fully integrated with Geeklog's statistics engine. There is nothing special you need to do to take advantage of this feature. When a user displays the Site Statistics in Geeklog, Media Gallery will report the total number of images in the system , the Top Viewed images and the Top Ranked (if ranking is enabled) images.
Media Gallery is fully integrated with Geeklog's search engine. There is nothing special you need to do to take advantage of this feature. You should note, that is a media item does not have a caption; Media Gallery will use the Album Title when displaying the search results.
Media Gallery also has its own search system, which adds additional features over the standard Geeklog search. Media Gallery's search allows you to specify a specific category and also search keywords.
Media Gallery is fully integrated with Geeklog's What's New block. This feature can be disabled in the Media Gallery Systems Option screen.
If comments are enabled for Media Gallery, any new comments to media will also be included in the What's New listing.
Special Consideration for What's New Listing
If you enable the What's New listing, Media Gallery will attempt to pull all the new comments for your media to list in the What's New listing. This can be a very resource intensive operation. Basically, what goes on behind the scenes on your server is that the database engine will actually create a temporary copy of the comments database table and scan each individual record in that file. This can be a large load on your server if you have hundreds and hundreds of comments. It has also caused disk space issues on some hosting companies because they do not allocate much space for the temporary tables that are created.
Because this feature can be very resource intensive, there is a method to disable pulling the new comments, but leaving the new media items listing intact. To disable Media Gallery from trying to retrieve the new comments, check the check box for Disable What's New Comments in the System Options configuration screen.
Just like Geeklog's Featured Article, you can also feature an album. If an album is featured, it will display on the homepage (or whatever topic page you specify) either before or after the stories for that page. Media Gallery offers additional functionality over how Geeklog's featured stories by allowing you to specify a different featured album for each Geeklog topic.
To make an album featured turn on the Featured Album attribute in the Album Edit screen and select the topic and location for the album to display.
When Media Gallery is installed, it automatically creates a Random Image block in the Geeklog blocks system. This block is disabled by default and can be enabled by turning it on through Geeklog's Blocks Administration.
The Random Image Block will show a random image from your albums, changing each time the page reloads and providing a direct link that the album where the image resides.
Media Gallery also integrates with Geeklog's User Profile system, displaying the last 5 media items uploaded by that user and any albums that the user owns. If a user has not uploaded any media and does not own any albums, nothing will be displayed on the user profile page.
This feature can be turned on / off by setting the Display MG Info in User Profile option in Media Gallery's System Options configuration screen.