Wrong images in the rich text editor when saving or publishing
I have a client showing me some weird stuff!! When inserting an image in the editor and hit the save button, the page is saved BUT the image changes to a totally different image with a completely differetn id and file name. What could be wrong?!
Yes, definitely, tried and tested. I'm having the exact same thing. I upload images into the WYSIWYG editor, they appear correctly, I save and they revert back completely to (seemingly random) wrong images.
Is there somewhere to officially document these bugs in the hope that they'll be addressed?
Just interested to know, did you upgrade any time recently? If so, what version to/from? Did you use the v3.5 web.config file? Any new packages installed?
Can anyone suggest how to go about debugging this? It just seems so odd - it's keeping the content of the WYSIWYG editor completely intact, just replacing the media items with other media items. I can't even think what would be causing this. I'm pretty sure it's not tinyMCE, as that would (if anything) break the file paths, it wouldn't just randomly select different media items.
Anders, just a quick note to say that I downgraded back to v4.0.2.1 and it's sorted the problem out for me. To detail exactly... I downloaded the v4.0.2.1 source files from http://umbraco.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=23321, unzipped, then uploaded the entire 'bin', 'install', 'umbraco' and 'umbraco_client' folders over the current ones.
I'm nervously anticipating something else cropping up when my client starts using the system again, but in the meantime this has held it together.
This has taught me a lot about backing up, restoring, upgrading and downgrading over the past week so in a way it was useful, but it's seriously been one of the worst working weeks I've ever had so if anyone knows of a way to document this bug I'd really like to do that.
Good luck with it Anders, I hope you get it resolved too!
Thanks for your help, i will try to downgrade as well to see if it will help me.
What is the chance to have a core team member reading this and comment on it? I can report it to codeplex but i cant reproduce the problem on other of our websites running 4.0.3 but something is wrong. Its not an anvanced website. I can give a core team member access to the website and talk them through to see if we cna find the problem in the source code and fix it.
By copying the files it automatically detected that I was migrating from v4.0.3 to v4.0.2.1 so it ran the 'upgrade' process automatically when I tried to browse the site.
Thanks. Do you have zip upload module installed? Your clients images do they have names like image_name_700x250, i know that there has been some problems with that as the image then get inserted as 700 x 200.
But not the problem we have as that inserts a totally different image, but maybe be related in some way.
I do have zip upload module installed yes. The client has uploaded hundreds of images, so perhaps some of them have the name formatted as you mention, but like you say, I'm doubtful as to whether that in iteself would create this bug.
I had this bug in a solution recently. I came about it by restoring a backup and I did the upgrade again. I just can't recall what I did different. Have you reported this as a bug on codeplex? I couldnt find it (as I wanted to give it my vote).
Sounds wierd! So just get back up of the 4.0.3 and upgrade again or did you get your backup of files for 4.0.2 and did the upgrade again? What about all the content ( without images ) the customers has created, until this error was found after the upgrade to 4.0.3?
I havent created it on codeplex as i didnt know if it should be created on codeplex. What are the chances for a bug with 2 votes to get seen and solved by the core team? And i dont mean that in a bad way. Just want info on it :)
Per from umbraco solved what the problem was. Its because of zipUpload that saves the images with a wrong id for the folder. I have made some code to fix the nodes, and move the files to the correct folders. But im going for vacation tomorrow so i cant manage to upload the fix. But will upload it soon and Tim will fix the ZipUpload module in the about 2 days.
Do you have an email i can send it to? I think i found the fix. But be sure to back the DB and website up before running it, as it changes in the DB and move files. Cant remember if the code work out of the box, but i think it does.
Ok, this is really weird. I haven't received Anders' code yet, but I've been trying to rebuild the media library by copying old images into new nodes created via the API using a slightly modified version of the code found in this forum post. That part is working fine - the "new" images are showing up in the frontend - but TinyMCE is still displaying random images as soon as I save/publish the document. Very bizarre, as I don't have this problem with images which are uploaded within TinyMCE itself, and I thought that the issue was related to a bug in the Zip Upload package rather than a more general issue with adding media via the API. Any feedback/advice would be greatly appreciated!
An update to the above: I noticed when I upload images into TinyMCE that the number in the image src path does not match the id of the node in the media library. For example, I have an image called "image.jpg" which has an id of 5036 in the media library but is referenced as "/media/91182/image.jpg" within TinyMCE. This image displays properly on my site, but i'm wondering what the number 91182 represents and if is there any way I can access that number through the API?
Now having the same issue on a fresh 6.0.2 install. Started happening after (instead of manually creating the image node) using the upload button in a media folder then uploading an .svg image. Then when inserting any image from another media folder into TinyMCE it would first show the correct image, but after saving or publishing the node it would revert to the first image of the damaged media node.
Workaround seems to be: remove and re-create all nodes in the damaged media folder. Luckily for me there were only a few, but there could be hundreds of course!
Steps to reproduce:
create a media folder F
use the upload button to upload a file
create 3 media nodes A, B, C in folder F
upload 3 images (in my case, .svg) to media nodes A, B, C
insert image of media node B into TinyMCE - image B displays correctly
save
inserted image reverts to incorrect image A
I'm not 100% sure whether the upload button needs to be used in folder F or whether any other folder may cause the same problem.
I'm also not sure whether this applies only to image nodes created after using the upload button or whether it also applies to pre-existing image nodes.
Wrong images in the rich text editor when saving or publishing
I have a client showing me some weird stuff!! When inserting an image in the editor and hit the save button, the page is saved BUT the image changes to a totally different image with a completely differetn id and file name. What could be wrong?!
<p><img src="/media/1568/Koncept_Huset_Type_1.jpg" alt="Koncept_Huset_Type_1.jpg" title="Koncept_Huset_Type_1.jpg" width="754" height="535" rel="824,583" /></p>
Gets converted to. As you see the alt tag is the same but the node is different.
<p><img src="/media/1229/tn_DSC_0539.JPG" alt="Koncept_Huset_Type_1.jpg" width="754" height="533" rel="1490,1000" /></p>
Any body from core or umbraco wizard knowing anything about this?
I think I'm having the same thing
Yes, definitely, tried and tested. I'm having the exact same thing. I upload images into the WYSIWYG editor, they appear correctly, I save and they revert back completely to (seemingly random) wrong images.
Is there somewhere to officially document these bugs in the hope that they'll be addressed?
Anders, did you manage to solve this?
Just interested to know, did you upgrade any time recently? If so, what version to/from? Did you use the v3.5 web.config file? Any new packages installed?
Can anyone suggest how to go about debugging this? It just seems so odd - it's keeping the content of the WYSIWYG editor completely intact, just replacing the media items with other media items. I can't even think what would be causing this. I'm pretty sure it's not tinyMCE, as that would (if anything) break the file paths, it wouldn't just randomly select different media items.
Anybody?
I updated from 4.0.1 to 4.0.3 and using the normal web.config. No new packages installed. Just the robots.txt, zip upload and config tree packages.
I dont know how to debug it either as its in the tinymce editor. This i a big problem and im not hoping it will start to do this on our big clients.
I think we need some umbraco wizard to help us here...
Anybody else having this problem or know how to solve it?? Our client is pretty angry about this.
Anders, just a quick note to say that I downgraded back to v4.0.2.1 and it's sorted the problem out for me. To detail exactly... I downloaded the v4.0.2.1 source files from http://umbraco.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=23321, unzipped, then uploaded the entire 'bin', 'install', 'umbraco' and 'umbraco_client' folders over the current ones.
I'm nervously anticipating something else cropping up when my client starts using the system again, but in the meantime this has held it together.
This has taught me a lot about backing up, restoring, upgrading and downgrading over the past week so in a way it was useful, but it's seriously been one of the worst working weeks I've ever had so if anyone knows of a way to document this bug I'd really like to do that.
Good luck with it Anders, I hope you get it resolved too!
Thanks for your help, i will try to downgrade as well to see if it will help me.
What is the chance to have a core team member reading this and comment on it? I can report it to codeplex but i cant reproduce the problem on other of our websites running 4.0.3 but something is wrong. Its not an anvanced website. I can give a core team member access to the website and talk them through to see if we cna find the problem in the source code and fix it.
Dan did you run the install process when down grading or only copy the files and thats it?
By copying the files it automatically detected that I was migrating from v4.0.3 to v4.0.2.1 so it ran the 'upgrade' process automatically when I tried to browse the site.
Thanks. Do you have zip upload module installed? Your clients images do they have names like image_name_700x250, i know that there has been some problems with that as the image then get inserted as 700 x 200.
But not the problem we have as that inserts a totally different image, but maybe be related in some way.
I do have zip upload module installed yes. The client has uploaded hundreds of images, so perhaps some of them have the name formatted as you mention, but like you say, I'm doubtful as to whether that in iteself would create this bug.
Hi all,
I had this bug in a solution recently. I came about it by restoring a backup and I did the upgrade again. I just can't recall what I did different. Have you reported this as a bug on codeplex? I couldnt find it (as I wanted to give it my vote).
/Jesper Ordrup
Hi Jesper,
Sounds wierd! So just get back up of the 4.0.3 and upgrade again or did you get your backup of files for 4.0.2 and did the upgrade again? What about all the content ( without images ) the customers has created, until this error was found after the upgrade to 4.0.3?
I havent created it on codeplex as i didnt know if it should be created on codeplex. What are the chances for a bug with 2 votes to get seen and solved by the core team? And i dont mean that in a bad way. Just want info on it :)
I've logged the issue: http://umbraco.codeplex.com/WorkItem/View.aspx?WorkItemId=26038 - please feel free to add detail and of course vote.
Jesper could you provide help quickly as our biggest client is having this problem at the moment!!
Per from umbraco solved what the problem was. Its because of zipUpload that saves the images with a wrong id for the folder. I have made some code to fix the nodes, and move the files to the correct folders. But im going for vacation tomorrow so i cant manage to upload the fix. But will upload it soon and Tim will fix the ZipUpload module in the about 2 days.
Hey Anders,
Any chance you could upload that fix? I've had the same problem and don't feel too confident about downgrading...
Mike
Hi Michael,
Do you have an email i can send it to? I think i found the fix. But be sure to back the DB and website up before running it, as it changes in the DB and move files. Cant remember if the code work out of the box, but i think it does.
Hey Anders,
You can reach me at leakybag _at_ gmail.com
Cheers!
Mike
Ok, this is really weird. I haven't received Anders' code yet, but I've been trying to rebuild the media library by copying old images into new nodes created via the API using a slightly modified version of the code found in this forum post. That part is working fine - the "new" images are showing up in the frontend - but TinyMCE is still displaying random images as soon as I save/publish the document. Very bizarre, as I don't have this problem with images which are uploaded within TinyMCE itself, and I thought that the issue was related to a bug in the Zip Upload package rather than a more general issue with adding media via the API. Any feedback/advice would be greatly appreciated!
Mike
An update to the above: I noticed when I upload images into TinyMCE that the number in the image src path does not match the id of the node in the media library. For example, I have an image called "image.jpg" which has an id of 5036 in the media library but is referenced as "/media/91182/image.jpg" within TinyMCE. This image displays properly on my site, but i'm wondering what the number 91182 represents and if is there any way I can access that number through the API?
Hi Michael,
Did you ever get anywhere with this or get the code from Anders? Having the same issue here on a fresh 4.0.3 install
Thanks,
Tom
Now having the same issue on a fresh 6.0.2 install. Started happening after (instead of manually creating the image node) using the upload button in a media folder then uploading an .svg image. Then when inserting any image from another media folder into TinyMCE it would first show the correct image, but after saving or publishing the node it would revert to the first image of the damaged media node.
Workaround seems to be: remove and re-create all nodes in the damaged media folder. Luckily for me there were only a few, but there could be hundreds of course!
Steps to reproduce:
Should be fixed in the latest nightly: http://issues.umbraco.org/issue/U4-1808
Jeroen
Thanks Jeroen.
is working on a reply...