4images Forum & Community
Welcome, Guest. Please login or register.
Did you miss your activation email?
May 21, 2018, 01:32:54 AM

Login with username, password and session length
Search:     Advanced search
Check the new Tutorial subforum with helpfull guides and tutorials for modifications and tweaks.
Togle to toolbar
Translate this page with =>
Translate this page >
* Home Help Search Login Register
 
+  4images Forum & Community
|-+  4images Modifications / Modifikationen
| |-+  Mods & Plugins (Releases & Support)
| | |-+  Plugins (Moderators: mawenzi, Rembrandt)
| | | |-+  [Plugin] Batch Import
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: «« « 1 ... 10 11 12 13 [14] 15 » »» Print
Current Topic Rating: *****
Author Topic: [Plugin] Batch Import  (Read 263563 times)
TechnoRocker
Newbie
*
Offline Offline

Posts: 13

Thank You
-Given: 2
-Receive: 0


View Profile
« Reply #195 on: July 05, 2009, 07:16:27 PM »

Hallo allerseids,
Ich habe folgenes Problem:

Quote  [Expand]
0 images in .
Import category ...
DB Error: Bad SQL Query: SELECT cat_order FROM 4images_categories WHERE cat_parent_id = ORDER BY cat_order DESC LIMIT 1
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY cat_order DESC LIMIT 1' at line 4

DB Error: Bad SQL Query: INSERT INTO 4images_categories (cat_id, cat_name, cat_description, cat_parent_id, cat_order, auth_viewcat, auth_viewimage, auth_download, auth_upload, auth_directupload, auth_vote, auth_sendpostcard, auth_readcomment, auth_postcomment) VALUES (2, '', 'lol', , 10, 0, 0, 2, 9, 9, 0, 0, 0, 2)
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' 10, 0, 0, 2, 9, 9, 0, 0, 0, 2)' at line 4
FAILED

Import finished!

Das ist der Pfad


Die Config:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
//-----------------------------------------------------
//--- Configuration -----------------------------------
//-----------------------------------------------------

// Path to the directory the image data are stored.
// No trailing slash!
$data_src_path = "/srv/www/vhosts/clay-class.net/httpdocs/2/data/Dancefloor";

// Thumbnail options
// suffix:     Optional, can be left blank
// prefix:     Optional, can be left blank
// subfolder:  If you images are stored in a subfolder,
//             set the folder name here. Example: "thumbnails/"
//             Optional, can be left blank
// extensions: Valid thumbnail extensions
$thumbnail_options = array(
  "prefix"     => "",
  "suffix"     => "",
  "subfolder"  => "",
  "extensions" => array("jpg", "JPG", "jpeg", "JPEG", "gif", "GIF", "png", "PNG")
);

// As default, the script will only copy the image files
// from your source folders to the 4images folders.
// After import you will have your image data twice on
// your server.
// If you have not enough server space set this to 1.
// Then the script will move the image files.
// Be carefully with this, your data could be lost!!!
$move_image_files = 0;

// Set this to 1 to use file modification time as date?
// Otherwise the current date will be used.
$use_image_filemtime = 1;

// Default description for each image, can be left blank
$default_image_description = "Dancefloor 2009";

// Default keywords for each image, can be left blank
// Separated by spaces. Example: "keyword1 keyword2 keyword3"
$default_image_keywords = "Dancefloor 2009 schule clay";

// Set this to the id of the user who should be the owner of each image.
// If 0, the user id of the current logged in user will be used. That's you ;)
$default_user_id = 0;

// Default description for each category, can be left blank
$default_cat_description = "lol";

// Default category permissions
// AUTH_ALL   = All
// AUTH_USER  = Registered Users
// AUTH_ACL   = Private
// AUTH_ADMIN = Administrators
$auth_viewcat      = AUTH_ALL;
$auth_viewimage    = AUTH_ALL;
$auth_download     = AUTH_USER;
$auth_upload       = AUTH_ADMIN;
$auth_directupload = AUTH_ADMIN;
$auth_vote         = AUTH_ALL;
$auth_sendpostcard = AUTH_ALL;
$auth_readcomment  = AUTH_ALL;
$auth_postcomment  = AUTH_USER;

//-----------------------------------------------------
//--- End Configuration -------------------------------
//-----------------------------------------------------

Wie bekomme ich das Problem weg ?

Mfg

[EDIT by V@no]please don't use [center][/center] in your posts[/EDIT]
« Last Edit: July 05, 2009, 09:52:26 PM by V@no » Logged
Sebas Bonito
Sr. Member
****
Offline Offline

Posts: 271

Thank You
-Given: 4
-Receive: 1

Sebas Bonito


View Profile
« Reply #196 on: July 23, 2009, 04:07:12 PM »

English I get the same message like TechnoRocker (post above), additional to that, here is my server-error log to his.
Deutsch Ich kriege die selbe Fehlermeldung wie TechnoRocker (Post drüber). Ergänzend dazu mein server-error log zu diesem Problem.

Quote  [Expand]
[Thu Jul 23 16:01:31 2009] [error] [client x] PHP Warning: opendir() [<a href='function.opendir'>function.opendir</a>]: open_basedir restriction in effect. File(/) is not within the allowed path(s): (/srv/www/vhosts/de/httpdocs:/tmp) in /srv/www/vhosts/de/httpdocs/daeof/admin/plugins/batch_import.php on line 314, referer: /admin/plugins/batch_import.php

[Thu Jul 23 16:01:31 2009] [error] [client x] PHP Warning: opendir(/) [<a href='function.opendir'>function.opendir</a>]: failed to open dir: Operation not permitted in /srv/www/vhosts/de/httpdocs/daeof/admin/plugins/batch_import.php on line 314, referer: /admin/plugins/batch_import.php

English As "$data_src_path"  I've chosen the sub-folder "tmp" in admin/plugins (CHMOD 777)
Deutsch Als "$data_src_path" habe ich den Unterordner "tmp" in Plugins ausgewählt (CHMOD 777).

English Anyone an idea what this means, and how to fix it?
Deutsch Hat jemand ne Idee, was das zu bedeuten hat, und wie man das Problem lösen kann?
« Last Edit: July 25, 2009, 12:15:26 AM by Schnick und Schnack » Logged
Rembrandt
Moderator
4images Guru
*****
Offline Offline

Posts: 4187

Thank You
-Given: 116
-Receive: 896

Vienna


View Profile WWW
« Reply #197 on: July 23, 2009, 06:04:09 PM »

Hi!
...
Quote  [Expand]
[...open_basedir restriction in effect. File(/) is not within the allowed path(s):...
....

ob das nicht eine PHP restriction ist.

mfg Andi
Logged

Meine 4Images Modifikationen  Now over 100 Modification Online!    Meine 4images Demo Seite


Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Sebas Bonito
Sr. Member
****
Offline Offline

Posts: 271

Thank You
-Given: 4
-Receive: 1

Sebas Bonito


View Profile
« Reply #198 on: July 23, 2009, 06:49:47 PM »

Hi!
...
Quote  [Expand]
[...open_basedir restriction in effect. File(/) is not within the allowed path(s):...
....

ob das nicht eine PHP restriction ist.
mfg Andi

Hi Andi, irgendwie läuft das... hab ein bissl rumgespielt.. hängt es vielleicht damit zusammen, dass die Fotos noch mal in einem Extra-Ordner sein müssen? *grübel*

Ne andere Geschichte: Die Fotos werden nicht verkleinert; besser gesagt, die MOD Auto image resizer wird nicht verwendet. Kann man das irgendwie integrieren? Denn so werden die Fotos in voller Auflösung angezeigt, und das sprengt nicht nur den Rahmen, sondern auch den Bildschirm.
Logged
Rembrandt
Moderator
4images Guru
*****
Offline Offline

Posts: 4187

Thank You
-Given: 116
-Receive: 896

Vienna


View Profile WWW
« Reply #199 on: July 23, 2009, 07:48:15 PM »

Hi!
...
Ne andere Geschichte: Die Fotos werden nicht verkleinert; besser gesagt, die MOD Auto image resizer wird nicht verwendet. Kann man das irgendwie integrieren? Denn so werden die Fotos in voller Auflösung angezeigt, und das sprengt nicht nur den Rahmen, sondern auch den Bildschirm.
ich verwende den big mod, ist aber etwas kompliziert weil die einbauanleitung und das debugging über mehrere seite geht.

du ladest ein großes bild hoch, das automatisch in einen extra ordner kommt, das verkleinerte z.b. 800x600 wird auf der detail angezeigt,
und zum download steht wieder das originale zur verfügung.
http://www.4homepages.de/forum/index.php?topic=7499.msg148451#msg148451

mfg Andi
« Last Edit: November 19, 2010, 04:55:00 AM by Rembrandt » Logged

Meine 4Images Modifikationen  Now over 100 Modification Online!    Meine 4images Demo Seite


Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Sebas Bonito
Sr. Member
****
Offline Offline

Posts: 271

Thank You
-Given: 4
-Receive: 1

Sebas Bonito


View Profile
« Reply #200 on: July 23, 2009, 08:32:14 PM »

Hi!
...
Ne andere Geschichte: Die Fotos werden nicht verkleinert; besser gesagt, die MOD Auto image resizer wird nicht verwendet. Kann man das irgendwie integrieren? Denn so werden die Fotos in voller Auflösung angezeigt, und das sprengt nicht nur den Rahmen, sondern auch den Bildschirm.
ich verwende den big mod, ist aber etwas kompliziert weil die einbauanleitung und das debugging über mehrere seite geht.

du ladest ein großes bild hoch, das automatisch in einen extra ordner kommt, das verkleinerte z.b. 800x600 wird auf der detail angezeigt,
und zum download steht wieder das originale zur verfügung.
http://www.4homepages.de/forum/index.php?topic=7499.msg33712#msg33712

mfg Andi

Hi Andi,

also es läuft doch (MOD Auto image resizer UND [Plugin] Batch Import)... aber danke für den Tipp!

Bei der ersten MOD gibt es im ACP unter "Bilder verwalten" den Punkt "Auto-Image-Resizer". Wenn man nun das (zu große) Foto (nach dem Batch Import) verkleinert, wird automatisch die Original-Datei in den Unterordner "big" kopiert. GENAU SO wollte ich das.



Vielleicht noch ein Tipp für alle, die dieses Plugin nutzen: Meist ist es ja so, dass man nach dem Upload/Batchen die Kategorie noch bearbeiten will. Wenn man nun den Users auf der Seite zunächst nicht den Zugang gewähren will, muss man die "auth_viewcat" dementsprechend anpassen. Ich habe das gleich in die batch_import.php gepackt, damit ich die Kategorie erstmal in Ruhe bearbeiten kann (ohne das nochmal manuell einzustellen). Suche

1
($cat, '".addslashes($cat_name)."', '".addslashes($default_cat_description)."', $cat_parent_id, ".($cat_order['cat_order'] + 10).", $auth_viewcat, $auth_viewimage, $auth_download, $auth_upload, $auth_directupload, $auth_vote, $auth_sendpostcard, $auth_readcomment, $auth_postcomment)";

und ersetze es mit

1
($cat, '".addslashes($cat_name)."', '".addslashes($default_cat_description)."', $cat_parent_id, ".($cat_order['cat_order'] + 10).", 9, $auth_viewimage, $auth_download, $auth_upload, $auth_directupload, $auth_vote, $auth_sendpostcard, $auth_readcomment, $auth_postcomment)";

...die 9 ist in meinem Fall der Admin (ggf. anpassen!).
Logged
thilina
Pre-Newbie

Offline Offline

Posts: 1

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #201 on: January 14, 2010, 03:45:12 AM »

hey,
it say`s

8 images in . Importing image 1 to 8
Import category ...
DB Error: Bad SQL Query: SELECT cat_order FROM ishare_categories WHERE cat_parent_id = ORDER BY cat_order
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY cat_order' at line 4

DB Error: Bad SQL Query: INSERT INTO ishare_categories (cat_id, cat_name, cat_description, cat_parent_id, cat_order, auth_viewcat, auth_viewimage, auth_download, auth_upload, auth_directupload, auth_vote, auth_sendpostcard, auth_readcomment, auth_postcomment) VALUES (3, '', '', , 10, 0, 0, 2, 2, 9, 0, 0, 0, 2)
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' 10, 0, 0, 2, 2, 9, 0, 0, 0, 2)' at line 4
FAILED

1. Importing image .autofsck

Warning: copy(./../../data/media/3/.autofsck) [function.copy]: failed to open stream: No such file or directory in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /.autofsck
Skipping.....

2. Importing image .autorelabel

Warning: copy(./../../data/media/3/.autorelabel) [function.copy]: failed to open stream: No such file or directory in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /.autorelabel
Skipping.....

3. Importing image .pearrc

Warning: copy(./../../data/media/3/.pearrc) [function.copy]: failed to open stream: No such file or directory in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /.pearrc
Skipping.....

4. Importing image .rnd

Warning: copy(/.rnd) [function.copy]: failed to open stream: Permission denied in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /.rnd
Skipping.....

5. Importing image cpmode.conf

Warning: copy(./../../data/media/3/cpmode.conf) [function.copy]: failed to open stream: No such file or directory in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /cpmode.conf
Skipping.....

6. Importing image latest

Warning: copy(./../../data/media/3/latest) [function.copy]: failed to open stream: No such file or directory in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /latest
Skipping.....

7. Importing image oldcrontab

Warning: copy(./../../data/media/3/oldcrontab) [function.copy]: failed to open stream: No such file or directory in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /oldcrontab
Skipping.....

8. Importing image testdir

Warning: copy(./../../data/media/3/testdir) [function.copy]: failed to open stream: No such file or directory in /home/download/public_html/imageshare/admin/plugins/batch_import.php on line 122
Copy Image: Error while copying image /testdir
Skipping.....

thank you...
Logged
Hoang
Newbie
*
Offline Offline

Posts: 25

Thank You
-Given: 6
-Receive: 1


View Profile
« Reply #202 on: September 16, 2010, 05:14:20 PM »

Is it possible to support batch import to special cat (subcat not to root) ?
Logged
x23piracy
Sr. Member
****
Offline Offline

Posts: 420

Thank You
-Given: 48
-Receive: 41


View Profile WWW
« Reply #203 on: October 14, 2010, 03:53:35 AM »

Hi,

this script is very nice but there is something i don't understand.

Why are successfully imported images and categories (folders) are not deleted?
So it is necessary to delete the contents of the import folder, if you forgot that
the categories are created again (same name) and the images re-imported.

I see no point in why files and folders are retaining, can someone explain this?

Someone has already adapted the script?

EDIT:

Ok i found that here Wink

1
2
3
4
5
6
7
8
// As default, the script will only copy the image files
// from your source folders to the 4images folders.
// After import you will have your image data twice on
// your server.
// If you have not enough server space set this to 1.
// Then the script will move the image files.
// Be carefully with this, your data could be lost!!!
$move_image_files = 0;

This is not clear for me:

1
// Then the script will move the image files.

Move to where? Do you mean deleted?

1
// Be carefully with this, your data could be lost!!!

Lost? You mean if the importt was unsuccessfully? but the script
should not delete anything if an error accours. Hmm

Why are categories that already exist duplicated?
Who uses two identical categories denominated?

The idea is to give users an ftp access for a
convenient upload of images.

If the categories are duplicated it's useless

Please clear this up.


Greeting X23
« Last Edit: October 14, 2010, 04:12:51 AM by x23piracy » Logged


Don't trust in md5 it's unsafe change your 4i galerys password hash algorythm! second pw db field, create new hashes over some time, deny old hash. Help members that cry, send informationen mail to the rest. Camouflage new pw hash in cookie. Done!

--(◔̯◔)--
Hoang
Newbie
*
Offline Offline

Posts: 25

Thank You
-Given: 6
-Receive: 1


View Profile
« Reply #204 on: October 22, 2010, 10:46:32 AM »

No support from author!

Is it possible to support batch import to special cat (subcat not to root) ?

Logged
nameless
Full Member
***
Offline Offline

Posts: 143

Thank You
-Given: 7
-Receive: 0


View Profile
« Reply #205 on: November 18, 2010, 11:38:44 PM »

thanks for this mod and it works good with 4image 1.78

but if i have an exit category for example XXXX

and i want to Batch Import some category under XXXX category Not to the root

thanks
Logged
nameless
Full Member
***
Offline Offline

Posts: 143

Thank You
-Given: 7
-Receive: 0


View Profile
« Reply #206 on: December 10, 2010, 01:18:33 PM »

hi evry one
if i use this plug in and when it work it stoped for any reson how can i make it Continue batch
Logged
ca_20gti
Pre-Newbie

Offline Offline

Posts: 1

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #207 on: December 18, 2010, 07:37:18 AM »

Nevermind... I got it to work.. oi
« Last Edit: December 19, 2010, 06:15:26 AM by ca_20gti » Logged
chrissim
Pre-Newbie

Offline Offline

Posts: 4

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #208 on: February 02, 2012, 11:28:17 AM »

hi,

The batch import mod worked great on my side but i have some hiccups here when i imported my images.
The import process were fine and working well but the only thing the date were wrongly recorded for all images that i imported.

For eg: Today i imported images to my category it should showed today date but it was shown last year July 2011 instead.

Another issue here all the keywords were in hyperlinked in straight line. Can we have those keywords in comma instead

Could someone advise me how to fix these problems here?

Thanks
Logged
V@no
If you don't tell me what to do, I won't tell you where you should go :)
Administrator
4images Guru
*****
Offline Offline

Posts: 17849

Thank You
-Given: 47
-Receive: 565

mmm PHP...


View Profile WWW
« Reply #209 on: February 03, 2012, 03:13:48 AM »

the date were wrongly recorded for all images that i imported.

For eg: Today i imported images to my category it should showed today date but it was shown last year July 2011 instead.

Replace:
1
$use_image_filemtime 1;

with:
1
$use_image_filemtime 0;


Another issue here all the keywords were in hyperlinked in straight line. Can we have those keywords in comma instead

The plugin was made for v1.7...quite outdated.
Replace:
1
2
$default_image_keywords str_replace(","" "$default_image_keywords);
$default_image_keywords ereg_replace("( ){2,}"" "$default_image_keywords);

With:
1
2
3
4
5
6
7
8
9
10
11
12
if (version_compare(SCRIPT_VERSION"1.7.8" "<"))
{
	
$default_image_keywords str_replace(","" "$default_image_keywords);
	
$default_image_keywords ereg_replace("( ){2,}"" "$default_image_keywords);
}
else
{
  
$default_image_keywords preg_replace("/[\n\r]/is"","$default_image_keywords);
  
$image_keywords_arr explode(','$default_image_keywords);
  
array_walk($image_keywords_arr'trim_value');
  
$default_image_keywords implode(','array_unique(array_filter($image_keywords_arr)));
}
Logged

Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)
Pages: «« « 1 ... 10 11 12 13 [14] 15 » »» Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.17 seconds with 21 queries.