Hey Guys,
Just trying to work out how to prevent TinyMCE from inserting the align attribute on images. It’s one of those cases where I need to build in a strict doctype and this doesn’t allow for the align attribute to be used.
Any help would be greatly appreciated.
Thanks in advance,
Hi jonrawlins,
strange, i don’t have any align attributes inserted by TinyMCE (MODx 1.0.4/TinyMCE 3.3.5.1), to position images i add a css class btw. // image editin PopUp -> Appearance -> Class ( one of the css classes you define under configuration -> inteface & feature -> css selectors)
j
Hmmm, I am using the same version however the TinyMCE selected within the configuration options is set to "creative". Just out of interest which are you using?
I am unsure myself why it does it. I may have to switch over to not using the image widget for that particular TV. Just need to limit the size that the image will display etc.
Yea it is, I will just have to revert to a standard tv to get around the problem.
Thanks for the help though. Just hacking TinyMCE to allow/disallow attributes is not an option for me currently.
Thanks again.
No problems, the issue is...
I am creating a portfolio using chunks for each document. For the portfolio docs I have a TV that you can select an image from a directory and it will display the image within the anchor tag therefore making the image clickable to view a pdf (This is how the company I work for show their work).
However, the image that get’s inserted into the variable placeholder on the page when loaded has align="none" assigned to it which I need to prevent.
I hope this explains a little more, I should be able to get around it if I manually create the image tag within the chunk. Just wanted to make less maintence in the future etc.
maybe don’t use the image widget for the output and create the structure of the image tag from within your chunk