We recently discovered some forum posts were displaying fine, while others were displaying the HTML tags instead of using them as markup. On further investigation, I found the individual forums were not all configured identically and some had HTML disallowed, even though the default editor is a rich-text editor.
I did update most of the top-level forums. If you find a forum that hasn't been updated and your post is not rendered properly, please let us know. Some of the old forums aren't active much, and some are not relevant because of our site consolidation (the addons site forum and the wiki forum, for example)
Steve Twitter: @skenow Facebook: Steve Kenow
Now we may have something - each forum has its own setting for allowing HTML. This one didn't allow, until now.
Let's see what happens.
Steve Twitter: @skenow Facebook: Steve Kenow
the options display differently in different threads ???
Steve Twitter: @skenow Facebook: Steve Kenow
From a new post in an old topic - https://www.impresscms.org/modules/iforum/viewtopic.php?post_id=50656#forumpost50656
Wondering about the options below
Steve Twitter: @skenow Facebook: Steve Kenow
At this point, the default is to allow all comments if the module has comments (in icms_version.php). Probably since the base assumption is that ImpressCMS and predecessor were community sites and that would be the most common choice.
Also, all notifications defined in icms_version.php will be enabled by default.
Neither of these are reading anything from the module at the time of install.
However - you could override those options after the module is installed with the install function for the module, which is called at the very end of the process.
Steve Twitter: @skenow Facebook: Steve Kenow
How do i disable comments and notifications as default setting of a module preferences
and also set default permission of module when installing the module
is this possible? any example i can refer to ?
As a side note, this thread does not show paragraph tags when I post something new. Strange
Those issues are the same ones that I encountered during my tests. After that, I was investigating webpack, and there you can include files with a specific directive, and it tells webpack to make it a relative path.
Perhaps this kind of functionality should be left to the front-end developers and not taken on by the CMS?
A very good question. And it looks like it is only posts that have been made after the migration to ImpressCMS 1.4.0.
Why are the html tags showing in the rendered posts, now?
Steve Twitter: @skenow Facebook: Steve Kenow
There are minify and combine functions in the core - and currently left unused. Mostly because the resulting file was placed in the cache/ folder and at least one of the js and css files had some specific paths that didn't work when the file was in a different location.
Steve Twitter: @skenow Facebook: Steve Kenow
I found the locations in the header file where all the different files were loaded, and I included a switch statement so that I can switch the way includes are done by simply defining a boolean in the theme. When the boolean is true, I include a file 'combined.js' and 'combined.css', which are combined and minified versions of the different javascript and CSS files that are included at the moment. Whent he boolean is false, the old behaviour is still there.
This reduces considerably the loading time (first time at least) of a page. I still have some small issues with the minifying, but I think I have identified the problem.
I ran into something else - I had to update the system module to regenerate templates.
Steve Twitter: @skenow Facebook: Steve Kenow
icms_core_theme_Object does all the work, but the work to be done is defined in /header.php. Just search for ->addScript and ->addStylesheet
include/cp_functions:: icms_cp_header() creates the work for the admin area.
Steve Twitter: @skenow Facebook: Steve Kenow
The billboard module needs major updates and it is no longer used on the site at the moment.
I'll look into the icms_view_theme_Object, because I want to understand where the different javascript and CSS files get included in the core. I believe some of them are not needed on every page.
<p>I tested on the test website before pushing the new code to the production website, but didn't verify after that. Noted for the future.</p>
We're back in business - I deleted the contents of cache/ and templates_c/ and that resolved the issue.
Steve Twitter: @skenow Facebook: Steve Kenow
I'm not sure what happened, but since this update, I am not able to access the admin area - I just get a blank page.
Edit: just added this and saved. The HTML tags go away on the save, since the forum setting has changed.
Steve Twitter: @skenow Facebook: Steve Kenow
This is the question I had in the slack channel - "async deferred" can be used to move when the javascript is loaded. The actual place is during the renderMetas method of icms_view_theme_Object.
This works for most things and I have it running this way on several sites. The Billboard module does not work properly on the initial page load and renders separate images for each slide until you refresh (works sometimes)
Steve Twitter: @skenow Facebook: Steve Kenow