Zen Cart Logo
Forums / All Other Contributions/Addons / Image Handler 3 Support Thread (for ZC v1.3.9)

Image Handler 3 Support Thread (for ZC v1.3.9)

Views: 180,262

Results 741 to 760 of 1,099
12 Jan 2012, 2:33 AM
#741
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Image Handler 3 Support Thread (for ZC v1.3.9)

DarkAngel:

you mean you noticed that!!! I thought it was cleverly disguised...lol

nah I just ended up in the twilight zone...lol

btw I noticed it waaaaaaay after I posted it:laugh::laugh::laugh: I HAD to mess with you girl.. I knew you were blowing off steam.. :laugh::laugh::laugh:

12 Jan 2012, 2:38 AM
#742
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

GArmour:

Howdy,

I'm new to Zen Cart. I have been building websites since 2003. (NTIMM)So you know from your experience that when you copy files and folders over where the NAME of the folder alredy exists, you will be prompted by your FTP client that the folder NAME already exists.. Simply answer yes, and it will then do the same check for each file name that already exists in the folder.. (it will prompt you when you are overwriting an existing file.) Doing this does not affect any other files ALREADY IN THE TARGET FOLDER. They will remain in place as you are not overwriting any of them..

GArmour:

I have a question about installing Image Handler 3.

In the Image Handler 3 installation instructions:

3. Rename the "YOUR_ADMIN_FOLDER" folder in the "1_Install_Files" & "2_Required_Core_Edits" folders to match the name of your admin folder.

1_Install_Files/YOUR_ADMIN/
2_Required_Core_Edits/YOUR_ADMIN/

Okay, that make sense, as do renaming several other folders to match the template name.

What is confusing to me is that section that says:

5. Upload the files from "1_Install_Files" to your store. (DO NOT upload the "1_Install_Files" folder, just the CONTENTS of this folder -
copy ALL of the add-on files to your store!! Most issues are caused by store owners who decide to NOT load ALL of the module files)

  1. Upload the files from "2_Required_Core_Edits" to your store. (DO NOT upload the "2_Required_Core_Edits" folder, just the CONTENTS of this folder - copy ALL of the add-on files to your store!! Most issues are caused by store owners who decide to NOT load ALL of the module files)

If I upload these folders to my main store folder it appears that the new folder renamed the same as the admin folder will overwrite that folder. Am I missing something here?

To which folder(s) in Zen Cart do the Image Handler 3 folders and files need to uploaded?

Thanks in advance for your help.the root of your store.. and as the instructions indicate you upload the CONTENTS of these folders, NOT the folders..

12 Jan 2012, 2:59 AM
#743
garmour avatar

garmour

New Zenner

Join Date:
Jan 2012
Posts:
5
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

DivaVocals:

So you know from your experience that when you copy files and folders over where the NAME of the folder alredy exists, you will be prompted by your FTP client that the folder NAME already exists.. Simply answer yes, and it will then do the same check for each file name that already exists in the folder.. (it will prompt you when you are overwriting an existing file.) Doing this does not affect any other files ALREADY IN THE TARGET FOLDER. They will remain in place as you are not overwriting any of them..

the root of your store.. and as the instructions indicate you upload the CONTENTS of these folders, NOT the folders..

THANKS!

Why was it necessary to rename the folders to the same as my admin folder if only the contents get uploaded? This is confusing.

12 Jan 2012, 3:50 AM
#744
garmour avatar

garmour

New Zenner

Join Date:
Jan 2012
Posts:
5
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Thanks for the help! I got Image Handler 3 installed and running. Perhaps I was being overly cautious, but I have leaned to ask questions before I cause a self-inflicted disaster. It's easier than asking what went wrong.

12 Jan 2012, 4:04 AM
#745
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

GArmour:

THANKS!

Why was it necessary to rename the folders to the same as my admin folder if only the contents get uploaded? This is confusing.
Because it's easier to upload the ENTIRE contents of the install folders (which contain files as well as folders) versus uploading the contents of each individual folder.. It's necessary to rename the admin folder since when we bundle the add-on we don't know what YOUR admin folder is called..

You will find that this is how MANY mod authors bundle their add-ons..

12 Jan 2012, 4:38 AM
#746
darkangel avatar

darkangel

Totally Zenned

Join Date:
Oct 2007
Location:
Emporia, Kansas
Posts:
1,729
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

DivaVocals:

:laugh::laugh::laugh: I HAD to mess with you girl.. I knew you were blowing off steam.. :laugh::laugh::laugh:

I know sweety and a bit of levity is always a pleasure...

@GArmour

and as for the confusing part of the read me...it confoozled me a bit too then I re-read and saw the "contents" part...but there are many out there that do not realize that and upload the folder---oopsie they find out quick to read that darn read me better...lol

personally I quit renaming things cause I did it myself too many darn times...I should have been born blonder than blonde.

12 Jan 2012, 10:15 AM
#747
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

clydejones:

There will be changes required to the admin side in order for IH3 to work with 1.5

notably ( image_handler_tools_dhtml.php ) will be deleted

and replaced with a new datafile definition ( ```
define('BOX_TOOLS_IMAGE_HANDLER', 'Image Handler');

> 
> An sql statement will need to be run in order to register the page in the new 1.5 admin pages. ( ```
INSERT INTO admin_pages (page_key, language_key, main_page, page_params, menu_key, display_on_menu, sort_order) VALUES ('imageHandler', 'BOX_TOOLS_IMAGE_HANDLER', 'FILENAME_IMAGE_HANDLER', '', 'tools', 'Y', 999);
``` )
> 
> These change will make IH3 non-backward compatible with previous versions.
> 
> Front end files will need to be compared and merged if necessary.
> 
> I'll let you know how I fair with the testing.

OK, let's take it from the beginning. As I understand from Clyde's post quoted above and from yesterday's posts in this thread, IH3 can work with 1.5 even though it may not meet all security requirements of 1.5 at the moment.

I have tried to implement Clyde's suggestions but can not make it to work. Could one of the gurus provide some guidance please?

I run the SQL statement and now have a row in the admin_pages table reading:

page_key = imageHandler
language_key = BOX_TOOLS_IMAGE_HANDLER
main_page = FILENAME_IMAGE_HANDLER
page_params =
menu_key = tools
display_on_menu = Y
sort_order = 999

After running the SQL statement, I get the IH3 in the Tools menu but its links are not doing anything. See the image below.

![](http://athenscollectibles.info/images/zen_cart_forums/IH3.jpg)

Clyde suggested deleting image_handler_tools_dhtml.php (that's easy to do) and replacing it with the new datafile definition
define('BOX_TOOLS_IMAGE_HANDLER', 'Image Handler');

The question is: in which file should the datafile definition go? I tried many files but with no success. The result is always as in the picture above.

Any ideas please? Has anyone else tried Clyde's solution and had IH3 working with 1.5?
12 Jan 2012, 11:32 AM
#748
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,763
Plugin Contributions:
9

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Have you tried putting the define in a file called ih3_filenames.php and adding the file to the YOURADMIN/includes/extra_datafiles folder?

You could also call it my_admin_module_filenames.php if you plan on adding other mods that need admin registration.

12 Jan 2012, 11:49 AM
#749
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Thank you for the suggestion. I did create a new file in the appropriate folder and tried both file names but the links still don't do anything. I just have define('BOX_TOOLS_IMAGE_HANDLER', 'Image Handler'); on the top left of every screen in Administration after the new file was created. Does this say anything to you?

12 Jan 2012, 7:09 PM
#750
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Athens Collectibles:

Thank you for the suggestion. I did create a new file in the appropriate folder and tried both file names but the links still don't do anything. I just have define('BOX_TOOLS_IMAGE_HANDLER', 'Image Handler'); on the top left of every screen in Administration after the new file was created. Does this say anything to you?It is possible they do not work because of the security requirements of the new v1.5 that IH3 does not meet yet..

dbltoe: have you tried Clyde's method and have you been able to get IH3 to work in v1.5?? I've not tried it yet (got a LOT on my plate -- so not much time for free mod stuff currently)

12 Jan 2012, 7:21 PM
#751
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Thanks for coming back DivaVocals. There are only 3 steps in Clyde's method: delete a file (done), run an SQL statement (done, hence the IH3 appears in Admin > Tools) and replace the deleted file with a new datafile definition. It is this last step that confuses me, that is where to include this definition.

dbltoe suggested creating a new file, which I tried and didn't work. Any more ideas? Is it possible that the new file should have a specific file name or be in a specific folder?

I'm willing to play the guinea pig and have tried many things myself but had no success.

12 Jan 2012, 8:08 PM
#752
niccol avatar

niccol

Totally Zenned

Join Date:
Apr 2009
Posts:
2,138
Plugin Contributions:
1

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

In some ways it doesn't matter where it goes if it gets autoloaded.

You can put it in admin/includes/extra_datafiles/myfile.php

which i think is what clyde was saying and is probably best.

Or you could try:

You can put it in admin/includes/laguages/english/extra_definitions/new_file.php

or whatever language that you are using.

As long as the constant is loaded it effectively doesnt matter where it comes from as far as making it work goes. But there is a Zen way of doing things so Clyde's way is best.

(obviously I have just made up those file names. you can call the file whatever you want too. but the paths should stay the same.)

12 Jan 2012, 8:18 PM
#753
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Hi Nick,

as I said above (post #747), the new file loads from the admin/includes/extra_datafiles folder, but all it does is display define('BOX_TOOLS_IMAGE_HANDLER', 'Image Handler'); on top of the Admin screen, above the logo. The Manager, Admin, Preview, About links still do not work. I even removed the .htaccess file from admin and admin/includes in case a rule there prevented the mod from working but nothing changed.

12 Jan 2012, 10:18 PM
#754
niccol avatar

niccol

Totally Zenned

Join Date:
Apr 2009
Posts:
2,138
Plugin Contributions:
1

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

the file should read:

<?php 
define('BOX_TOOLS_IMAGE_HANDLER', 'Image Handler'); 

I suspect that you don't have the first line of that.

13 Jan 2012, 9:06 AM
#755
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Nick, you were right to suspect me. <?php was not included as the first line. But, when added, nothing changed except for the constant not displaying any more above the logo. Links are still dead. :cry:

13 Jan 2012, 9:27 AM
#756
darkangel avatar

darkangel

Totally Zenned

Join Date:
Oct 2007
Location:
Emporia, Kansas
Posts:
1,729
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

so can you post the file you created and the exact thing you did please...I got confused (not a difficult task either so hush...lol)

13 Jan 2012, 9:54 AM
#757
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

You are not alone in your confusion! What I've done so far:

  1. Run the SQL statement as suggested by Clyde (see post #745)
  2. Deleted file ADMIN/includes/boxes/image_handler_tools_dhtml.php as suggested by Clyde (see post #745)
  3. Created a new file ADMIN/includes/extra_datafiles/ih3_filenames.php as suggested by dbltoe (see post #746) and corrected by niccol (see post #752)

Contents of the new file:

<?php
define('BOX_TOOLS_IMAGE_HANDLER', 'Image Handler');

The situation remains as described in the screenshot of post #745. When the links Manager, Admin, Preview and About are clicked, nothing happens.

I wish I was a php programmer to check each file and see what's going on but, unfortunately, I'm not. I don't believe that there are security issues preventing IH to work. It may not meet all security requirements of Zen Cart 1.5 but it should work, even if there were risks which I (and other users) would be prepared to accept.

13 Jan 2012, 2:55 PM
#758
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Athens Collectibles:

I wish I was a php programmer to check each file and see what's going on but, unfortunately, I'm not. I don't believe that there are security issues preventing IH to work. It may not meet all security requirements of Zen Cart 1.5 but it should work, even if there were risks which I (and other users) would be prepared to accept.I believe it IS the increased security in IH3 that is preventing the links in the app from working.. There is a fair bit of IH3 code that IS NOT secure based on the standards that v1.5 of ZC was built under. It is ENTIRELY possible that the new ZC will indeed prevent add-ons that don't meet these standards to run.. (this is not impossible -- WordPress does this with it's code to try and keep errant plugins from bringing down a site, so WHY couldn't Zen Cart do it)

Now do I know this for SURE?? Nope.. I don't know FOR SURE e that this is what is happening here because I have not looked at the IH3 code. However I do know based on my 17+ years working in software development that this can indeed be the case. Additionally there have been indications (based on discussion about IH3 compatibility with v1.5 by knowledgeable folks from this community) that the issues with IH3 and needed security fixes may very well prevent IH3 from working under v1.5..

That said, as I said previously I don't know what stage the work on IH3 for v1.5 is at.. I don't think that there is a QUICK fix for it using the current codebase at this time. If you REALLY need it working, you might consider hiring a developer to fix it for you, or wait for more information on IH3 development..

Now if anyone in the community knows otherwise hopefully they will share.. (niccol??nigel???) I am happy to be proven wrong here.. :smile:

13 Jan 2012, 3:32 PM
#759
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

I am happy to be proven wrong here..Me too :yes:

13 Jan 2012, 3:41 PM
#760
niccol avatar

niccol

Totally Zenned

Join Date:
Apr 2009
Posts:
2,138
Plugin Contributions:
1

Re: Image Handler 3 Support Thread (for ZC v1.3.9)

Well, I thought I had got IH3 running fine on a development server but can't say for sure because my mind is a bit elsewhere at the moment.

There is the issue with sercurity on 1.5 but I didn't think that this actually prevented things from working. Rather people were being encouraged to code to meet those guidelines. But this is just what I believe.

However, there are other issues with making a module work with a new version. The code was written to be compatible with a previous codebase. If there are incompatibilities with the new codebase then that will cause functional issues. To be honest I would guess that that is the case here, or there is simply an installation error.

Having said that these links are actioned using a get parameter on the URL. Which is one of the things that is being discouraged in Zen 1.5. So perhaps there is stronger security in place to prevent this happening. You'd have to investigate or ask the developers.

What happens if you add this to the end of the image handler URL

?page=about

so it reads

image_handler.php?page=about

That should emulate the link that is being used and might shed some light on the issue.

I know there are efforts to get IH working. As Diva knows I am not involved in that. Partly, because others are doing it and partly because I think that IH is overly complex for the needs of most stores. So, I am not keen to spend too much time investigating this quirk.