[MOD] Thickbox Module for Pligg

Register an Account
Pligg Chat Room
Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-09-2007, 10:22 PM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi All,

I've taken the latest version of Thickbox and turned it into a Pligg mod.

There are some incompatibilities between having Thickbox and Scriptalicious running at the same time. I've tried to address this by turning off Thickbox when in the admin_config area. As everyone set up may be different, its easier to have this as a module and restrict it than to simply include it site-wide which some people have done. Also, it keeps things a little more tidy.

There may be issues with Lightbox and Thickbox running together, though I honestly haven't tried it as we won't have private messaging enabled on our site.

You can download it here:
http://forums.pligg.com/downloads.php?do=file&id=34

Best,
Cent

Last edited by cent; 04-09-2007 at 10:30 PM. Reason: Update
Reply With Quote
  #2 (permalink)  
Old 04-10-2007, 12:15 AM
kbeeveer46's Avatar
Pligg Developer/Admin
Pligg Version: 0
Pligg Template: none
 
Join Date: Jun 2006
Location: Muncie, Indiana
Posts: 3,215
Cool. Hopefully this can be used in addition to future modules. You have any luck with that image upload module?
Reply With Quote
  #3 (permalink)  
Old 04-10-2007, 01:30 AM
dollars5's Avatar
Pligg Donor
 
Join Date: Dec 2006
Location: India
Posts: 1,961
Thanks - how does it compare to the existing lightbox in size, performance etc?

Good work - me waiting to see your images upload mod very soon - this is becoming a mot wanted feature for everyone.
Reply With Quote
  #4 (permalink)  
Old 04-10-2007, 10:54 AM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi KB... actually, its pretty much done. Just going through the module to add comments and remove debugging code. So far, in my own testing, the module keeps the image intact when voting and viewing the story. I think some people had cases where hard-coded code worked on submission but the image data got erased from the db.

Please keep in mind this module only allows for a photo to be uploaded with a submission. It doesn't allow the user to put a URL to a photo from another site.

So far the module supports:
- Admin option for image directory
- GD Version support
- Selectable JPG quality (for resizing large images to fit max W or H)
- Use Thickbox or not (can also be used with Lightbox if necessary with minimal changes)
- Show thumb in story or fullsize image
- Max thumb width x height (if showing thumbnails)
- Fullsize filename prefix (ie. start all image filenames with "img_");
- Fullsize width x height (scales larger images down)
- Fullsize max toggle (used to set a max width or height of full size image)
- Selectable field for image filename (ie. link_field10)
- Thumbnail legend text (ie. click thumbnail for larger version)
- Custom selectable thumbnail generator (thumbnails generatred on the fly but you can swap out my class for phpthumb or some other thumbnail generator)
- CSS code for thumbnail/image configuration
- and finally language support

TODO list:
- Photo caption
- Store original file name in database. Currently only stores new image name using uniqid(); Thinking of saving both the original file name and saved file name in an array, imploding it and storing it. This will still allow for both names to be stored in a single field. Actually, this could store the photo caption, original filename and new filename together. Not sure if you would be able to search and pick up stuff in this field though.

Best,
Cent
Reply With Quote
  #5 (permalink)  
Old 04-10-2007, 10:58 AM
kbeeveer46's Avatar
Pligg Developer/Admin
Pligg Version: 0
Pligg Template: none
 
Join Date: Jun 2006
Location: Muncie, Indiana
Posts: 3,215
Sounds awesome. Did you say that using this mod will probably cause issues with people using private messaging because of lightbox? Maybe we can look into changing lightbox over to thickbox now that you have written that mod.
Reply With Quote
  #6 (permalink)  
Old 04-10-2007, 10:59 AM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
hi dollars5,

i think thickbox is easier to use. while the original lightbox was for photos and there have been modified versions of lightbox written, i think thickbox is far simpler and the jquery is a lot more compact. you can easily do a photo gallery, inline (scrollable content), iframe, custom sizing of "lightbox" window on a link by link basis pretty easily.

Best,
Cent
Reply With Quote
  #7 (permalink)  
Old 04-10-2007, 11:03 AM
cent's Avatar
Constant Pligger
 
Join Date: Jan 2007
Location: New York, NY
Posts: 180
Hi KB...

not sure. I'm going to test lightbox/messaging in conjunction with thickbox/image upload to see how they work together. if they do work together, its a lot of JS being downloaded between lightbox (at its dependencies) and thickbox (thickbox.js and jquery.js). I know there have been some threads on making things smaller, this will probably start a whole new bunch of convos.

Personally, i think thickbox is more compact and offers everything lightbox does. once i get some free time, i may put together a thickbox/messaging module unless one of the devs beats me to it.

Best,
Cent

Quote:
Originally Posted by kbeeveer46 View Post
Sounds awesome. Did you say that using this mod will probably cause issues with people using private messaging because of lightbox? Maybe we can look into changing lightbox over to thickbox now that you have written that mod.
Reply With Quote
  #8 (permalink)  
Old 04-10-2007, 11:08 AM
Constant Pligger
 
Join Date: Mar 2006
Posts: 537
I believe we might be able to switch all effects over to using jquery eventually, and this would really help cut down on the amount of javascript being downloaded. If thickbox is going to be used for things like video mods and other effects, then using it in place of lightbox for messaging might also be a good idea.

Better to use 1 library than many.
Reply With Quote
  #9 (permalink)  
Old 04-10-2007, 11:41 AM
Casual Pligger
 
Join Date: Feb 2007
Posts: 93
any examples of this mod working on a pligg site?
Reply With Quote
  #10 (permalink)  
Old 04-13-2007, 09:10 AM
Banned
Pligg Version: 9.8.
Pligg Template: Custom
 
Join Date: Feb 2007
Location: Canada
Posts: 796
Up until now I was very happy with this mod.

I have discovered though that this prevents other js from working. For example: editting in admin > modify lang. also, the sidebar effects do not owrk now, also the js effects when you click on a members name in their story to see profile and the save this mod doesn't work now either.

Is there a way around this?

You can test this out at http://www.newsdots.com/story.php?ti...rtual-wardrobe


All of this was working up until I installed this.
Geoserv
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Fixes to Profile Extra Fields Module v0.2 and Extended Profile Module v0.1 redwine Questions and Comments 8 01-04-2010 07:06 PM
[MOD] Image Upload Module (v1.0) -- Now Available cent Questions and Comments 184 06-27-2009 01:50 AM
[MOD] Image Upload Module (v0.93) -- Please test cent Questions and Comments 54 05-01-2009 10:12 PM
[MOD] MP3 Upload Module cent Questions and Comments 33 02-18-2009 05:34 PM
Optimised Scriptaculous Module with Thickbox Simon Questions and Comments 78 07-27-2008 01:11 AM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development