Help - Search - Members - Calendar
Full Version: New Entry with thumb-href already in Entry Body?
Movable Type Community Forum > Additional Resources > Tips and Tricks
Bytes U
How can I have the following default text appear in the Entry Body box every time I select "New Entry" from the author's menu?
CODE
<a href="Paste Link Here"><img src="Place Thumbnail Location Here" alt="click for album" hspace="8" align="right" /></a>

If I don't want a thumbnail link in a new entry I can just delete it manually.
I would even be satified if that text would appear somewhere in the new entry template page so I could easily cut/paste the html into the entry body box.

Why?? So I can add a thumbnail that links to a specified album in Coppermine photo gallery.
bigbaldhead
I am looking for something similar to this...I create my thumbnails manually and upload them via ftp. I always name them, by appending "tn_" to the beginning of the image name (e.g. "tn_IMAGENAME.jpg"). I choose to create a popup image which generates:

CODE
<a href="http://subdomain.domain.net/mt-static/images/IMAGENAME.html" onclick="window.open('http://subdomain.domain.net/mt-static/images/IMAGENAME.html','popup','width=568,height=451,scrollbars=no,resizable=no,toolbar=no,directories=no,lo
cation=no,menubar=no,status=no,left=0,top=0'); return false">View image</a>


I would like it to generate:

CODE
<a href="http://subdomain.domain.net/mt-static/images/IMAGENAME.html" onclick="window.open('http://subdomain.domain.net/mt-static/images/IMAGENAME.html','popup','width=190,height=251,scrollbars=no,resizable=no,toolbar=no,directories=no,lo
cation=no,menubar=no,status=no,left=0,top=0'); return false"><img src="http://subdomain.domain.net/mt-static/images/tn_IMAGENAME.jpg" height="80" width="106" align="top" border="0" hspace="0" vspace="0" alt="" title="" longdesc="" /></a>


Is there any way that I can have it generate this code automatically? I think that it is somehow possible in the CMS.pm file, but I'm a little nervous about hacking the file without a little guidance.

Once again any help would be appreciated. Thanks so much.

-danny
bigbaldhead
It strikes me that for my needs it probably just makes more sense to go ahead and let Image::Magick create the thumbnail (thereby generating the code that I wanted). Then I can modify the thumbnail image, as usual, and just replace the Image::Magick thumb on the server...

so...I guess you can ignore my question here. Thanks again.

-danny
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.