info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by Raül Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
- Nikolai Shcherbin@rivervanrain

Nikolai Shcherbin - 0 likes
6 - Save and activate My plugin via administration. Now you can freely crop avatars as you wish ;)
- MillaGR@MillaBG

MillaGR - 0 likes

- Nikolai Shcherbin@rivervanrain

Nikolai Shcherbin - 0 likes
where, w - width, h - height, Be careful, all symbols are important. 2 - Create a new file \mod\my_plugin\classes\MyPlugin\SetIconSizes.php 3 - Open SetIconSizes.php and add this example code Change w\h on your custom sizes. You can ignore some sizes, e.g. small, tiny; just use default sizes and values. You may need to clear the cache - run 'Upgrade' via administration. - you need to recreate your avatars to overwrite previously saved icons on your server,
- Elgg's design may not be compatible with your custom icon sizes so there may be some issues in UI.
- MillaGR@MillaBG

MillaGR - 0 likes
You must log in to post replies.1 - Download this plugin
2 - UnZip and upload folder my_plugin to /mod
3 - Don't activate this plugin yet.
4 - Copy file from
\vendor\elgg\elgg\views\default\entity\edit\icon.php
to
\mod\my_plugin\views\default\entity\edit\icon.php
(Create non-existent folders)
5 - Open icon.php and change code on:
Thank you very much for your help, really.
I can now crop it as I want, but when it is displayed on the profile, it is still square and not the cropped image in a rectangle.Could you tell me why?
By default, Elgg config has these sizes for avatars:
You can override this config via custom plugin.
Use My plugin again.
1 - Open elgg-plugin.php and add this code before last ];
Please note:
Learn docs.
It worked perfectly! Thank you so much, really. You saved me. Big hug.