Hi Eugen,

While I got the module installed successfully this morning after your advice to check the module versions again, I actually now run into the following issue: After uploading and inserting an image, neither image nor any code get inserted into a post.

After image upload the image does show in the Upload window and I get the imagecache options. However, clicking the Insert button only an empty line is being added to a post but not image or code.

This is the case in both Firefox and IE8.

I was wondering if ImageCache might be the problem now and tried an empty preset. But that didn't work either.

I would be glad for any advice you can give!

Danke,
RPK

Comments

EugenMayer’s picture

RPK did you actually read the documentation?

Do you have "HTML filter" activated in the content filter and if, do you have enabled the "img" tag there?

rpk’s picture

Hi Eugen,

Yes, I did read the documentation. The filter is set to full HTML. I assume HTML Corrector and URL Filter can't cause problems with this module, can they? I am relatively (relatively) new to Drupal and wouldn't be surprised if - despite reading the documentation - I may have overseen something.

RPK

EugenMayer’s picture

Well please just be sure that HTML (the wysiwyg edit) is working. Then deactivate most of the filters just to be sure we dont run into a bug with them.

Generally it must be a misconfiguration or a bug with some kind of those filter we aint know about yet. But in that case, iam using the HTML-corrector myself, so i dont think its the cause of this.

On the other hand, as it is a blanc line, its most probably a problem with the imagecache or imagecache theme method. If you are familiar with firebug, please just check what the result of the "showimage" request looks like. In general, it should be some kind of

<img .. src="..">

.. did you theme imagecache yourself ( theme_imagecache?)

rpk’s picture

Hi Eugen,

The WYSIWYG wrapped FCKEditor is working fine. I deactivated all input format filters, including HTML corrector. I checked permissions. I deleted all ImageCache presets (never 'themed' it myself, but did use some additional actions before deleting them.) I double checked module versions once more.

Not sure why it's still not working. Source code only shows an added line break
tag, no image tag.

RPK

EugenMayer’s picture

Ok thanks for your effort.

Are you familiar with firebug and can you research, what the ajax GET request "showimage" returns? If not, is your site public so i could check that?
Iam eager to fix that issue but as i cant reproduce it, its hard :)

rpk’s picture

Hi Eugen,

Thanks for your continued help!

The site is not public yet.

I use Firebug but would honestly not know how to see what the "ajax Get request 'showimage' returns.

After looking around in Firebug, this, however, may very well be what you are looking for:
GET http://localhost/mysite/index.php?q=ajax/wysiwyg_imgupl/showimage/4b6db6...

Returned the following Response:

Fatal error: Call to undefined function dsm() in C:\wamp\www\mysite\sites\all\modules\wysiwyg_imageupload\wysiwyg_imageupload.ajax.inc on line 74

And looking at line 74 in wysiwyg_imageupload.ajax.inc, it seems it's a file path issue.
dsm($filepath);

Please be kind if this turns out be an issue caused by the foolishly foolish or otherwise knowingly and admittedly unwise actions of this relatively (relatively) new Drupal website developer!

Vielen Dank fuer deine Hilfe,
RPK

guictx’s picture

Version: 6.x-1.x-dev » 6.x-1.0-rc2

I was having the exact same problem as rpk (also working in localhost).

After searching for the error in the forums I tried, as suggested in various places, replacing dsm() with drupal_set_message() in wysiwyg_imageupload.ajax.inc.

It solves the problem for me.

This is a great module!

rpk’s picture

Yep, now it works!

After replacing dsm($filepath) with drupal_set_message() in line 74 of wysiwyg_imageupload.ajax.inc, I also needed to replace dsm($output); in line 77 with drupal_set_message() et voila - It works!

Also, I had previously deleted all ImageCache presets in an attempt to minimize possible causes for the problems with WYSIWYG image upload. After the above changes in the code I had to create an ImageCache preset, since the WYSIWYG image upload seems to need it to work.

Thanks Eugen and quictx for the help! This looks like a great module, indeed!

RPK

EugenMayer’s picture

Title: Neither image nor code get inserted » Neither image nor code get inserted - dsm() used int showimage handler
Category: support » bug
Priority: Normal » Critical

Well this is all my fault. dsm is the "shortcut" for developers to show informations of a variable which can be probably a complex object. that method is implemented in the "devel" module and is actually used for debugging. I did not run into that issue because i have devel installed.

Iam sorry wasting your time with that, this was a bad mistake of myself.

This will be fixed in RC3.

EugenMayer’s picture

Status: Active » Fixed

Fixed.

rpk’s picture

Hi Eugen,

Not a waste of time for me at all! This is a great module and I'm glad it works now!

Thanks!

RPK

bora-89’s picture

The same problem I've experienced.
As you all said, I replaced dsm() with drupal_set_message() and it worked!
But the bad side of it is that it works just perfect in the FireFox(3.5.6).
For me, in IE8 there is aslo some error:

Webpage error details

Message: Object doesn't support this property or method
Line: 72
Char: 3
Code: 0

I don't get even the upload window.

Eugen, how you think of it?

EugenMayer’s picture

bora please open a new issue, i dont think your one is related to this.
Please write down your jquery_ui module version and your library versin. Also your jquery_update version and wysiwyg module version. Thanks

EugenMayer’s picture

Status: Fixed » Closed (fixed)
realityloop’s picture

Devel enabled causes ajax error on attempted file upload at my end, disabling devel resolves error