If you don’t want users to be prompted to switch to a different plan when they run out of allowable posts on their current plan, this snippet will do the trick.
If this snippet helped, feel free to buy me a taco :)
JS Code SnippetOn the page you want this to appear, add an HTML widget (FREE) and paste the code in there. Be sure to have < script> before your code and after the code if it isn't already inserted above.
Instructions
Be sure to change the URL to the one you need to remove. Including domain and the "create" page. Easier to not put the code in yet, copy the link from the button then paste it in that section.
// Example: Remove all elements with a specific URL
document.addEventListener('DOMContentLoaded', function() {
var links = document.querySelectorAll('a');
links.forEach(function(link) {
if (link.href === 'https://staging.mdsmokefree.com/shop-owner-pricing/?redirect_to=https://staging.mdsmokefree.com/create-shop') {
link.parentNode.removeChild(link);
}
});
});