Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding setting to enable/disable custom page templates #2923

Merged

Conversation

dparker1005
Copy link
Member

@dparker1005 dparker1005 commented Mar 29, 2024

All Submissions:

Changes proposed in this Pull Request:

Screenshot 2024-03-29 at 8 40 35 AM

Added a setting to the Page Settings page that allows admins to choose to:

  • Always use custom page templates
  • Use custom page templates only if they are compatible with their current version of PMPro
  • Not use custom page templates

By default, this is set to only using custom page templates that have versions that match the core page template versions. This should help to avoid issues where sites update to the newest version of PMPro and functionality on frontend pages breaks as a result.

For sites that are using a theme or 3rd party plugin that includes custom page templates, this can also protect them from authors that do not update their page templates or allow them to avoid using those templates for any other reason.

For sites that have built their own template and are ok being responsible for keeping them up to date, they can choose to always use page templates, regardless of version.

Other information:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you successfully run tests with your changes locally?

Changelog entry

Enter a summary of all changes on this Pull Request. This will appear in the changelog if accepted.

?>
</p>
<div class="notice notice-error pmpro_notification pmpro_notification-error">
<button type="button" class="pmpro-notice-button notice-dismiss" value="hide_pause_notification"><span class="screen-reader-text"><?php esc_html_e( 'Dismiss this notice.', 'paid-memberships-pro' ); ?></span></button>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we aren't going to allow dismiss in the banner, we should delete this close button.

@kimcoleman
Copy link
Member

Since this page can get long, we should duplicate the save settings button in all the section boxes. If we don't like that approach, we instead need to move the button outside the last box.

@dparker1005
Copy link
Member Author

Pushed those changes, thank you!

@ideadude ideadude merged commit 420cd71 into strangerstudios:dev Apr 11, 2024
@dparker1005 dparker1005 deleted the enable-page-template-settings branch April 11, 2024 15:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants