Jump to content

Recommended Posts

Posted

Hi there,

I'm now inserting images into Rich Text Editors and learned that the height and width values are being explicitly set on the image tags. Can this behaviour be turned of so no dimensions are set?

Thanks.

Posted

Hi Marc,

Thanks for this link!

I haven't used TinyMCE before and am still getting to grips with ProcessWire. However, I'm sure it will help and I'll read it up thoroughly.

Cheers :)

Posted

Hi Marc,

Just to let you know that the following line:

extended_valid_elements:img[src|id|class|alt]

In the "Additional TinyMCE setting" textbox gives me exactly what I want! :)

Many thanks!

--Gary

  • Like 1
Posted

You mean if you initially resized the image? I'm unfamiliar with the exact workings of images but if they are resized after changes in the "Edit Image" page, I assumed it created another instance of the image with a different URL. If so, wouldn't the generated <img> tag still point to the correctly re-sized image?

I read your other thread yesterday, which was pointed out to me by Soma. I couldn't draw a conclusion from your comment. Are you suggesting that Ryan's suggestion to strip the height/width using a formatter is the better approach?

Thanks! :)

Posted

It does create a different image, that is not problem. But after initial image resize, when you next time edit the image in TinyMCE, the editor doesn't remember the width anymore and fallbacks to original size. Example: if you want to change left alignment to right, you also need to do resizing again, since TinyMCE doesn't know the size (it reads those from height and width attributes apparently).

Posted

Sorry :(

I didn't really mean it, but I thought it's something I would search first and then ask if nothing found. And as I know there was such a thread already I wanted to search it as I know it can be hard to find things here sometimes. I also suggest to use google "site:processwire.com keyword" search as it will be much more successful. ;)

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...