Version for 5.x?

glopacadmin - April 11, 2008 - 19:53
Project:jQuery Map Hilight
Version:5.x-1.x-dev
Component:Documentation
Category:support request
Priority:normal
Assigned:WorldFallz
Status:closed
Description

I've been looking for this feature. But we run Drupal 5.3 and do not have plans for a while to go to 6.

Can you say whether this will work on 5?

Thanks.

#1

WorldFallz - April 14, 2008 - 15:49

Unfortunately, at the moment it does not. I was going to try to provide a backport for d5, but the jquery plugin that provides the bulk of the functionality requires jquery v1.2 (d5 has 1.0.something I think).

Updating the module code for d5 is easy, but using the module with D5 means using http://drupal.org/project/jquery_update with the patch from http://drupal.org/node/156221 comment #48.

If you're willing to do that, I can update the module so it will be compatible with D5 and you can try it out. I probably won't get to this until the weekend though, what's your timeframe?

#2

glopacadmin - April 16, 2008 - 19:52

My timeframe is not immediate. Or rather, I cannot risk breaking other functionality in use. I guess we are willing to apply the patch to get jquery 1.2. Now we have 1.1.2 and jquery update running. Seems that we would have to disable that and try our luck wiht the patch. Is that right?

No rush, but let me know when you get to offering a D5 update and we'll do the jquery patch then.

We have a number of remote authors who need to make image maps for instructional pages. Using one of the image mapping sites is fine, but the extra step of creating overlays is just not. Thanks.

#3

WorldFallz - April 16, 2008 - 21:11

Seems that we would have to disable that and try our luck wiht the patch. Is that right?

I believe so. The plugin itself (not the module) requires jquery 1.2, so whatever is the current method for updating the current d5 to jquery 1.2 is what is needed. I haven't tried it, so I have no real idea for the ramifications of that move.

Using one of the image mapping sites is fine, but the extra step of creating overlays is just not. Thanks.

I agree wholeheartedly-- that's exactly the reason I created the module. Previously, I was using un-highlighted image maps-- also pretty unacceptable, but at least I could train on that. I used a little icon for images that had image maps so users would know there were links there.

BTW, if you use visio for any of your graphics, it spits out a nice little image map if you "Save as web page". You have to dig for it in one of the bazillion .htm files it creates and massage it a bit with find/replace, but it saves a TON of time creating coordinates. One of these days I'm going to make a little script or php file to automate the find/replace stuff.

I'll probably post a d5 compatible version of the module in the next couple of days-- perhaps over the weekend. I'll post in this thread when it's available.

#4

yngens - April 23, 2008 - 04:54

subscribe

#5

WorldFallz - April 23, 2008 - 16:12
Assigned to:Anonymous» WorldFallz
Status:active» postponed (maintainer needs more info)

I just committed a release for D5. It should show up in the list of releases within 12 hours (has to wait for the next run of the packaging script). I have no access to a jquery updated D5 site, so I have no way to test it. Give it a shot and let me know how it works. Note the disclaimer in the readme, I can't help with upgrading your site to jquery v 1.2, but I'll try to support this version of the module to the best of my ability.

#6

WorldFallz - April 25, 2008 - 19:15

I can confirm it works ( i just had to set up a test d5 site and upgrade jquery to see, lol).

[EDIT: DON'T FOLLOW THIS, USE THE INSTRUCTIONS IN THE README.txt. Sorry for the confusion.]

Here's what I did to get it working:

  1. install jquery_update (follow the instructions)
  2. install jquery_plugin
  3. install the d5 version of jq_maphilight
  4. grab the latest minified copy of jquery from jquery.com (I used v1.2.3)
  5. rename the jquery-1.2.3.min.js file to "jquery.js" & copy to your drupal /misc directory (MAKE A BACKUP COPY FIRST)
  6. grab the lastest copy of the metadata plugin from http://plugins.jquery.com/node/674 and overwrite the one in the jquery_plugin directory (MAKE A BACKUP COPY FIRST)
  7. follow the instructions in the README.txt file for creating the test page to verify it works.

This is only a test d5 site, so I have nothing else on it-- I have no idea if this will break other plugins or other jquery stuff in drupal so i say again:

USE AT YOUR OWN RISK.

If your site does go wonky, it should be a matter of reverting to the previous versions of the jquery.js and jquery.metadata.min.js files to get it back.

#7

WorldFallz - April 23, 2008 - 19:32
Status:postponed (maintainer needs more info)» fixed

Marking this "Fixed" as I have verified the module itself works fine.

#8

glopacadmin - April 25, 2008 - 16:52
Version:6.x-1.x-dev» 5.x-1.x-dev
Component:Code» Documentation
Status:fixed» postponed (maintainer needs more info)

Thanks for the work and the documentation.

I've followed your steps in #6 and put it on our site. The good news is that these plugins and modules have not blown up the site. The bad news is that the hilight module is not working. I can get to the module admin and it shows the plugin at /sites/all/modules/jquery_plugin/jquery.maphilight.min.js, but adding the class="jq_maphilight" to the img tag of an existing image map give no results.

As your steps are a bit different in the readme.txt and here in #6 I wonder if I missed something. E.g. I did NOT use the patch from http://drupal.org/node/156221/comment #48 because I put the latest version of jquery.js (1.2.3.min) from the jquery.com site per your #6 steps.

Any ideas?

At least it has not effected other things on the site (we're using Hierarchical select that depends on jquery updated).

#9

glopacadmin - April 25, 2008 - 19:01

Okay, I have this working now. However, there are some bugs. These are not so much with your module as with the maphilight plugin itself, or rather with that combined with other image map and img tag programs.

The problem before was simply that my image maps did not include the # in the usemap="" HTML. This is because we're using the TinyMCE rich-text editor and it does not add the pound sign for some reason.

The bugs are basically that the maphilight plugin javascript does not play nice with the TinyMCE javascript. We had some pages where an initial image swapped out to an image mapped image. This used the onmouseover="this.src=''" function. With the class="jq_maphilight" this function no longer works and so the regions show up on the initial image.

I can live with this behavior, but it would be nice to be able to combine the two functions. I'll post to the jquery.com maphilight plugin page about this. Other than that any suggestions?

Thanks again for your work. Great to have someone work on this small item.

#10

WorldFallz - April 25, 2008 - 19:53

Did you view source for the page and check that jquery.maphilight.min.js is in the list of javascript files in the header?

Also, you may have to empty the cache and/or clear the browser cache (in FF it's CTRL-F5) as well-- I can't remember if I had to do this specifically, but I almost always do it unconsciously whenever developing.

Regarding the instructions, sorry about the confusion-- I should have been more verbose in my comment above. My d5 testbox is on a shared host that I have no shell access to, so I couldn't easily try the patch from http://drupal.org/node/156221#comment-668998. What I did above was just for a quick & dirty check that the module itself would work.

The "official" way to use this module is with the instructions in the README.txt (not my comment above) because thats the semi-"official" way of upgrading of drupal jquery as outlined in http://drupal.org/node/156221#comment-668998.

I just tested it out, and both that patch and the process as outlined in the README.txt work (doesn't require the additional step #6 above, that was necessary only as a result of using jquery v1.2.3 instead of the patch).

#11

WorldFallz - April 25, 2008 - 19:50

@#9

The bugs are basically that the maphilight plugin javascript does not play nice with the TinyMCE javascript.

hmm... this is odd, because I don't load the plugin on /*/*/edit pages (if you view source while editing with tiny, take a look and verify that jquery.maphilight.min.js is not loaded) so there shouldn't be any interaction with tiny at all.

ok, I just tried on my upgraded jquery test site with tinymce and so far so good.

Maybe it's related to another filter or image handler? What else do you use that might affect the img tag?

Also, are you using FF or IE? The last time I checked, tinymce had a very nasty bug with image maps... any time you enabled it on a page with an image map using IE as a browser, the AREA tags would get mangled (no matter how I configured tiny's extended attributes, it would never go away). Who knows it may have some other weird bugs--

Thanks again for your work. Great to have someone work on this small item.

Thanks-- glad someone else is finding it useful. This has been a pet peeve of mine with image maps for YEARS. To have to use flash for something so simple seemed like insanity.

When I found the jquery maphilight plugin I about screamed for joy, lol. Funny thing is, my main production site is D5-- I was crushed when it didn't work. I created the D6 version waiting for the day I would eventually upgrade, lol ( i was just too lazy to port it to d5 for myself). So you've helped me too-- if it wasn't for inquiries for a d5 version, I probably never would have bothered, lol.

#12

WorldFallz - May 6, 2008 - 18:02

Those following this thread might be interested in this jquery_update 5.x-2.x-dev (which now supports jquery v 1.2.3). I haven't tested it myself though.

#13

WorldFallz - August 26, 2008 - 19:47
Status:postponed (maintainer needs more info)» closed

closing this issue-- the module works fine with the jquery_update 5.x-2.0 release.

#14

WorldFallz - October 12, 2008 - 03:57
Status:closed» fixed

#15

Anonymous (not verified) - October 26, 2008 - 04:04
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.