I need to be able to apply a CSS style to images in the WYSIWYG editor of EES and I believe I have set it up correctly - entered the class names on the Styles page of the Design parse file (as per http://manuals.matrix.squizsuite.net/designs/chapters/design-asset/#Styles-Screen) and added a CSS file as a child of the same design file containing empty style rules (as per http://forums.squizsuite.net/index.php?showtopic=2170).
When I go into the WYSIWYG and attempt to add a style to some selected text, all is well - looking at the HTML source shows the <span> with the class created as expected.
However, when I select an image in the editor and apply a CSS style, nothing whatsoever happens! No <span>, no class applied to it, nothing.
So, that leads me to question whether it is actually possible to apply a CSS style to an image in this way?
Similarly, should it be possible to select an image and the following line of text (the image caption) and apply a CSS style? - that's not working for me either!
Can anyone enlighten me please or suggest where I might be going wrong?
Many thanks,
Stu
Apply WYSIWYG CSS style to an image
The wysiwyg editor (htmlarea) in matrix is so old, it's not funny. You will not be able to consistently style images using the style dropdowns. You're better off editing the insert image plugin to output the code you want.
[quote]
The wysiwyg editor (htmlarea) in matrix is so old, it's not funny. You will not be able to consistently style images using the style dropdowns. You're better off editing the insert image plugin to output the code you want.
[/quote]
Sadly I can't do that because of the nature of the server and Matrix setup I am sharing. Looks like I'm going to have to look for another solution.
What I need to do is get images in my body content into a containing div, span or paragraph, along with the image caption text. I was hoping to allow my content editors to be able to style images in this way using the WYSIWYG, but it looks like I will have to either get them creating divs and coding the container in or I will have to put images onto pages as the admin user. Not ideal and I can't believe Matrix doesn't have a way of doing it for the non-technical editor but thanks for your reply anyway
Cheers
Stu
I'm all sorted now, thanks, by simplifying my html/css so that the user gives the image a class when they add the image to the page, and they give the caption a css style using the drop down box.
So, thanks for your replies, but I've got there in the end!
Funny though, I subsequently discovered that it is possible to add a CSS style using the drop down box in Firefox but not in Internet Explorer. I loathe Microsoft!
Cheers
Stu