Send private message

You must be logged in to send a private message.

Friends

No friends yet.

Group membership

Activity

  • ChrisFr replied on the discussion topic Elgg 6.3.3 - Pages plugin
    Absolutely perfect ! Thanks again. view reply
  • ChrisFr replied on the discussion topic Elgg 6.3.3 - Pages plugin
    Thank you Nikolai. It works well ! But the writing dropdown list remains visible and displays "private". Is there a way to hide it? (I clear the cache before each test I run.) view reply
  • ChrisFr added a new discussion topic Elgg 6.3.3 - Pages plugin in the group Elgg Technical Support
    Hello, How can I make the pages in the pages plugin always "private" and remove the access dropdown list ? What do I need to change in the code ? Chris
    • Thank you Nikolai.

      It works well !

      But the writing dropdown list remains visible and displays "private".

      Is there a way to hide it?

      (I clear the cache before each test I run.)

    • Forgot about saving...

      Add a new event in your custom plugin:

      elgg-plugin.php

      'events' => [
              'fields' => [
                  'object:page' => [
                      \MyPlugin\Pages\FieldsHandler::class => ['priority' => 501],
                  ],
              ],
      ],

      Create a new file \mod\my_plugin\classes\MyPlugin\Pages\FieldsHandler.php

      <?php
      
      namespace MyPlugin\Pages;
      
      class FieldsHandler {
          
          public function __invoke(\Elgg\Event $event): ?array {
              $result = $event->getValue();
              
              foreach ($result as $k => $field) {
                  if (elgg_extract('name', $field) === 'write_access_id') {
                      unset($result[$k]);
                  }
              }
              
              $result = array_values($result);
              
              return $result;
          }
      }

      Note: your custom plugin must be placed under 'Pages' plugin on the /admin/plugins page.

       

       

    • Absolutely perfect !

      Thanks again.

  • The direct links to the cache work perfectly. Otherwise, it wouldn't work with other browsers. But I solved the problem !!! Apparently, Firefox was experiencing an intermittent cache management issue for the editor. (in my case) I... view reply
  • The problem is more difficult to reproduce with CKEditor, but with a little persistence, I get this: onmozfullscreenchange est obsolète. tagify.js:1:49314 onmozfullscreenerror est obsolète. tagify.js:1:49314 Le chargement du... view reply
  • And I want to make it clear that the problem is not present on other browsers (Opera, Chrome, etc.). In this case, the editor opens very quickly and never presents a problem. view reply
  • Thank you for your detailed response. For my tests, I'm using Firefox version 148 in Windows 11. I think you could reproduce the issue with this version, as I've encountered it on several computers. The first time I open the editing... view reply
  • Hello, The CKEditor OR TinyMCE editors don't always display correctly in Firefox. They appear briefly, then disappear for a few minutes. (It's random) I've reproduced this problem on several computers. This issue only...
    • CKEditor

      For Apache:

      Add the correct MIME type for `.mjs`:

      <IfModule mod_mime.c>
          AddType application/javascript .mjs
      </IfModule>

      Then restart Apache (for example, `systemctl restart apache2` or `httpd`).


      For nginx:

      Make sure `.mjs` is mapped to JavaScript in the `http` block:

      http {
          include mime.types;
      
          types {
              application/javascript  js mjs;
          }
      
          # ...
      }

      If you already have a `types` block with `application/javascript js;`, just add `mjs`:

      
      types {
          application/javascript  js mjs;
      }


      Then reload nginx:

      nginx -t
      systemctl reload nginx
    • TinyMCE

      These TinyMCE errors mean that the JavaScript files for icons and plugins are not being correctly loaded from the URLs TinyMCE expects (missing files, wrong paths, or HTML error pages instead of JS).

      - Check that the files really exist

      Open these URLs directly in the browser:

      - http://192.168.50.162/cache/1772092595/default/tinymce/icons/default/icons.min.js
      - http://192.168.50.162/cache/1772092595/default/tinymce/plugins/autosave/plugin.min.js
      - http://192.168.50.162/cache/1772092595/default/tinymce/plugins/emoticons/plugin.min.js
      
      etc

      - Run 'Upgrade' via administration to clean the caches

      - Clear the browser's caches

    • The direct links to the cache work perfectly. Otherwise, it wouldn't work with other browsers.

      But I solved the problem !!!

      Apparently, Firefox was experiencing an intermittent cache management issue for the editor. (in my case)

      I proved it by disabling "simplecache" in the administration panel, and it worked (slowly).

      So I re-enabled "simplecache" in the administration panel, and removed the "php_opcache.dll" extension from my PHP 8.4.18 server.

      Now it works perfectly with Firefox !!!

      Thanks, Nikolai, for your help.