UDT to easily insert resized clickable images (floated) with caption into pages.

Do something cool with CMS? Show us ...
This board is for 'Answers', and the discussion of answers... Not for questions.
User avatar
Gregor
Power Poster
Power Poster
Posts: 1874
Joined: Thu Mar 23, 2006 9:25 am
Location: The Netherlands

Re: UDT to easily insert resized clickable images (floated) with caption into pages.

Post by Gregor »

Something funny:
http://www.uisge-beatha.eu/news/140/30/Kleur-Anti-Fouling.html

If side=left, how can I forecome possible that they placed more or less next to eachother?

Gregor
JeremyBASS

Re: UDT to easily insert resized clickable images (floated) with caption into pages.

Post by JeremyBASS »

FWIW instead of a UDT there are a few different image resizer plugins that wouldn't need a udt call... Just thought I'd put that out theree... Cheers J
Wishbone
Power Poster
Power Poster
Posts: 1369
Joined: Tue Dec 23, 2008 8:39 pm

Re: UDT to easily insert resized clickable images (floated) with caption into pages.

Post by Wishbone »

JeremyBASS wrote: FWIW instead of a UDT there are a few different image resizer plugins that wouldn't need a udt call... Just thought I'd put that out theree... Cheers J
And place captions, floated, etc? The point of this is to be able to place the image properly sized with captions in an easy fashion so that clients won't have to mess with divs/styles, etc.
Last edited by Wishbone on Wed Feb 03, 2010 11:34 pm, edited 1 time in total.
JeremyBASS

Re: UDT to easily insert resized clickable images (floated) with caption into pages.

Post by JeremyBASS »

really depends... that is up to you.. but yes you can do that... this is all in the setup, see I just have the client use a dropdown and a text box on the page thru content extended, or gallery, or... well there is many ways to approch this.. but I use on all of them the supersizer plugin so that you get perfect images with clients that have no idea whats what... It was just an FYI that there are ways that don't use udts which is a DB hit every time.. that was all :D
User avatar
Gregor
Power Poster
Power Poster
Posts: 1874
Joined: Thu Mar 23, 2006 9:25 am
Location: The Netherlands

Re: UDT to easily insert resized clickable images (floated) with caption into pages.

Post by Gregor »

@JeremyBass: could you provide us with an example on how to use this in news for example?

Thnks
JeremyBASS

Re: UDT to easily insert resized clickable images (floated) with caption into pages.

Post by JeremyBASS »

Hey there, here is one example of one way.. I give them a field for the image.. now it really depends on what they want to do, but lets us say that they want to move it about in the details.  This is what I do this.. use a {capture} at the top of the template and assign it to the var image.  Use supersize to create botht the thumb and the popup size..  then use module_custom to add a note above the details area, saying something like "use {$image} anywhere in the details to add the uploaded image.".

This is simple way to handle it.. I use very tight code so my popup of choice is colorbox (great jQ pluing) so my capture is small too.. now I don't have a template handy atm but I hope that tells how to avoid the UDT and also keep it bullet proof for the client.  Cheers -Jeremy
sumpson
Forum Members
Forum Members
Posts: 111
Joined: Thu May 08, 2008 6:35 pm

Re: UDT to easily insert resized clickable images (floated)

Post by sumpson »

I know this is a very old topic but it has been very helpfull to me and works great, however I would like to make an addition to this.

this is the current tag people would have to put into their wysiwyg editor:
{image file="imagename.jpg" title="title of image" side="left"}

ps. had to change {image} into something else because it is already in use at installation.

The ideal solution would be for users to select the image in the wysiwyg itself and have the HTML in the code like:

<img src="uploads/images/imagename.jpg" alt="title of image" class="left" width="200" height="200"/>
this way the image is visible in the wysiwyg editor as well and users dont have to add codes.

would it be possible to rewrite the HTML input into the tag?

something like:
<img = {image src="uploads/images = file=" alt = title class = side width="***" height="***" /> = }


any help would be greatly appreciated.
Locked

Return to “Tips and Tricks”