Open Bobbycharlton1 opened 5 years ago
There are some issues with forum attachments indeed.
Related #3496
In 2.3.3 there are still some issues. Even if I set img width to 1024 in forum admin with a 56kb file measuring 495 x 700 I get a 'file too large' message with upload limits set at 20mb
Now having updated from V1.1.4 to 2.3.3 I noticed a folder inside the forum plugin 'attachments' so none of the existing ones appeared. (I had a modified setup storing attachments by user id in the forum plugin folder so don't know about the OE 1.1.4 setup)
Looking at the posts that have been moved from V1.1.4 to v 2.3.3 none of the existing images appeared even though I still have the old 'attachment' folder in place.
But by removing the {e_PLUGIN} from the IMG link path and replacing with a full http:// link the images appear, so is there a shortcode issue with {e_PLUGIN} in the forums?
EDIT:
OK digging a bit further, if I copy the old 'attachment' folder into e107_images, and use the {e_IMAGE} shortcode instead of e_PLUGIN in the old forum posts then the old attached images show in forum posts so I can live with that.
But adding images to new forum posts is still an issue for me.
Well image attachment does work now using php 7.4 but, there is only the option to attach 1 image, nothing shows on 'preview' but the image appears if you simply add 1, don't preview i, just post.
However, IF you go and 'edit' the post, there is no image path to see, copy or edit so there are some issues.
To have this topic complete: preview worked in 2022 https://github.com/e107inc/e107/issues/4726
To have this topic complete: preview worked in 2022 #4726
No idea why then, but for me using bootstrap5 theme, preview shows nothing, post edit shows nothing, no path to the image when logged in as main admin in Firefox or chrome using the full v2.3.3 file download from e107.
Integrity check doesn't show any errors either
OK More Info:
PHP Errors
You are right. It stopped working for me too - I have the updated version of the forum plugin from 2022, I just checked this one when I was sure it worked. I have a local version of bootstrap5 used (not CDN).
The code is correct, check your console for javascript error.
Uncaught TypeError: Cannot read properties of undefined (reading 'classList')
at Hi._isAnimated (bootstrap.bundle.min.js:6:53067)
at Hi._initializeBackDrop (bootstrap.bundle.min.js:6:51282)
at new Hi (bootstrap.bundle.min.js:6:49838)
at Hi.getOrCreateInstance (bootstrap.bundle.min.js:6:6729)
at HTMLAnchorElement.<anonymous> (bootstrap.bundle.min.js:6:54365)
at HTMLDocument.n (bootstrap.bundle.min.js:6:4406)
Sorry, you lost me now with js error. Tried with & without CDN in 'Libraries' and both cdnjs and jsDelivr all with the same result, nada.
@NECPWAweb my modal is not working because this error after click on attachment preview: (F12, console tab). It can be frontend theme issue, investigating now.
OK just to clarify, I have 'Hero' Downloads, Sitemap and forum plugins installed on site.
Preview in latest 2.3.4 (just synced)
core bootstrap5 theme, core forum plugin, it works.
Now I need to find why it doesn't with my bootstrap 5 theme...
EDIT - solution
My theme.html file was missing {---MODAL---}
shortcode. So forum modal didn't work.
in your source code you must have <div id="uiModal">
element
Tested: latest core + core forum plugin latest core + custom forum plugin custom theme + custom forum plugin
All that appears in my core 2.3.3 bootstrap5 theme.html is: {---MODAL---}
What needs to be added for the full element as there is nothing in core bootstrap3 either in the 2.3.3 release?
in e107 V1 I could attach multiple files/images to a forum post. in V2 it allows only 1? then if I press preview, it does not show a preview of the image I attached?