Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2010-05-05 17:38:53

mapu
Member
From: Munich, Germany
Registered: 2004-03-16
Posts: 141

[request] Batch thumbnail resize

Let’s say I have 200 images in TXP all with thumbnails cropped 200×200 px.

For a new layout I need a different size of the thumbnails, I even want to remove the cropping.

Dynamic resizing is no (perfect) solution because of the server stress. Downloading the original images, resizing them locally and uploading them as new thumbnails seem also not to be a good way because the thumbnail size etc. is stored in the database.

An admin plugin for that purpose would be wonderful (Example for WordPress), but I’m grateful for every hint for a nice approach to this task.

Offline

#2 2010-05-06 20:54:53

makss
Plugin Author
From: Ukraine
Registered: 2008-10-21
Posts: 355
Website

Re: [request] Batch thumbnail resize

mapu wrote:

Downloading the original images, resizing them locally and uploading them as new thumbnails seem also not to be a good way because the thumbnail size etc. is stored in the database.

Thumbnail size not stored in database. Only original images store size in DB.
Simple download original images and make new thumbnail uses XnView or macros in Photoshop

Last edited by makss (2010-05-06 20:56:08)


aks_cron : Cron inside Textpattern | aks_article : extended article_custom tag
aks_cache : cache for TxP | aks_dragdrop : Drag&Drop categories (article, link, image, file)

Offline

#3 2010-05-07 04:07:49

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: [request] Batch thumbnail resize

makss wrote:

Thumbnail size not stored in database.

Actually, it is since 4.2.0.

Offline

#4 2010-05-07 06:37:11

makss
Plugin Author
From: Ukraine
Registered: 2008-10-21
Posts: 355
Website

Re: [request] Batch thumbnail resize

wet wrote:

Thumbnail size not stored in database.
Actually, it is since 4.2.0.

Thank you for a correction.

Step2: Backup database and update txp_image. Run query in phpMyAdmin:

update prefix_txp_image set thumb_w= 300, thumb_h= 300 where thumbnail=1

300 – new thumbnail size
prefix_ – your table prefix


aks_cron : Cron inside Textpattern | aks_article : extended article_custom tag
aks_cache : cache for TxP | aks_dragdrop : Drag&Drop categories (article, link, image, file)

Offline

#5 2010-05-07 08:50:43

mapu
Member
From: Munich, Germany
Registered: 2004-03-16
Posts: 141

Re: [request] Batch thumbnail resize

makss wrote:

Step2: Backup database and update txp_image. Run query in phpMyAdmin:

update prefix_txp_image set thumb_w= 300, thumb_h= 300 where thumbnail=1

300 – new thumbnail size
prefix_ – your table prefix

Thanks, I’ll give this a try!

Offline

#6 2010-05-07 20:11:11

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: [request] Batch thumbnail resize

If you’re using an earlier version, 4.0.8 and older, you can use the method I described here

Offline

#7 2010-05-07 20:15:36

mapu
Member
From: Munich, Germany
Registered: 2004-03-16
Posts: 141

Re: [request] Batch thumbnail resize

masa wrote:

If you’re using an earlier version, 4.0.8 and older, you can use the method I described here

My TXP installs are always up to date! ;)

Offline

#8 2010-05-07 21:05:39

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: [request] Batch thumbnail resize

mapu wrote:

My TXP installs are always up to date! ;)

In that case it’s more complicated unfortunately.

Offline

Board footer

Powered by FluxBB