You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nothing is actually broken here, but while submitting this theme to wporg, I got a warning about this custom shortcode that is not allowed in the theme. This custom [flexslider_gallery] shortcode is used to replace slideshow galleries (specifically) with a full-width flexslider slideshow that appears above the post title on single posts.
After looking into this, it appears the same functionality can be achieved using a filter on post_gallery. A filter is a much safer approach and less code is required to achieve the exact same result.
I should note that the custom [flexslider_gallery] shortcode is not publicly mentioned anywhere, since only the theme use it to replace the default [gallery] shortcode when the slideshow type is selected. No users would know it even exists without digging into the code. Removing it in favor of a more wporg-friendly filter will not cause any disruption for wpcom users.
The text was updated successfully, but these errors were encountered:
To test the fix, first create a gallery with the default shortcode: [gallery ids="123,124,125"] and you should see the standard gallery output in the_content below the post title.
Then, create a slideshow gallery like: [gallery ids="123,124,125" type="slideshow"] and confirm that the gallery gets removed from the_content and placed above the post title as a full-screen flexslider slideshow gallery.
Nothing is actually broken here, but while submitting this theme to wporg, I got a warning about this custom shortcode that is not allowed in the theme. This custom
[flexslider_gallery]
shortcode is used to replace slideshow galleries (specifically) with a full-width flexslider slideshow that appears above the post title on single posts.After looking into this, it appears the same functionality can be achieved using a filter on
post_gallery
. A filter is a much safer approach and less code is required to achieve the exact same result.I should note that the custom
[flexslider_gallery]
shortcode is not publicly mentioned anywhere, since only the theme use it to replace the default[gallery]
shortcode when the slideshow type is selected. No users would know it even exists without digging into the code. Removing it in favor of a more wporg-friendly filter will not cause any disruption for wpcom users.The text was updated successfully, but these errors were encountered: