Posts by CodeBrewery

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Yup, encountered this when a client (not Envato-related) complained they couldn’t add another link to their menu and the menu itself was going all over the place after the failed attempt at adding the 89th menu item. Just like @FinalDestiny, I don’t think there’s another fix apart from increasing max_input_vars.

By the way, this thread was really helpful for me at the time this happened (roughly 1.5 months ago). Also, I enjoyed reading this StackExchange answer, too.

Bottom line for me is, do not sweat it. If a client approaches you with this problem, your best bet would be to explain to them why this happens (PHP security reasons, etc.) and even try to educate them that a 90-item menu is an abomination. I tried to talk sense into my client, but we ended up increasing max_input_vars and he kept the humongous menu. Oh well…

P.S. Out of curiosity – would this happen if there were, say, 2 menus of 50-60 items each?

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Hi Graeme,

This is a public forum and in most cases we can’t do much else than point you in the direction of your item author’s support venue.

However, I had a look at the template you mentioned and you simply need to replace one_third with one_fourth and you will have your images in four columns while retaining the right-hand divs (Information and Latest post).

For future reference, you can have a look at the grid system used in your template by finding layout.css which is located in the styles folder.

Hope this helps!

Cheers,
Ivelin

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Leo, thanks for the link, it was really useful having it!

Because of this question on SO I got the idea to play around with the URL parameters and see if it does anything. Adding &pagename=photo to the end of your URL pointed to the correct page.

I think the solution you are looking for is outlined in this Tuts+ tutorial – navigate to “Step 3 Page Templates”. Here is also the relevant page in the Codex – where it says “Pagination note”.

Let me know if this sheds light over what’s going on!

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Can you set up a demo area on your site and let me have a look? I may well be missing something important, but the code you posted looks correct.

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

You need to place the pagination functions and the reset_postdata call inside the Loop. I trust you have done this?

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Not sure if you have updated the live site (I checked the link from your OP), but for the pagination to show, you will need more than 8 posts – in your case, photos.

Also, make sure next_posts_link and previous_posts_link are right after endwhile; and that they are followed by wp_reset_postdata(). You want all of this happening inside your shortcode function, I would think. ;)

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Hey Leo,

Without being much of an expert in WordPress, I’m thinking the following:

In the WP_Query args set posts_per_page to 8, then trigger pagination by displaying the next_posts_link and previous_posts_link after your endwhile. Do not forget the “paged” parameter – you can read how it is used with WP_Query here.

It seems you will also need an additional wrapper around the UL so the pagination is outside the list. Then it’s up to you to figure out what to do with these links.

Let me know if I have misunderstood the question or anything, because I just got up and I’m still sleepy. ^^

Cheers,
Ivelin

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Hey,

First thing that comes to mind is the Icomoon app and its library.

Alternatively, have a look at the Themify.me icon set, it looks quite nice. I wouldn’t have known about it if it weren’t for a buyer of mine, but they are lovely indeed.

A third option is this CodeCanyon WP plugin by Themeva.

Fourth option – this collection of icons. I found the site only today so haven’t had the time to properly look around and to read the licensing / terms&conditions part. Heck, I’m not even sure how this site works yet! ^^

Probably there are tons more that are better, but those are the ones that I know of. Hope I’ve been helpful!

Cheers,
Ivelin

P.S. I’m sure you’ve seen Linecons all around TF and know about them, but if not, check them out – they are SO good!

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Hey Mel!

If I have understood you correctly, you are looking for this, which is powered by jQuery BBQ.

Have a read here to see how Isotope is combined with BBQ for a filterable portfolio.

Alternatively, this shows integration with tabs.

Let me know if this was any help!

Cheers,
Ivelin

36 posts
  • Has sold $100+ on Envato Market
  • Has been part of the Envato Community for over 3 years
  • Located in Bulgaria
  • Sells items exclusively on Envato Market
CodeBrewery says

Hey,

I can’t say much about your first question (saving plugin settings) because I haven’t had to do this anywhere yet.

Re: admin panel and WordPress settings, I don’t know if this is the correct/best way to handle these things but here’s what I do:

1. Check user capabilities. You can look at this Codex page for each user role’s capabilities. Then you do if ( !current_user_can('update_core') ) (for example) inside a function hooked on admin_menu and call remove_menu_page($menu_slug) where $menu_slug can be “tools.php” or “upload.php” or any top-level page slug.

Here’s how it would look:

add_action('admin_menu', 'some_function');
    function some_function() {
        if( !current_user_can('update_core') ) {
            remove_menu_page('upload.php');
            remove_menu_page('edit-comments.php');
            remove_menu_page('profile.php');
            remove_menu_page('tools.php');
        }
    }

2. The problem with the above is that even though the links are removed, the pages can still be accessed by typing the respective URL. So the page doesn’t exist in the menu but can be accessed at http://something.com/wp-admin/menu-slug.php To counter that I hook a function on admin_init which works with the global $pagenow; it trims the .php ending and compares what’s left with a set of page names like “uploads”, “profile”, “edit-comments”, etc. If they are equal, I do a simple redirect like this – wp_redirect(home_url());. Here’s the whole code:

add_action('admin_init', 'another_function');
    function another_function() {
        global $pagenow;
        $shrt = str_replace('.php', '', $pagenow);
        if ($shrt == 'upload' || $shrt == 'edit-comments' || $shrt == 'profile' || $shrt == 'tools') {
            wp_redirect(home_url());
        }
    };

Once again – this is how I personally do it and seeing how I s*ck at WP compared to the many amazing developers here, there may be a better way.

Hope I’ve given you some basic direction to solve your problem.

Cheers,
Ivelin

by
by
by
by
by
by