Themify Review – A Diverse, Versatile and Highly-Capable WordPress Theme Shop

Looking for that perfect WordPress theme? It’s easy to get lost, I know. Unfortunately, however, choosing the right theme can make or break your site’s chances of success, so it’s not a decision to undertake lightly. The problem: with so many thousands of themes out there, it’s difficult to settle on just one. I’ve lost… View Article

The post Themify Review – A Diverse, Versatile and Highly-Capable WordPress Theme Shop appeared first on WinningWP.

Powered by WPeMatico

A Collection of the Best WordPress Photography Themes for 2016

If you’re looking to create an online photography portfolio to show off your skills and promote your services, there’s a number of relatively obvious things you’ll clearly need to consider, such as ensuring your photographs are all presented in the very best light possible. However, when it comes to choosing the perfect WordPress theme for… View Article

The post A Collection of the Best WordPress Photography Themes for 2016 appeared first on WinningWP.

Powered by WPeMatico

MyThemeShop Review – A Superb Value WordPress Theme Club

When choosing their preferred theme and plugins, WordPress users are spoiled for choice. With the official repository, dedicated marketplaces, and various different WordPress shops to choose from, there are literally thousands of options — so many in fact, that it can all-to-easily become difficult to make any kind of decision at all! Making the right… View Article

The post MyThemeShop Review – A Superb Value WordPress Theme Club appeared first on WinningWP.

Powered by WPeMatico

Debugging JavaScript Events: Why Does It Do That When I Click This?

Sometimes things happen on a page that you can’t figure out. You click on a link and nothing happens; you submit a form and a modal pops up. Something is happening in JavaScript, but you can’t figure out where.

Enter, once again, the Chrome Developer Tools.

Let’s say we have a link on the page that when clicked, instead of taking us to the URL in its href attribute, throws error messages all over the page randomly. A quick search all of your codebase returns no clear clues towards what script could be causing it. There are either too many references to the link to filter through, or nothing that seems to point directly to this link. We need to check what events are bound to this DOM node.

To do this, open up Chrome on the page, right click on the element, and click “Inspect Element.” This opens up the familiar Chrome Developer Tools. Hopefully you are already familiar with the basics here, inspecting elements and their styles, and basic JavaScript debugging (if you aren’t do yourself a favor and do a bit of looking around and look up some tutorials!). What interests us now is the “Event Listeners” tab on the right in the elements screen (which should be the screen that opens when you use “Inspect Element”).

Screenshot 2015-12-28 16.15.01

Under this panel, you should see a bunch of expandable event names and under each links to the functions that are bound to that event on the currently selected element. For our example, we should check out the click event to see what scripts we have bound to that event. On the left, we can see the DOM node the event is specifically bound to (events can be bound to a parent object listening for actions on child objects), and on the right, we can see the script and the location in the script of the function that is bound to that action.

Screenshot 2015-12-28 16.17.22

Clicking on that file name will bring us to the Sources page of the Developer Tools with that file shown. From here you can read through each function bound to the event and find which seems most likely to be the one triggering the behavior you are trying to figure out. You can add breakpoints and pause the code mid-execution to check exactly what is happening that may be causing the issue.

If the code is minimized make sure to click the “Pretty Print” button in the bottom left of the source view to expand out the code for easier reading, turning this:

Screenshot 2015-12-28 16.23.22

Into this:

Screenshot 2015-12-28 16.25.15

Much better, right?

Do you have any questions? Other tips you’d like to add to the mix? Throw them in the comments below!

The post Debugging JavaScript Events: Why Does It Do That When I Click This? appeared first on WebDevStudios.com.

Powered by WPeMatico

A Collection of the Best WordPress Review Themes for 2016 and Beyond

Before buying a product, most consumers head online to research their potential purchase. Interestingly, many would admit to being swayed by impartial reviews when assessing a product’s merits (and weaknesses). This behavior means review websites are big business these days. Whether you want to promote your own items or earn affiliate commissions by recommending others’,… View Article

The post A Collection of the Best WordPress Review Themes for 2016 and Beyond appeared first on WinningWP.

Powered by WPeMatico

WooCommerce, Easy Digital Downloads or iThemes Exchange – Choosing the Right WordPress eCommerce Plugin

Largely due to the success of enormous eCommerce sites like Amazon, people are increasingly becoming more and more comfortable shopping online — something that more and more business are beginning to take advantage of. Essentially, there are now more opportunities than ever before for people like you and me to make a living by selling… View Article

The post WooCommerce, Easy Digital Downloads or iThemes Exchange – Choosing the Right WordPress eCommerce Plugin appeared first on WinningWP.

Powered by WPeMatico

Five Of The Best WordPress Review Plugins For 2016

From product, to film, to restaurant reviews, the internet has given everyone a voice to share their opinions on just about anything. This has made reviews an important part of modern life, with an abundance of reviews now available online. With so many reviews just a mouse click away, most of us jump online to… View Article

The post Five Of The Best WordPress Review Plugins For 2016 appeared first on WinningWP.

Powered by WPeMatico

15+ Stunning Examples of ThemeForest’s Popular Brooklyn WordPress Theme in Action

If you’re looking to buy a new theme for your site, it’s almost always worthwhile taking a look at a handful of live examples of websites using the exact same theme you’re considering before taking the plunge. Below, we take a look at over fifteen real-life examples of one of ThemeForest’s most popular themes: Brooklyn… View Article

The post 15+ Stunning Examples of ThemeForest’s Popular Brooklyn WordPress Theme in Action appeared first on WinningWP.

Powered by WPeMatico

Thrive Leads, OptinMonster or Bloom: Which is the Best Email Optin Form Plugin for WordPress?

OptinMonster, Bloom, and Thrive Leads. When it comes to growing your email list, these commercial plugins are the three main players in the WordPress ecosystem. Which is the best? Well, unfortunately, there really isn’t a simple answer to this particular question. However, if you want to know which the best email optin plugin is for… View Article

The post Thrive Leads, OptinMonster or Bloom: Which is the Best Email Optin Form Plugin for WordPress? appeared first on WinningWP.

Powered by WPeMatico

Custom Post Type UI Version 1.2.0 Now Available!

It’s been awhile since we last visited Custom Post Type UI on the WebDevStudios blog. We released version 1.1.0 on June 12th 2015. Not long after that, Custom Post Type UI surpassed 1 million downloads.

Since then, I’ve been slowly but steadily working on the next major version. Today, I am happy to announce the release of version 1.2.0. A mix of 21 new features, bug fixes, and updates have gone into this version. We will go over some highlights today.

Notable new features

Individual post type and taxonomy output for the “Get Code” area

In version 1.1.x and earlier, the “Get Code” feature allowed you to move your registered types and taxonomies to external locations. This output provided a paste-ready block of code for use in custom plugins or your theme’s functions.php. The only drawback was that it was always all or nothing. In version 1.2.0, there is now output for individual post types and taxonomies as well.

Support for adding post types and taxonomies to the WordPress REST API

In WordPress 4.4, the core developers added the REST API infrastructure. In Custom Post Type UI 1.2.0, we added the ability to add REST API support to your post types and taxonomies. If you are unfamiliar with the WP REST API, or need a refresher, check out Ryan‘s WP REST API Overview once done here.

Template hierarchy references in the Registered Post Types and Taxonomies area

When you are reviewing your registered post types and taxonomies, you will now see a new column. Here you will see common template file names you can use to better target your post types and taxonomies. With those, you can further customize the frontend of your website. These are not special names from Custom Post Type UI. They come right from WordPress’ template stack.

Accessibility and usability improvements around the plugin

Last year one of our design leads, Greg, talked about The Basics of Developing Accessible Websites, and I knew I wanted to increase the accessibility of Custom Post Type UI. With that, I worked and revised the labels used on various forms used in Custom Post Type UI. I also updated the headings to match accessibility changes made in WordPress core. I plan to continue reviewing and improving accessibility in future versions as well. It is a job that is truly never done.

“Debug info” tab with debugging information  on the support forums

While I try to keep Custom Post Type UI as user-friendly and simple as possible, it is just not always the case. Sometimes, you just need some help figuring out how to do something. When that time comes, you hop over to the Custom Post Type UI support forum and post your questions. If you have ever had to do that, you have no doubt seen me show up. Depending on the situation, I may need more information to help debug the issue. This is where the new “debug info” tab will come into play. It will provide me with the needed extra information. This information will include:

  • Site URL
  • WordPress version
  • permalink structure
  • active theme
  • active plugins
  • registered post types from both Custom Post Type UI and elsewhere
  • Custom Post Type UI posts types and taxonomies settings
  • many other details.

If you are hesitant to share this information to the public, please let me know. I will provide a way to send the data in private.

Other quick notes

We have bumped the minimum version to WordPress 4.2. We also migrated the textdomain to match the slug we have on WordPress.org. If you would like to help translate Custom Post Type UI, let us know and we will point you in the right direction.

All in all, I am quite happy with how Custom Post Type UI version 1.2.0 turned out. I hope a lot of the new features help our users and address issues they were having.

The post Custom Post Type UI Version 1.2.0 Now Available! appeared first on WebDevStudios.com.

Powered by WPeMatico

Time Saving Tips For Cross Browser Testing

Cross browser testing (CBT/CBT-ing) is something we take very seriously here at WDS. If you don’t believe me, just ask our design leads Greg Rickaby or Corey Collins. As a front-end developer, providing screenshots from cross browser testing is a must before submitting work/code for review. Making sure a site functions and looks correctly across required browsers and devices is key to delivering a top notch product and that’s a goal we should all strive for.

Take the Time

CBT-ing is not fun and there are slew of reasons why. One of the biggest is that it takes time…a lot of time. Add a deadline that you have to meet and both your stress level and heart rate will shoot through the roof!

There are many different setups when it comes to cross browser testing. WDS currently uses a service provided by CrossBrowserTesting.com. Even despite its rich feature set, testing can still be time consuming and at times a frustrating process. In this post, I will show you some cool tricks I’ve learned that to help you save time and streamline your testing process when using CBT.com. At the bottom of this post I’ve included links to the relevant resources for each feature we cover.

NOTE: My local dev environment runs on OSX and VVV.

Setup Local Testing

CBT.com has a local connection feature that allows you to test websites running in your local dev environment. Testing locally is usually quicker (depending how powerful your machine is) and it’s a good option if you need to periodically check your work while you dev.

Getting setup for local testing can be a bit confusing, but it’s definitely worth it. Here are the steps I used:

  • Login to the test center
  • Click ‘Enable Local Connection’ at the top right of the page. Doing so will display a popup with instructions to follow:

localconnection

After you’ve installed Java and downloaded the app to a location on your machine, I’d recommend you add a command alias to your terminal profile so you can activate local testing with a simple command.

Here’s what my alias looks like:

alias cbt="cd ~/; java -jar cbttunnel.jar -authkey ‘your auth key’”

With the above alias setup, all you need to do is run cbt from your terminal and local testing will start automatically.

Handy Bookmarklet

Thanks to Allison Tarr for filling me in on using this nifty shortcut! CBT.com provides a bookmarklet that you can use if you want to run a quick live test on the current page. Using this in conjunction with local testing makes for a powerful combination.

Installing the bookmarklet is easy. Just login to the test center and scroll to the bottom of the page and check out the ‘Quick-Test Bookmarklet’ section.

Here’s an example using the bookmarklet along with local testing:

bookmarklet

Login Profiles

Ever run into the situation where you are working on a website that has a protected page and it needs to be tested in ten different browsers? Before discovering the Login Profiles feature, I would manually test each protected page which was very time consuming and caused unneeded frustration.Setting up a login profile is pretty straight forward and the instructions that CBT.com have provided up are very good (you can find the instructions here).

After you get a login profile setup, you can configure a ‘Screenshot’ test and select the profile you want to use. That’s it!

login-profile

 

Login Profile Tips

  • Take the advice from CBT.com and test a login profile first with just one browser selected.
  • If you find that the screenshots are failing, setting a screenshot delay may help (thanks to Cameron for the heads up on this!).
    screenshot-delay
  • There are times when walking through the Login Profile wizard that it won’t automatically select the input fields for username, password, and the submit button.

A quick shortcut for getting input details is to copy the XPath directly from devtools and use that.

xpath

Selenium Tests

Selenium tests are handy when you want to get screenshots of a page after some sort of interaction has taken place–like when a hover state of a menu has been activated. Initially, I knew that CBT.com had support for Selenium testing, but it was foreign to me and seemed really complicated to setup.

I was wrong.

They created Selenium Builder, which is a Firefox extension that can be used to record scripts. Just follow the installation instructions on CBT.com to get it setup, but be sure to read the tip below first!

Setup Tip:

When I was setting this up, there was one part of the setup that was confusing. Just know that after you install the Firefox extension, you can access the Selenium Builder by going to Tools > Web Developer > Launch Selenium Builder. From here, you will be able to access the other settings you need to adjust for setup:

selenium-builder

 

You might be asking what this extension actually does. Basically, it records the actions you perform on a webpage and allows you to save it to a JSON file. Those ‘instructions’ can then be used when you are setting up your screenshot test on CBT.com.

json

Tip: When you launch a recording session, you may or may not want to record mouseover actions.

mouseover

If you’ve never used Selenium testing, I encourage you to give it a try! After you record a session or two, the process becomes much easier.

Links:

Getting local connections setup
Setting up a Login Profile
Setting up and recording a Selenium test

Conclusion

Cross browser testing is neither fun or easy, but the service and set of features that CrossBrowserTesting.com provides is solid and can make the process slightly less painful.

Do you have another testing workflow that works well for you? Have you used CrossBrowserTesting.com? Let me know about it! I’m interested to hear what other people are doing to make this process easier.

The post Time Saving Tips For Cross Browser Testing appeared first on WebDevStudios.com.

Powered by WPeMatico

Integrating ElasticSearch with WordPress

High traffic sites that heavily depend on search can run into server resource issues and cause a sluggish experience for users. A good solution for this is to allow a third-party service to handle search for your site. We recently had a client that needed just that and ElasticSearch was a good fit. 10up’s ElasticPress plugin was used for integration with WordPress.

ElasticSearch provides a wide variety of filters and tokenizers that will fit nearly every project. The ones mentioned below highlight some that were helpful in resolving search issues during the project.

Searching with special characters

ElasticSearch uses tokenizers in custom analyzers for search. The problem is that the standard tokenizer doesn’t generate tokens for punctuation like ampersands. The whitespace tokenizer needs to be used to split tokens by whitespace and preserve punctuation. This can be done by updating ElasticSearch mapping by using ElasticPress filters and WP CLI command. The default mapping can be found includes/mappings.php and using the ElasticPress ep_config_mapping_file filter to return an updated mapping file location. This will fix some special characters, but others such as hyphens and periods will have to be added to the word_deliminator filter:

    'wds_es_word_delimiter' => array(
        'type' => 'word_delimiter',
        'preserve_original' => true,
        'type_table' => array( 
            '.' => 'ALPHA', 
            '-' => 'ALPHA',
            '#' => 'ALPHA',
        ),
    ),

Narrowing search results

A more narrowed title based searching was needed because a variety of other searches were also available on the site and title based searches were returning too many results. The default ElasticPress minimum similarity value can be altered via the ep_min_similarity filter. ElasticSearch assigns a similarity based on how close a string matches and using this filter allows results to be removed from results if the similarity was too low. The Ngram filter can also be disabled in ES mapping to remove partial word matching. 

Synonym searches

For search strings like “NYC” to match “New York City” a synonym filter needs to be used. This will allow ES to convert these strings during search and tokenization. A filter can be added to the mapping and your custom analyzer for cases such as these.

    'wds_es_synonym_filter' => array(
        'type' => 'synonym',
        'synonyms' => array(
            'nyc, ny, new york city, new york',
            'half, 1/2',
            'quarter, 1/4',
            ''n, 'n', n, and, &, &’,
        ),
    ),

Duplicate results during pagination

When paginating results with a custom sorter over multiple shards the data can sometimes be returned more than once because of differences in how results with the same value are sorted. A preference query string can be added to the request with a unique value to ensure the same shard is used. ElasticPress has a ep_search_request_path filter that will allow the preference parameter to be added.

Conclusion

ElasticSearch is an excellent solution for sites that depend heavily on search. It’s capable of scaling with your site and is much more efficient than regular WordPress search. ElasticPress can integrate ElasticSearch into your WordPress site seamlessly and has a bunch of helpful hooks, filters, and functions that makes tweaking search easy.

The post Integrating ElasticSearch with WordPress appeared first on WebDevStudios.com.

Powered by WPeMatico

ThemeFuse Christmas Deal – Save 30% on Themes and Club Memberships

Now boasting over thirty WordPress themes, an increasingly popular multi-purpose WordPress theme named ‘Core‘ and a developer-focused theming Framework called ‘Unyson‘, ThemeFuse have come a long way since first entering the premium WordPress theme business back in 2010. From general-purpose blogging themes to Magazine, eCommerce and a number of niche-type themes (including a Food, Real… View Article

The post ThemeFuse Christmas Deal – Save 30% on Themes and Club Memberships appeared first on WinningWP.

Powered by WPeMatico

35+ Stunning Examples of the Jupiter WordPress Theme in Action

When you’re looking to buy a brand new WordPress theme, it’s almost always interesting to see a few examples of real-life sites already using the exact same theme you’re considering. In this particular showcase, we take a look at over thirty-five live examples of one of ThemeForest’s most popular themes: Jupiter — a responsive, multi-purpose… View Article

The post 35+ Stunning Examples of the Jupiter WordPress Theme in Action appeared first on WinningWP.

Powered by WPeMatico

WP-API: Endpoint Namespaces

WordPress is getting a JSON Rest API added to core. The first part of the API is actually already included. The endpoint infrastructure is in 4.4. As developers build extensions to the API, we need to take responsibility for our actions and how they can affect a site. WordPress is unique in that it is the ultimate generic API tool and anything can be created utilizing this new tool.

“The infrastructure of the API itself, supports basically anything you can throw at it. If you take away the core endpoints, it is essentially a framework for building APIs, and you can build those however you like.” – Ryan McCue

Namespaces

To avoid collisions, namespaces are something to be thoughtful about. Namespaces are the slugs in the URL before the endpoint. Also, the schema and structure of your data should be a consideration. The core endpoint namespace is:

/wp/

This means it is reserved for core endpoints. Similarly, you may come across plugins that have a namespace. You should probably not add endpoints to a previously used namespace unless the data is specific to that plugin. Think of namespaces like you would with class or function names; they need to be unique. If you are creating endpoints, then add filters in your JSON response code so others can add more data to your existing namespaces endpoints.

What happens when you try and register a namespace and endpoint that already exists? Nothing–it actually gets ignored if the code is loaded after the previous registration. If you register a namespace and a plugin loads before your plugin, then they win and your endpoint will get ignored. To avoid this, create unique namespaces (PLEASE).

If it’s a plugin hosted in the WordPress repo, the slug of the plugin is good namespace for your endpoints. The slug is in the URL after /plugins/. These are unique to each hosted plugin. (This may not be the case for some plugins; they may choose a unique name based on other factors. For example, the core namespace is ‘wp.’)

Options are everything here. You can create wildly different APIs for a myriad of applications. This is one of the reasons I feel WordPress’ Rest API is going to be the go-to framework for creating APIs. You have authentication and administration tools baked in along with Custom Post Types, Taxonomies, and Meta, OH MY! Though, we have almost infinite API possibilities with data structure I think it is good to have some standardized endpoint structures.

Taking core namespaces and endpoints as a basis for creating your own endpoints is the best method. Accessing your custom endpoints will feel natural to a user if they are similar. Looking at the core endpoint for posts:

/wp-json/wp/v1/posts

You may think to create a custom endpoint for a Custom Post Type you might use:

/wp-json/wp/v1/custom-post-type

You could also register your own namespace using the CPT slug:

/wp-json/custom-post-type/v1/posts

The lesson here is you need to decide what is best for your data. If you are adding a simple CPT, you can access the data using the ‘?type=’ parameter when visiting the posts endpoint but if you have complex data structures and a lot of extra meta you may want to go the route of creating unique endpoints. If your plugin will have lots of endpoints, utilizing a custom namespace is the way to go. Note that Custom Post Types will not show unless it has the argument ‘show_in_rest’ during the creation of the type.

JSON Structure

You can hook into the filter ‘rest_prepare_post’. This is the filter you would use to add post meta or any other data to the posts endpoint. Create your own unique filter names, like ‘rest_prepare_my_custom_post_type.’

The filter mentioned above, ‘rest_prepare_post,’ can add or remove anything from a post response. If a plugin filtered the API response and added a new key to the data array, then you came along and added the same key, it would bump their data out of the API response and you may break their site or application. You can add any data in any structured way to the API. This is its greatest power, but it can get wild if there is not some sort of standardized structure. If you have five plugins adding the same meta to five different parent keys it could get messy! Plus, how would a client accessing your API know where the meta for the post is stored?

Conclusion

There is no set method structuring APIs and can’t truly be enforced. Maybe the API needs some guidelines on where to place extra data in the structure. Until then it is best to create our own namespaces / endpoints specific to your data’s needs. If you need to learn how to add the endpoints, hit up the WP-API docs site.

*original image by Nimish Gogri

The post WP-API: Endpoint Namespaces appeared first on WebDevStudios.com.

Powered by WPeMatico

WP Rocket Review: Just How Effective Is It?

Don’t you just hate slow websites? Well, you’re certainly not alone: your visitors hate them as well — and to make matters worse, so too does Google. That’s right, if you want your website to rank highly in the search engines, sell more products, generate more leads, earn more revenue, or simply deliver a more… View Article

The post WP Rocket Review: Just How Effective Is It? appeared first on WinningWP.

Powered by WPeMatico

55+ Stunning Examples of Real Life Websites Using Shopify

A few years ago, Magento was the go-to platform for creating professional eCommerce stores. However, while it may indeed still be the preferred online retail solution for many of the very largest online sellers, its king-of-the-hill reputation as the general eCommerce platform of choice is almost certainly coming to an end (if it hasn’t already… View Article

The post 55+ Stunning Examples of Real Life Websites Using Shopify appeared first on WinningWP.

Powered by WPeMatico

‘Stats of the Word’ – Infographic

Each year, the co-founder of WordPress and CEO of Automattic (the company behind WordPress.com), Matt Mullenweg, gives a presentation in which he details how WordPress is progressing and the direction it’s currently heading. I’m talking, of course, about Mullenweg’s annual ‘State of the Word’ speech — which took place this year at WordCamp US 2015…. View Article

The post ‘Stats of the Word’ – Infographic appeared first on WinningWP.

Powered by WPeMatico