Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: nhn_image_import: multiple image import
> you can’t use functions of other plugins anymore
It’s possible. You can use include_plugin() (continue if not present) and require_plugin() (die if not present). you have to pass the name of the plugin as parameter. After that you can call the different functions in the other plugin normally.
Offline
Re: nhn_image_import: multiple image import
Nils mate, you did a great job with this plug-in!
I wanted to start “bastardizing” your plugin to fit my needs, but then realized that I don’t have enough time for that. I am “cutting corners” with the help of Automator so I’m OK – Windows guys or OS X <10.4 won’t be as lucky though. My suggestions:
~ auto re-sizing by adding some variables the top of your plug-in (e.g. <code>$default_resize = 500; // feel free to customize</code>)
~ auto thumbnail creation, following the above principle (e.g. <code>$default_thumb = 100; // feel free to customize</code>)
~ auto <code>$aspect_ratio</code> maybe...
~ now then, AND THIS IS THE MOST IMPORTANT ONE, scrap the image naming only by ID and put in place something like <code>$id.$image_name</code>. Adding 0s to the <code>$id</code> e.g. <strong>0001</strong> will ensure images stay in sequence up to <strong>9999</strong>. When I FTP in the images folder and see a bunch of numbers as image names, it makes my task so much harder to retrieve (copy) what I want... I hate the idea of being forced to use only TXPs interface for handling images (which is pretty poor
the moment…).
Hope my suggestions help ; ), Gerhard.
Offline
Re: nhn_image_import: multiple image import
Any idea of the status of this plugin? It’s not completely broken but it is giving some eval issues that cause it to mass duplicate with txp4.0
Proud Canadian. Toronto Locksmith , Actualize Consulting
Offline
Re: nhn_image_import: multiple image import
Sorry, I’ve been on holiday for a few weeks.
I have not yet been testing the plugin under TXP 4.0 but I know that you can get in trouble, if the chmod of the uploaded images is not correct.
Unfortunately I won’t have the time for the next 2 months to continue the developement of this plugin because I’m moving and have to do some university stuff simultanious. I have some ideas to solve the problems with duplicated uploads, but if these changes are needed before November, somebody might take over the ownership of the plugin.
Offline
#29 2005-08-29 13:55:36
- aba
- Plugin Author
- Registered: 2004-04-14
- Posts: 119
Re: nhn_image_import: multiple image import
I’m willing. I already extended it to create thumbnails when importing images and no thumb-*.* is found. I plan to release it after some testing.
Offline
Re: nhn_image_import: multiple image import
Wow this plugin sounds great.
<blockquote>I wanted to start “bastardizing” your plugin to fit my needs, but then realized that I don’t have enough time for that. I am “cutting corners” with the help of Automator so I’m OK – Windows guys or OS X <10.4 won’t be as lucky though.</blockquote>
I really should start looking into automator. I just had a project/have a project that could be made much easier probably w/automator.
bludrop studios .::. Creative Expression
Offline
Re: nhn_image_import: multiple image import
> blumie607 wrote:
<blockquote>I really should start looking into automator. I just had a project/have a project that could be made much easier probably w/automator.
</blockquote>
What is automator?
Proud Canadian. Toronto Locksmith , Actualize Consulting
Offline
Re: nhn_image_import: multiple image import
For your information: This plugin has been taken over by aba (thank you!) and as he told me via email, there will be soon a new release.
Nils
Offline
#33 2005-09-08 14:02:11
- aba
- Plugin Author
- Registered: 2004-04-14
- Posts: 119
Re: nhn_image_import: multiple image import
I wonder whether Nils would still recognize his plugin…
I rewrote the nhn_image_import but unfortunately it does much more than I need so I miss some testing of features I’m not very interested in: This results in:
beta testers wanted
you should have some basic understanding of textpattern and file permissions (that’s still a problem for the plugin) and you should be willing to sacrifice your images to the plugin (read: it should not be used in a production system! – you have been warned). You also need to have a plugin cache directory to drop the php in because I didn’t compile a plugin yet (I need to write the documentation first).
It is still not finished and there is a good chance that it either doesn’t work or burn your house and kill your pets. Hopefully I have a version ready for the weekend (aspect ratio needs to be done first) that does the following:
all features can be globally enabled/disabled
- automatic thumbnail generation unless thumb-imagename.ext is present (then this is used as thumbnail)
- you may have a small looking glass in plugins (the class used by txp is quite powerful)
- get caption either from exif comment or iptc comment
- use filename (minus extension and ‘_’ replaced by spaces) for alt tag
- resize pictures while importing (personally I don’t see why sending large pictures to a server and resize them when importing is something you need/want but someone requested it – because it uses the same thumbnail class there might be drawback though)
please let me know by email if you’re interested to test some code that might not even work.
warning: I’m not a programmer, so there might be some thing a real PHP programmer would kill me for. If you find something like this, let me know.
despite the permissions issue there are two more problems with the plugin:
1. It is not very commucative when errors occur (and I have some problems how to handle them)
2. It often needs a refresh of the image tab after import because I still don’t get it how to import the images and have the up to date image list in the tab (I’m currently considering to implement the plugin in an extensions tab to get rid of these problems – opinions are welcome).
gerhard: sorry, but this plugin is using the internal image functions so there is no chance for your request to scrap filenames solely based on id.
Offline
Re: nhn_image_import: multiple image import
An extensions tab would be considerably helpful. But quite the task ;P I’ll gladly test it out… I have a couple of different servers and domains that I can ‘ruin’ ;)
Proud Canadian. Toronto Locksmith , Actualize Consulting
Offline
Re: nhn_image_import: multiple image import
“automatic thumbnail generation unless thumb-imagename.ext is present (then this is used as thumbnail)”
Does this mean thumbs won’t be named [imagename]t.[ext]
anymore?
Offline