mark l chaves
Forum Replies Created
-
Hi @lisamaryburke,
Would you mind reaching out to us at this link?
https://code-atlantic.com/contact-us/
That way we can exchange more details in a private channel to see what’s going on.
Thanks so much 🙂
Hey @paulabender,
We haven’t heard back from you.
We’re going to close this thread. Feel free to post a new issue or contact us directly if you need help with anything.
https://code-atlantic.com/contact-us/
Cheers 🙂
Hi @redbulb,
Apologies for the delay.
Thanks for clarifying your feature request. This might be doable. Meaning looping through all restrictions to see if there’s an allowable restriction further down the chain (instead of bailing on the first blocking restriction).
Let us see what we can do and we’ll get back to you!
Cheers 🙂
Hey @ronhorne50,
Thanks so much for posting. We’re sorry you’re seeing only a blank page coming up.
Right off the bat, we see 2 JavaScript errors in the console when we visit that My Courses page.
https://share.wppopupmaker.com/NQuYGYXe
The first thing to do is rule out these errors. They might be coming from something called Divi Bars?
If so, can you temporarily disable that plugin to see if that clears things up and allows Content Control to function?
If that doesn’t work for any reason, please submit a help ticket so we can take a closer look.
https://code-atlantic.com/contact-us/
Much appreciated!
Hey @dominmax,
On top of what @belimperial suggested, your second option should work too.
If you can edit your
.vpc-successdiv, you should be able to add thepopmake-closeandpum-closeclasses to that div. Adding these 2 extra classes will make your div behave like a close button for that popup.Here’s an HTML code example of what I mean.
<div class="vpc-success popmake-close pum-close">Click here to close</div>Thanks!
Forum: Plugins
In reply to: [User Menus - Nav Menu Visibility] Menu visibilityHello @misterraiden,
Thanks so much for posting. We’re sorry you’re not able to save multiple roles.
Can you please first check your PHP
max_input_vars? If it’s only at 1000 or so, we recommend updating your php.ini or user.ini to have at leastmax_input_vars=2500If you’ve never edited either of those files before, please check how your hosting provider recommends updating them. They might need to make the update for you.
You can also see if you have any PHP messages in your error logs or run the Query Monitor plugin while trying to select multiple roles. Both of these ways will confirm if you’re getting a PHP error.
Cheers!
Forum: Plugins
In reply to: [User Menus - Nav Menu Visibility] User Minimum Role not WorkingHi @devonsays,
Thanks so much for posting. We’re sorry you’re seeing an issue with your student and group leader roles.
Unfortunately, we haven’t seen that issue ourselves.
Here’s the test case we just ran:
1) Created a Group Leader role.
2) Assigned a user the roles Editor, Tester, and Group Leader.
3) Created a Post link menu item to a test post.
4) Set Who can see this link? to Logged in Users.
5) Clicked Choose which roles can see this link.
6) Clicked only the Group Leader role.
7) Clicked Save Menu.
8) Logged in as the user from step #1 (editor, tester, group-leader). The test Post link appeared in the menu (expected for a Group Leader).
9) Logged in as a subscriber. The test Post link did NOT appear (expected for a non Group Leader).
As an alternate case, I changed the Post link menu item to allow the Admin, Tester, and Group Leader roles. This worked as expected.
Have you tried other combinations just to see what happens? Can you also make sure you’re not getting any JavaScript errors in the browser console (to rule out plugin conflicts).
If you’re still getting unexpected results, would you please reach out to us using this link?
https://code-atlantic.com/contact-us/
That way we can have a closer look using a secure channel.
Thanks so much :-)`
Hey @rajatag,
Thanks for posting and for your kind words 🙂
We’ve just just reproduced the issue. We’re investigating it now. We’ll keep you posted.
Cheers!
Hi @andrewmperryman,
Just letting you know that we can reproduce the issue. We’re having a closer look now.
We’ll keep you posted!
Hello @lisamaryburke,
Thanks for reaching out.
You can search for a user role plugin.
Once you use a plugin such as User Role Editor to create your roles, you’ll see your new roles show up in the Content Control Restriction Editor under the General tab for the Logged in Users setting.
Check the roles you want to have access. Then, you can set up your Product Category restriction under the Content tab.
We hope that helps.
Let us know how that works out for you 🙂
Hello @paulabender,
Thanks for posting.
The Content Control plugin doesn’t support menu items. It’s great for restricting access to posts, pages, media, products, categories, and tags.
The good news is there are other plugins that can do this for you.
You might want to check out our sister plugin, User Menus.
We hope that helps.
Let us know if you need anything else.
Have a great day 🙂
Hey @jillyspence,
As @bcworkz mentioned, there are syntax errors in your PHP code. See the screen capture.
1) Line 17 has a missing beginning single quote (
').2) Line 25 has a mismatching pair of quotes.
3) Line 25 starts an array with a left curly bracket instead of a left paren bracket.
Those are just for starters. I think there are more.
I think you should:
1) Start out with a minimal working example. There are many working examples online for you. Here’s one.
// Use a code snippets plugin or child theme functions.php file. add_action( 'wp_head', function() { ?> <script> /* write your JavaScript code here */ console.log( 'Hello, World!'); </script> <?php } );2) Add your code bit by bit and test each time. The last bit you added before your code breaks is usually the culprit.
3) Think about using a code snippet plugin instead of a child theme’s functions.php file. I’ve worked for 3 different plugin companies and we always recommend this to our customers. I hardly use a child theme let alone a functions.php file myself these days.
Good luck!
- This reply was modified 4 years, 9 months ago by mark l chaves. Reason: Typo
Forum: Developing with WordPress
In reply to: When PHP variable’s value change.Hi @roelfk7,
Just to throw out a couple of live examples.
1) You can use an API to fetch your current price. E.g., https://codepen.io/marklchaves/pen/wveyxoa
2) You can use AJAX to hit your DB for the current price. E.g., https://streetphotography.blog/ajax-random-number/
Example snippet for the AJAX option.
setInterval(function () { // Just run this on the AJAX Random Number post. if (!document.URL.includes("ajax-random-number")) return; $.ajax({ url: ajaxurl, cache: false, data: { action: "random_number_request", // This is your PHP function that can hit the DB. }, success: function (data) { const bid = 1.05; // Stub as float. const status = data == bid ? "WINNING" : "LOSING"; // data is a string so use == to coerce $("#random").text(<code>${data} ${status}</code>); }, error: function (errorThrown) { window.alert(errorThrown); // Change to console.log for prod. }, }); }, 2000); // setInterval()Good luck! 🙂
Hey @andrewmperryman,
Thanks for the heads-up. We also appreciate your kind words.
We’ll try to reproduce the issue and circle back with you after.
Have a great weekend 🙂
Mark
Hi @eddierosenthal,
We haven’t heard back from you.
We’re going to close this thread. Feel free to post a new issue or contact us directly if you need help with the Content Control plugin.
https://code-atlantic.com/contact-us/
Cheers 🙂