Insert Attachment All

Insert Attachment All 1.4

No permission to download

AndyB

Well-known member
AndyB submitted a new resource:

Insert Attachment All - Inserts all attached images into messages.

Description:

The Insert Attachment All add-on is designed to insert attached images into messages. So instead of the thumbnail attachments showing below the message, the add-on will insert the the full size BB Code as seen here:

View attachment 72418

Those viewing your forum will enjoy not having to click thumbnails to view full size images.

Note: This add-on is designed to be used once, it will check every post on your forum and insert any attached images that have not...

Read more about this resource...
 
The addon works great. However we imported the forum from VB so the attachments are not inserted in their original location in the post. Instead I see
Code:
[attachment=4:2o4oestg]xxxxxxxx.JPG[/attachment:2o4oestg]
[attachment=3:2o4oestg]xxxxxxxx.JPG[/attachment:2o4oestg]
[attachment=2:2o4oestg]xxxxxxxx.JPG[/attachment:2o4oestg]
and the attachments are inserted at the bottom of the post. Is there anyway to insert in the correct location?

Edit: I think those links are from my earlier import from phpbb into VB.

After moving on from first thousand posts all attachments appear to be in thumbail format.

And this plugin is attaching the full size image at the end of the post. So now I can see both a thumbnail and the full size image.

Edit2: Found a solution to my problem

I just ran this query
Code:
UPDATE xf_post SET message = REPLACE(message,'[ATTACH]','[ATTACH=full]');
 
Last edited:
Hello! I have some questions about this add-on.
Is it correct I understood that this add-on is changed the full images to a thumbnail in all posts in forum, the previous ones and the following?
 
Will this check to see if there is already an attach code in the message before adding it? I don't want duplicates in new posts where your other add-on already added that code! Thanks!

-- EDIT --

Got a response from the author, and did some testing - the add-on will NOT create duplicates. Xenforo will remove the "box" attachment as well when it finds the ATTACH tag. Works great! Thanks @AndyB!
 
Last edited:
Will this automatically embed image attachments into posts in the future? Or do I have to run this addon again?
 
I just tested this and it does not show the image in the post. If I edit the post, the image shows up until I refresh the page and the image isn't displaying.

Will keep testing ....
 
Last edited:
We have an addon that inserts attachments (as full or thumbs) after saving a thread. And we have an addon that inserts attachements full instead of inserted thumbs. This is really nice, thank you, Andy.

But how i can run through the database and insert all attachements that have no tags inside the text?
I dont want to press now some thousands time to open the page, to edit, to edit again, to save ... I am shure there is a better solution.
But where can if ind it, please?

-----

So maybe i have a cache issue also, but now i have no idea what to do.
The list runs and shows my posts with attachements not in the message text, but makes nothing to them. :(
 
Last edited:
Finally i understand where to press the link to update the posts listed.
Probabyl a text-decoration:underline or a button would be really nice for blind people like me. :)
 
Last edited:
I dont know how and why, but now i have a lot of posts with

attach=full inside the text where users wanted them to be and a second time at the end again.
Is there any clever regex or an ideao how to filter them and remove the attachments at the bottom only if they are inside the text also?


Code:
[ATTACH=full]59944.vB[/ATTACH]

Text

[ATTACH=full]59945.vB[/ATTACH]

Text

[ATTACH=full]59946.vB[/ATTACH]

Text

[ATTACH=full]59947.vB[/ATTACH]

Text

[ATTACH=full]59948.vB[/ATTACH]

[ATTACH=full]59944[/ATTACH]

[ATTACH=full]59945[/ATTACH]

[ATTACH=full]59946[/ATTACH]

[ATTACH=full]59947[/ATTACH]

[ATTACH=full]59948[/ATTACH]

Maybe that .vB was the problem for the addon to decide not to put in the pictures again?

What can i do?
Ask if there is a attach]xxx.vB[/attach and then replace the bormal one without .vB ?
 
Back
Top Bottom