Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2018-01-31 07:26:08

Summer
Member
Registered: 2018-01-29
Posts: 60

Is there any plugin for inserting images when editing an article?

guys,Need to insert some pictures when editing the article, the official website of many plug-ins have lapsed. Recommended plug-ins?

Offline

#2 2018-01-31 21:00:28

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,305

Re: Is there any plugin for inserting images when editing an article?

Here’s a version of bot_image_upload that’s fixed for TXP 4.6. Don’t be fooled by its name, it’s not just about uploading images, it also inserts them for you at preset places. bot_image_upload creates a modified copy of the image panel in a lightbox above the write panel and lets you choose multiple images, displays them in the write panel and makes them draggable for ordering in your articles.

bot_image_upload used to work nicely in tandem with the multi-image drop-uploader abl_droploader. Not sure whether it still works with TXP 4.6.2.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#3 2018-02-01 00:34:03

Summer
Member
Registered: 2018-01-29
Posts: 60

Re: Is there any plugin for inserting images when editing an article?

uli wrote #309016:

Here a version of bot_image_upload that’s fixed for TXP 4.6. Don’t be fooled by its name, it’s not just about uploading images, it also inserts them for you at preset places. bot_image_upload creates a modified copy of the image panel and puts it in a lightbox above the write panel and lets you choose multiple images, displays them in the write panel and makes them draggable for ordering in your articles.

bot_image_upload used to work nicely in tandem with the multi-image drop-uploader abl_droploader. Not sure whether it still works with TXP 4.6.2.

Thanks, it does not work in 4.7.

Offline

#4 2018-02-01 12:13:22

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,305

Re: Is there any plugin for inserting images when editing an article?

TXP 4.7 is not yet officially released, not as a release candidate, not even in beta. Please give the community a little time to adapt the plugin to upcoming changes, and use the official 4.6 instead. There are quite a number of plugins to mimic many of 4.7’s improvements ahead of time. Just ask.

EDIT: Which of the two plugins, BTW, doesn’t work in 4.7 dev? Thanks.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#5 2018-02-01 12:39:35

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,615
Website

Re: Is there any plugin for inserting images when editing an article?

It’s bot_image_upload that doesn’t work. The admin layout has changed a little and some of the jquery used is now deprecated. I had a first attempt at introducing 4.7 compatibility, and it now works now with txp 4.7 beta but not everything is resolved.

Try the v0.6.6 packages here.

What’s currently not working:

  • If the iframe is reloaded, e.g. when you paginate, search, upload an image, the modifications to the iframe image panel are not reimplemented.
    • Did it do this in the past (I’ve not changed anything about this)?
    • Workaround: upload, then close the modal, then reopen and select the uploaded image
  • If going into an individual image in the iframe, the edit panel won’t show.
    • Workaround: close the modal and reopen…
  • Not everything that was previously hidden is now hidden, e.g. search options and list options, as the way they are realised in 4.7 has changed versus 4.6

Overall, in my view, the functionality this plugin adds is better achieved via another method than loading the image panel as an iframe. It’s too prone to breaking and ideally requires an own image picker.


TXP Builders – finely-crafted code, design and txp

Offline

#6 2018-02-01 13:48:20

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,305

Re: Is there any plugin for inserting images when editing an article?

jakob wrote #309026:

I had a first attempt at introducing 4.7 compatibility, and it now works now with txp 4.7 beta

<3

Kudos for your work on this and for bringing back the edit and delete icons. Thanks!

What’s currently not working:

I just saw that, when replacing an image — starting from an image contained in an article — after saving that change, the spinner spins endlessly and the article’s save button can only be pressed by closing the overlay via CSS with the inspector tool. ADDED: Ah, forgotten: The main image (not the thumbnail) is displayed in the Write panel after replacing an image. All is well after re-opening the article, though.

Last edited by uli (2018-02-01 13:53:19)


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#7 2018-02-01 15:25:40

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,615
Website

Re: Is there any plugin for inserting images when editing an article?

uli wrote #309027:

I just saw that, when replacing an image, after saving that change, the spinner spins endlessly and the article’s save button can only be pressed by closing the overlay via CSS with the inspector tool. ADDED: Ah, forgotten: The main image (not the thumnail) is displayed in the Write panel after replacing an image. All is well after re-opening the article, though.

I guess it needs more work. For now, I haven’t changed all that much, so why some things are now working that weren’t before and why other things that used to work aren’t now I’m not entirely sure. You can see my changes here. None of that affects the main operation of the plugin:

The spinner is shown while the content of the iframe-modal are fetched and parsed to remove unneeded items and add the bot_upload_image Select checkboxes. Once that’s succeeded, the spinner is hidden and the iframe shown. If something interrupts that process, the spinner stays there and the iframe-modal remains hidden, although it is there in the inspector.

My inspector console in firefox says:

Content Security Policy: 'x-frame-options' wird wegen 'frame-ancestors'-Direktive ignoriert.

… but it’s not doing anything across domains. That’s something new since 4.7 as stated here and here. These options can be overridden in config.php but I’m not sure how, or whether that is really the problem.

In Chrome it seems to be more forgiving but sometimes the ‘cancel’ button doesn’t bring back the article_image group like it normally does.


TXP Builders – finely-crafted code, design and txp

Offline

#8 2018-02-01 17:35:17

Summer
Member
Registered: 2018-01-29
Posts: 60

Re: Is there any plugin for inserting images when editing an article?

jakob wrote #309026:
Try the v0.6.6 packages here.

Thank you, it works, but there is a BUG, when you select the picture, and then edit the picture, click Save and then click Undo, it will disappear from the sidebar.

Last edited by Summer (2018-02-01 17:35:54)

Offline

#9 2018-02-01 22:40:25

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,615
Website

Re: Is there any plugin for inserting images when editing an article?

See if the revised v0.6.6.1 version works better for you.

That should resolve the disappearing window when editing an image’s details. Not sure that it resolves Firefox’s CSP complaints, though. Chrome seems not to have a problem.

BTW: I should add, I’m not the plugin author, just another txp user.


TXP Builders – finely-crafted code, design and txp

Offline

#10 2018-02-02 15:49:59

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,305

Re: Is there any plugin for inserting images when editing an article?

jakob wrote #309033:

BTW: I should add, I’m not the plugin author, just another txp user.

Julian, I might have added to that false impression by the hint in my posting.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

Board footer

Powered by FluxBB