Sign Up! Login: Password: New User? Forgot? Support
Top Mods!
Wowhead Search
by sonofsamedi
Digital Clock
by Wolfar15
Admin Forums
Welcome to the GuildPortal Help Community! These forums are for admin-to-admin help.
Available Forums
Forums : Pimp My Site! > Mottie help! Image gallery
Jin'aya (Guild Admin) 8/10/2009 5:35 AM EST : Mottie help! Image gallery
Jin'aya
Posts: 39
Becoming Adept!

Its Me, its Rhiannananananana, i am back and playing admin for a new guild

*stomps up and places large box of irritating problems on the desk* Right!

This page causing me the brain ache today

http://www.guildportal.com/Guild.aspx?GuildID=324821&TabID=2723132&PageName=Gallery

Basically, what i'd like to achieve is a scrolling image gallery but with full size images, not the thumbnails. or a way of adding a next and previous to the Random Catagorised Image.

I like the built in image gallery a lot as it allows members to add their images too, but my only problem is the current size of the images as it is the 'main feature' of that page rather than something shoved in a side box if you see my problem.

Help *crys pitifully in the corner*

./Jin'aya

edit: they dont have to be the full size images, perhaps just some way of defining the size of the thumbnail so its not 'tiny-by-tiny'

This will be a signature....
>My SWCWikia Page<
TopBottom

Mottie (MVP) 8/10/2009 12:19 PM EST : RE: Mottie help! Image gallery
GuildPortal MVP
Mottie
Posts: 3884
Zomgawsh Poster

Hi Jin'aya!

YAY for being an admin! o.O

LOL anyway, I messed around with the code and I think this should work. Make sure you add this code BELOW your gallery.
<script type="text/javascript">
$(document).ready(function(){
 var minimumHeight = 500;
 var maximumWidth = 1000;
 $('#imgPlaceDiv').css({ 'min-height':minimumHeight, 'height':'', 'width':'' });
 $('#imgWrapperAnchor').css({ 'max-height':'', 'max-width':'' }).attr('title','');
 $('#imgGalleryImage').css({ 'max-height':'', 'max-width':maximumWidth }).unbind();
 $('#imgCaptionDiv').css({ 'text-align':'center', 'width':'' });
})
var showGalleryImage = function(sGalleryImgPath, sDescription) {
 $('#imgGalleryImage').fadeOut('slow', function(){
  $('#imgGalleryImage').attr('src', sGalleryImgPath).load(function(){
   $('#imgGalleryImage').fadeIn('slow');
   $('#imgCaptionDiv').html(sDescription);
  });
 });
}
</script>
Some notes about this script:

  • It removes the size limits on the image gallery, but I added some variables (these won't work with IE, I don't think):

    • You can set the minimum height (minimumHeight) of the image area (when the image fades completely out, the box collapses to this height).

    • There is also a maximum width (maximumWidth) for those images that are so large they bump out your content box sides.

  • The image now fades out like it should, but now will not fade back in until the image is completely loaded - it used to flicker out then in, then just replace the image.

  • You can no longer click on the image to open a larger size.

  • Hovering over the image, no longer pauses the gallery - I can add this back in if you want.

  • You have no control over the image displayed... it's random and will always be 8 seconds between images - I can let you control this with some additional coding.
TopBottom

Jin'aya (Guild Admin) 8/10/2009 1:02 PM EST : RE: Mottie help! Image gallery
Jin'aya
Posts: 39
Becoming Adept!

YAY you star!

*** MASSIVE HUGS***

edit: you said
You have no control over the image displayed... it's random and willalways be 8 seconds between images - I can let you control this withsome additional coding.


is it possible to control the randomness so it just scrolls through all of them in turn? not a big issue its just that at the moment as there arent many images it will frequently bring up the same image 2 or 3 times in a row.

This will be a signature....
>My SWCWikia Page<
TopBottom

Mottie (MVP) 8/10/2009 1:21 PM EST : RE: Mottie help! Image gallery
GuildPortal MVP
Mottie
Posts: 3884
Zomgawsh Poster

You're welcome!

Oh and I forgot to add, you can change the image caption using this CSS... this will work even if you don't use the code above.
<style type="text/css">
#imgCaptionDiv {
 font-size: 120%;
 font-weight: bold;
 color: #000000;
}
</style>
TopBottom

Jin'aya (Guild Admin) 8/10/2009 1:45 PM EST : RE: Mottie help! Image gallery
Jin'aya
Posts: 39
Becoming Adept!

ah brilliant thank you *adds that bit of coding to her Mysterious box(tm)*

points to above edit to her reply with additional question.

*realises this reply made no sense* sticks question in here:

edit: you said
Youhave no control over the image displayed... it's random and willalwaysbe 8 seconds between images - I can let you control this withsomeadditional coding.


is it possible to control therandomness so it just scrolls through all of them in turn? not a bigissue its just that at the moment as there arent many images it willfrequently bring up the same image 2 or 3 times in a row.


This will be a signature....
>My SWCWikia Page<
TopBottom

Mottie (MVP) 8/22/2009 10:29 AM EST : RE: Mottie help! Image gallery
GuildPortal MVP
Mottie
Posts: 3884
Zomgawsh Poster

Hi Jin'aya!

I looked into modifying the gallery to step through each image as well as stay random and it just became a complete an utter mess. I don't have time at the moment to completely re-write the gallery so it's on the back burner for now.
TopBottom

Admins Online
There are   members online.
So-and-so has logged on!
%title%
%message%