Click on smiles and IE7 problem

CompShack - December 9, 2008 - 03:10
Project:Smileys
Version:6.x-1.0-alpha5
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

When you try to add a smile to a comment by clicking on the smile, nothing happen on IE7 (nothing gets inserted into the comment).

#1

sniegs - December 10, 2008 - 05:05

I have the same problem with Safari and Firefox. It is a conflict with YUI Editor, if I disable it, Smileys work.

Don't know if it is Smileys or YUI bug.

#2

CompShack - December 10, 2008 - 05:45

I use BU editor and only have the issue with IE7. Firefox works fine.

#3

ddyrr - December 13, 2008 - 21:23

I switched to FCKEditor, and now I have the problem with both Firefox and IE. This is the error message I get in IE:

Line 43: Expected identifier, string or number
Then it takes me to this line in smileys/scripts/smileys.js:
$(this).dialog(options);

#4

scrap2000 - December 20, 2008 - 15:11

In IE7, there are some problems with the smileys select-box. The "more..." link doesn't appear at all, and when you click on a smiley in the select box, nothing happens (no smiley's code is inserted into the message box).

It works fine in Firefox.

#5

ssace - December 20, 2008 - 21:49

I don't know if it's related to IE7 or not. It's wierd. My users all use different browsers and some work fine
but others say that they see the smileys, but when they click on them nothing happens. They can type the
shortcut and it works, but not selectable by clicking.

For me, it works perfectly in both Firefox and IE.

We've tried clearing cache in website and user browsers, but still no luck for some users.

EDIT: I take that back, It does NOT work in IE7 for me. Wonder if rolling back to alpha 3 will work
until this is fixed.

#6

ssace - December 20, 2008 - 22:24

I reverted back to alpha3 to get it working right again. Does anyone have a fix for this jquery problem with IE7?

#7

GatorBat - December 31, 2008 - 17:07

I too have the same issue with the current release of Smileys. I use the BUEditor as well. In all current releases of Firefox, Camino, and Safari (MAC and Windows), the smiley's insert properly upon clicking on them in the smiley select box. In IE 6/7, they fail to be added to ANY content type. As others have posted, inserting the correct ASCII text will indeed render the smiley in ANY browser. I have cleared all caches (Site, Views, and Theme Registry), and the results are still the same. I get a similar error message (see post #3) on SOME pages within IE 6/7.

#8

marcus0263 - January 3, 2009 - 18:31

Yep, using Smiley's and BUEditor with IE 6/7 doesn't work. This is an issue with M$, one of their recent patch's must have broken some things as M$ is known for doing.

#9

Ledo2 - January 4, 2009 - 01:20

I too confirm IE7 has issues with alpha4 and latest dev version of smileys module for drupal 6.8. It gives javascript errors on all pages where smileys control is present. And smileys are not click able. So when you click on it it does nothing. But you can manually put in the characters and the module filters it right.

And in the admin area there is some trouble with IE7 and Visibility icons. They are not shown. In FF 3 it woks fine.

But a great module. I like it. Hope these errors get fix and thanks for developer for his work.

#10

Gurpartap Singh - January 5, 2009 - 09:18

I have tried to fix the issues discussed here in Alpha5 release. I have tested in IE6 and someone else reported it fine in IE7 too. Please test and let me know if it's fixed with this release.

#11

Ledo2 - January 5, 2009 - 16:44

I tested alpha 5 in IE7 and FF3 and here are the results i noticed:

  1. IE7 does not produce script error on page where smileys bar is present any more
  2. IE7 clicking on smiley works now. It is automatically inserted in text area if we click on smiley from smiley bar
  3. In administer area in IE now the icons for Visibility are shown as they should be
  4. I noticed new weight management in administer area with drag and drop. I like it.
  5. export/Import works great.

    It works much better now!

    Here are some issues i noticed:

    1. In IE7 when we drag smiley from smileys bar in to the text area it does not allow us to do that. I think that is good. In FF3 we can drag smiley to the text area and we don't get Acronyms but the Image Path inserted into the text area. I don't know what it should do but it does no the same thing. And image path is probably not desired?
    2. In IE7 Visibility Legend under the save button is visible but it does not show icons. (3 icons one for each option in legend) The space is blank. But the mouse pointer does change when we hover over that area.

    And for Smileys dialog window. I don't use it but i tested it. I enabled all options in administer area for it and tested it in IE7 and FF3.

    1. if i use Visible on only on popup i.e. "More Smileys" or Visible on select box + popup both times the pop out window is empty.

    And a question:

    Must i change something in server settings or is this a bug. When i change weights of smileys and i press save button i get these:

    An error occurred while requesting the server. Be sure that you have proper permission(s), and the server is responding properly.

    The same thing when i click on icons in administer area for Visibility. I get a indicator top right "saving" but "error" pops out.

    But i can change Visibility and Weight settings with no problem in edit smiley area. If i edit each smiley individually.

#12

sniegs - January 10, 2009 - 06:39

I tested alpha 5 and it's the same as with alpha 4 when using YUI editor and Firefox / Safari / IE6 / IE7. Clicking on a smiley does nothing…

#13

Gurpartap Singh - January 10, 2009 - 08:44

YUI editor isn't supported. At least for now. Thanks for the feedback though! I just hope it will be easy to add a fix for YUI. :-)

Ledo2, that's a jumbo feedback. Much much appreciated! I'll keep in mind when next time I'll be drilling into smileys. Thanks! :)

#14

friolator - September 17, 2009 - 13:59
Version:6.x-1.0-alpha4» 6.x-1.0-alpha5

Not sure if this is related, but I'm seeing this in *some* forms, on Firefox or Safari. I'm using 1.0 Alpha 5.

I looked at the "jQuery.extend(Drupal.settings" block in the generated HTML for a page that works and one that doesn't, and found that there's a difference between the two:

This one works:
(this is on a node/edit page for a comment (using nodecomments), as well as on a regular node page with embedded comment form)

"smileys": { "enable_dialog": 1, "draggable": 1, "resizable": 1, "dialog_width": "400", "dialog_height": "0" },

This one does not:
(This is on a regular node page with an embedded comment form)

"smileys": { "enable_dialog": [ 1, 1 ], "draggable": [ 1, 1 ], "resizable": [ 1, 1 ], "dialog_width": [ "400", "400" ], "dialog_height": [ "0", "0" ] },

The one that doesn't work is just one content type. All the others, which are set up in the same way, seem to work fine. In the case of the one that doesn't work, its node/edit form is not in Panels, but the comment form on the node (where smileys aren't working) is in panels, if that matters.

The weird thing is that it works fine in most cases.

#15

friolator - September 17, 2009 - 16:03

quick update: we just enabled comments on another content type. Essentially it's the same type of layout: drupal comments on a nodecomment content type inside of Panels. We're getting the same strange javascript in "jQuery.extend(Drupal.settings" and the smileys box doesn't work there either.

Worth noting: other content types that use this same structure (nodecomment for the main content type, and drupal comments for the comments attached to it, all assembled in panels) work perfectly.

...Oh, and we're using BUEditor for all of our textarea fields, on both the forms that work and those that don't.

Edit: One other thing I just noticed is that the form element ids on the comment forms that *don't* work are not 'edit-comment,' they're 'edit-comment-1' -- tried adding "edit-comment-1" to the list of target textareas in the smileys.js file, but it didn't have any effect.

#16

Gurpartap Singh - September 18, 2009 - 12:57

friolator: A quick fix for the problem will be to add a static variable in code that adds the Drupal.settings (drupal_add_js(..., 'setting');). The static variable will hold a boolean that if the js has already been set, then don't add any more.

If you can't figure out, let me know, I'll try to patch it.

#17

friolator - September 18, 2009 - 13:23

hmm, I haven't really done anything with static variables. let me know how/where to set that and I'll give it a try.

thanks for the quick response!

#18

Gurpartap Singh - September 18, 2009 - 16:44

<?php
static $jsAdded = FALSE;

if (!
$jsAdded) {
 
// drupal_add_js(......);
 
$isAdded = TRUE;
}
?>

#19

friolator - September 18, 2009 - 17:37

ok, so I added that to smileys.module (and fixed a typo: $isAdded = TRUE; should be $jsAdded = TRUE;) and it does seem to prevent the double entries in "jQuery.extend(Drupal.settings". I can provide a patch for this if you'd like.

however, this doesn't fix the problem on these pages. I think the problem might be the last little nugget I tacked on a post above:

Edit: One other thing I just noticed is that the form element ids on the comment forms that *don't* work are not 'edit-comment,' they're 'edit-comment-1' -- tried adding "edit-comment-1" to the list of target textareas in the smileys.js file, but it didn't have any effect.

even after applying this patch, and adding edit-comment-1 to the list in smileys.js, we still can't click on the smileys and have them appear in the edit form.

any ideas?

#20

friolator - October 21, 2009 - 15:47

So I'm not sure why, but now this works. I wonder if something was cached and it was preventing the change from working.

var textareaIDs = {
  "edit-teaser-js": "",
  "edit-body": "",
  "edit-comment": "",
  "edit-comment-1": ""
};

...seems to work fine now.

#21

hauntfox - November 17, 2009 - 17:39

Specs
Browser: IE 8

My Issue:
I can click on the smileys and it inputs text versions of the smileys, but it doesn't insert a picture version no matter where I insert it.

Attempted Fix:
I tried editing the smileys.js file with those changes but that alone hasn't solved the problem for me.

Smileys.var textareaIDs = {
"edit-teaser-js": "",
"edit-body": "",
"edit-comment": "",
"edit-comment-1": ""};

(copied directly from my smileys.js file)

Then I flushed all caches.

 
 

Drupal is a registered trademark of Dries Buytaert.