Users with author privileges cannot create a proper gallery
-
When users with author privileges create a gallery, there are a some html code shows and gallery not shows properly. Also when the preview the private posts.
-
Hello,
the user creating the gallery must have the right to publish unfiltered_html. By default, only Administrator has this right, so only a user of this type can create galleries and edit them without problems.
That is, in order for the author to use my block, he needs to be given the right to publish unfiltered_htmlPS.
There are many different plugins for editing user experience (absolutely free).
Search on WordPress.org -> Plugins by sample search request – Role Editor.Thank you very much for your help! Now it works great!
I encounter the same issue with the administrator user role on multisite. Only the superadmin can work properly with the gallery and slider blocks.
Trying to manage the role of the user I found the administrator role had the capability “Unfiltered HTML” unchecked, i.e. it was off. I activated it but that didn’t help. After I save a post/page that has a gallery I get the gallery in the front-end as static images preceded by some HTML code like the one below:
{„copyRProtection“:false,“copyRAlert“:“Hello, this photo is mine!“,“sliderScrollNavi“:false,“sliderNextPrevAnimation“:“animation“,“galleryScrollPositionControll“:false,“sliderItemCounterEnable“:false,“sliderCaptionSrc“:“caption“,“sliderItemTitleEnable“:false,“sliderItemTitleFontSize“:18,“sliderItemTitleTextColor“:“rgba(255,255,255,1)“,“itemCounterColor“:“rgba(255,255,255,1)“,“sliderThumbBarEnable“:false,“sliderThumbBarHoverColor“:“rgba(240,240,240,1)“,“sliderBgColor“:“rgba(0,0,0,0.8)“,“sliderPreloaderColor“:“rgba(240,240,240,1)“,“sliderHeaderFooterBgColor“:“rgba(0,0,0,0.4)“,“sliderNavigationColor“:“rgba(0,0,0,1)“,“sliderNavigationColorOver“:“rgba(255,255,255,1)“,“sliderNavigationIconColor“:“rgba(255,255,255,1)“,“sliderNavigationIconColorOver“:“rgba(0,0,0,1)“,“sliderSlideshow“:false,“sliderSlideshowDelay“:8,“slideshowIndicatorColor“:“rgba(255,255,255,1)“,“slideshowIndicatorColorBg“:“rgba(255,255,255,0.5)“,“sliderThumbSubMenuBackgroundColor“:“rgba(255,255,255,0)“,“sliderThumbSubMenuBackgroundColorOver“:“rgba(255,255,255,1)“,“sliderThumbSubMenuIconColor“:“rgba(255,255,255,1)“,“sliderThumbSubMenuIconHoverColor“:“rgba(0,0,0,1)“,“sliderSocialShareEnabled“:false,“sliderZoomEnable“:false,“sliderFullscreenEnabled“:false,“modaBgColor“:“rgba(0,0,0,0.8)“,“modalIconColor“:“rgba(255,255,255,1)“,“modalIconColorHover“:“rgba(255,255,255,0.8)“,“shareFacebook“:true,“shareTwitter“:true,“sharePinterest“:true,“sliderItemDownload“:true,“shareCopyLink“:true,“tagsFilter“:false,“tagCloudAll“:“All“,“tagCloudBgColor“:“rgba(153,153,153,1)“,“tagCloudBgColorOver“:“rgba(253,253,253,1)“,“tagCloudTextColor“:“rgba(253,253,253,1)“,“tagCloudTextColorOver“:“rgba(153,153,153,1)“,“tagCloudFontSize“:16,“deepLinking“:false,“useLightbox“:true,“numItemsDisplayed“:0,“lazyLoading“:true,“contentNoPadding“:false,“galleryPreloaderColor“:“rgba(230,230,230,1)“,“galleryBgColor“:“rgba(0,0,0,0)“,“galleryBorderRadius“:0,“collectionThumbRecomendedWidth“:200,“thumbSpacing“:5,“externalLink“:true,“externalLinkDefName“:“Read More“,“externalLinkTextColor“:“rgba(0,0,0,1)“,“externalLinkBgColor“:“rgba(255,255,255,1)“,“externalLinkFontSize“:18,“captions“:true,“captionSrc“:“caption“,“captionHAlign“:“top“,“collectionthumbHoverTitleFontSize“:18,“collectionthumbRoundedCorners“:0,“collectionthumbHoverTitleTextColor“:“rgba(255,255,255,1)“,“collectionthumbHoverTitleTextBgColor“:“rgba(0,0,0,0.8)“,“collectionthumbHoverBgColor“:“rgba(0,0,0,0.4)“,“collectionThumbSubMenuDownload“:false,“collectionThumbSubMenuShare“:false,“collectionThumbSubMenuBgColor“:“rgba(0,0,0,0.4)“,“collectionThumbSubMenuBgColorHover“:“rgba(255,255,255,1)“,“collectionThumbSubMenuIconColor“:“rgba(255,255,255,1)“,“collectionThumbSubMenuIconColorHover“:“rgba(0,0,0,1)“,“galleryType“:“pgc_sgb_slider“,“galleryId“:“0b4eed0d_1611957629638″,“images“:[{„id“:2049,“title“:“ris“,“url“:… etc.When I go back to edit the post/page I find the gallery block showing this warning:
The block contains unexpected or invalid content. Try to restore the block.When restoring it like super admin it saves properly but no other role can do it.
@xseon For working with gallery blocks
1. Your user must have the right to publish unfiltered_html.
2. If you saved a page with a broken block, the block will not be restored to itself. You will have to try to restore or recreate this block. It’s just that if you saved a page with a problem, then you saved a problem.Sure, I understand that, so I gave that user the right you mention. Nevertheless, though he can restore the broken block right after hitting Save the block gets pale and brakes again.
You can access a test site with the problem here: https://megatron.bg/msite/test/wp-admin/
Superadmin credentials: xseon with pass 12-QWE-34
The other user: despet with pass des5rov
Go edit page ‘Начало’ when logged in as despet: https://megatron.bg/msite/test/wp-admin/post.php?post=2066&action=edit and just save the page. Then you’ll see the block brakes (fron-end: https://megatron.bg/msite/test/).
You can check the users capability and see the Unfiltered HTML box is checked for the groups despet is in.
Am I missing something?You can uncomment the lines at the end of the plugin.php file (in the root folder of the plugin) and thus you will give the right to a regular administrator to use the plugin. (below /** Multisite */ )
Or install this Unfiltered MU plugin and activate it on a specific site – this will give the right to all Editors.
And you can safely remove all the Rights Editors plugins that you installed, because this does not work now.
Thank you, Unfiltered MU solved the problem right away. Maybe you could incorporate it into your plugin to save its users all the trouble.
- The topic ‘Users with author privileges cannot create a proper gallery’ is closed to new replies.