[ad_1] Interesting little article over at CSS Tricks from Alex Riviere. In it, he explains that it’s possible to label “if” (and other “block type”) statements in JavaScript. I’ve never heard (or thought about) such a feature. As Alex says, it’s also a feature that I feel like I won’t use much, because it’s something most people neither know to be possible or will necessarily understand. (I’m always in favor of “broad comprehensibility” above “cleverness.”) But he makes the good point that for specific contexts where many-loops or ifs are not avoidable, it makes sense that these labels would make it a lot easier to track what’s happening. This example (copied directly from his article) makes the point of their value pretty clearly to me: let x = 0; outerLoop: while (x < 10) { x++; for (let y = 0; y < x; y++) { // This will jump back to the top of outerLoop if (y === 5) continue outerLoop; console.log(x,y); } console.log(‘—-‘); // This will only happen if x < 6 } Obviously, real code won’t have these types of “toy conditions.” But the number of times I’ve wondered if a break or continue statement was terminating the thing I meant it to is definitely dozens, and maybe hundreds. So good to know that JavaScript offers a solution to it 🤓 Visit css-tricks.com → [ad_2] Source link
Continue readingMonthly Archives: June 2021
Yoast Pivots Diversity Fund
[ad_1] For the last three and a half years, Yoast has offered a “diversity fund”, which funded WordCamp attendance for underrepresented people in tech. The goal was to increase the diversity at WordCamps. It worked very well. According to a recent blog post: During 2018, 2019, and 2020: We were able to sponsor 70 people, To join a total of 56 events, That were all around Asia, Africa, North America, South America, Europe, and Australia. The problem is that in 2020 all that came to a screeching halt when WordCamps stopped happening. But rather than throw up their hands and say “Oh well!”, the good folks at Yoast came up with a new plan. The New Plan The new plan is to sponsor the same group of people, but to fund their WordPress projects, rather than travel to an event. To quote the same blog post from above: So what kind of projects are we looking for? It can be a short-term project, like fixing a simple bug, or a longer-term project like creating a new WordPress theme. That being said, we are looking for projects that aim to be no longer than one WordPress release cycle of three months. I particularly love this new direction because it feels like a more substantial contribution. Don’t get me wrong, I think WordCamps are great and important, but supporting someone financially for three months while they build something that the entire world gets to use just feels like a bigger thing. Diversity is very important to us here at HeroPress. We’ve striven for diversity across multiple metrics, from gender to age, culture, geography, and language. I think that’s why this project speaks to me more than others. So many thanks to Yoast for making this happen. If you’d like more information about the program, check out this blog post, and if you’d like to apply for the fund click here. Related [ad_2] Source link
Continue readingCreate Per-Post Social Media Images With the Social Image Generator WordPress Plugin – WordPress Tavern
[ad_1] It was a bit of a low-key announcement when Daniel Post introduced Social Image Generator to the world in February via tweet. But, when you get repped by Chris Coyier of CSS-Tricks and the co-founder of WordPress uses your plugin (come on, Matt, set a default image), it means your product is on the right track. I am not easily impressed by every new plugin to fly across my metaphorical desk. I probably install at least a couple dozen every week. Sometimes, I do so because something looks handy on the surface, and I want to see if I can find some use for it. Other times, I think it might be worth sharing with Tavern readers. More often than not, I consider most of them cringeworthy. I have high standards. As I chatted with Post about this new plugin, I was excited enough to call Social Image Generator one of those OMG-where-have-you-been? types of plugins. You will not hear that from me often. Post quit his day job to venture out earlier this year, creating his one-man WordPress agency named Posty Studio. Social Image Generator is its first product. “I kept seeing tutorials on my Twitter feed on how to automatically generate images for your social media posts, but unfortunately, they all used a similar approach (Node.js) that just wasn’t suitable for WordPress,” said Post of the inspiration for the plugin. “This got me thinking: would it be possible to make this for WordPress? I started playing around with image generation in PHP, and when I got my proof of concept working, I realized that this might actually be something I should pursue.” In our chat over Slack, we actually saw the plugin in action. As he shared Coyier’s article from CSS-Tricks, the chatting platform displayed the social image in real-time. Auto-generated image appearing via Slack. Maybe it was fate. Maybe Post knew it would happen and thought it would be a good idea to show off his work as we talked about his project. Either way, it was enough to impress the writer who is unafraid to call your plugin a dumpster fire if he smells smoke. Post seems to be hitting all the right notes with this commercial plugin. It has a slew of features built into version 1.x, which we will get to shortly. It is dead simple to use. It is something nearly any website owner needs, assuming they want to share their content via social networks. And, with a $39/year starting price, it is not an overly expensive product for those on the fence about buying. How the Plugin Works After installing and activating Social Image Generator, users are taken to the plugin’s settings screen. Other than a license key field and a button for clearing the image cache, most users will want to dive straight into the template editor. At the moment, the plugin includes 23 templates. From Twenty Seventeen to Twenty Twenty-One, each of the last four default WordPress themes also has a dedicated template. After selecting one, users can customize the colors for the logo, post title, and more — the amount of customization depends on the chosen template. Browsing the plugin’s templates. Aside from selecting colors, users can choose between various logo and text options. They can also upload a default image for posts without featured images. Editing a template from Social Image Generator. When it comes time to publish, the plugin adds a meta box to the post sidebar. Users can further customize their social image and text on a per-post basis. Social image preview box on the post-editing screen. Once published, the plugin creates an image that will appear when a post is shared on social media. On the whole, there is a ton that anyone can do with the built-in templates. There is also an API for developers to create their own. For a first outing, it is a robust offering. However, there is so much more that can be done to make the plugin more flexible. Version 2.0 and Beyond Thus far, Post said he has received tons of positive feedback along with feature requests. Primarily, users are asking for more customization options and the ability to create and use multiple templates. These are the focus areas for the next version. With a 1,718% increase in revenue in the past month, it seems he might have the initial financial backing to invest in them. “I’ve started building a completely overhauled drag-n-drop editor, which will allow you to create basically any custom image you want,” he said. “It will be heavily inspired by the block editor, and I want to keep the UI and UX as close to the block editor as possible.” The new template editor would allow users to create multiple layers, an idea similar to how Photoshop, Gimp, and other image-editing software works. The difference would be that it can pull in data from WordPress. “For example, an ‘Image’ layer will have options such as height/width and positioning, as well as some stylistic options like color filters and gradient overlays,” said Post. “A ‘Text’ layer can be any font, color, and size and can show predefined options (post title, date, etc.) or whatever you want. You can add an infinite number of layers and order them however you’d like.” He seems excited about opening up new possibilities with an overhauled editor. Users could potentially create social image templates for each post type. A custom layer might pull in post metadata, such as displaying product pricing or ratings from eCommerce plugins like WooCommerce. “The prebuilt templates will still exist, similar to Block Patterns in the block editor,” said the plugin developer. “They will, however, serve as a starting point rather than the final product. I’ll also try to implement theme styling as much as possible. “The possibilities here are so endless, and I’m incredibly excited for this next part.” Like this: Like Loading… [ad_2] Source link
Continue reading4 Top GoDaddy Hosting Alternatives and Competitors for 2021
[ad_1] Hosting is a perennial topic among site owners. The conversation can get fanatic and fervent at times too. GoDaddy is one of the more popular hosts on the market. Even so, it’s not the only option. In fact, there are a lot of GoDaddy alternatives available that may suit you better. For example, you may not need GoDaddy’s collaboration tools. It could be that you need more when it comes to server specifications. Regardless, each provider has a different approach – and one could be better for your needs. Given this, we’ll look at some of the best GoDaddy alternatives, and discuss why they could do a more effective job. First, let’s give you some background on GoDaddy. A Quick Introduction to GoDaddy In short, GoDaddy is a monster-sized hosting provider. In fact, it covers many bases with its services, but hosting is a primary offering. The target user is small and medium business owners, which is why you’ve likely come across GoDaddy in the past. As such, the product lines and feature sets are all geared around running a business. Team-based solutions are also front and center too. GoDaddy is also a domain registrar, which means you can buy your domain and hosting from the same place. While this isn’t always recommended, it is convenient and in some cases can save you money. On paper, GoDaddy can cater to lots of different users and business. Even so, some users are looking elsewhere for hosting. Let’s take some time to find out why. Why You’d Want to Find GoDaddy Alternatives to Host Your Website Of course, GoDaddy is not the only host on the market. As the saying goes, “variety is the spice of life”. As such, there are lots of general reasons why you might want a GoDaddy alternative: The feature set doesn’t align with your site’s goals. There are too many features you’re not using. You’ve found third-party solutions for some of the built-in offerings. It could even be that none of the above is true. If you take a look at a site such as Review Signal, you’ll notice that GoDaddy is not in the top ten for any category. In fact, it’s struggling to remain in the top 20 hosting providers: This is down to a few reasons: Customer support can be poor, and the process to resolve simple queries is made into a complex number of steps. There have been user reports of poor server stability and speed over the years. The price can be cheap if you’re only using hosting. Though, if you’re buying more services from GoDaddy, the cost could spiral out of control. Despite this, GoDaddy can be a solid host for you, if everything hits the mark. More often than not though, you can find higher quality at a cheaper price point. 4 Top GoDaddy Alternatives and Competitors Let’s get down to the ‘nitty-gritty’, and look at some top-quality GoDaddy alternatives. Here are the providers we’ll feature: A2 Hosting. This cost-effective host has all the power of GoDaddy, but none of the ‘fluff’. WP Engine. If you’re after a dedicated WordPress host, WP Engine is a top-tier solution. Kinsta. For ‘hall of fame’ class hosting, Kinsta offers iron-clad dependability and functionality. DreamHost. A WordPress-approved host that offers value for money, and platform-specific servers. First off, we’ll look at the cheapest option on our list. Though, it’s not the worst performer by a long shot. 1. A2 Hosting First off, we have A2 Hosting. This provider has grown to become one of the major players over the past few years, and for good reason. It provides a number of plans for hosting your site, such as shared and dedicated plans, and a Virtual Private Server (VPS) if you need one. It also offers shared and managed WordPress hosting, which might have pricked up your ears. From the four dedicated plans, all but the lowest tier offers an unlimited number of websites. While all plans offer at least Solid State Drive storage, higher tiers give you Non-Volatile Memory Express (NVMe) drives for blazing speed and reliability. The more expensive plans also give you A2 Hosting’s ‘Turbo Boost’ servers. This lets you handle more traffic, reduce your page load speeds, work with a higher-powered processor, and get access to stellar caching. As for support, there’s a comprehensive knowledge base for all types of hosting. If you’re after a more personal experience, A2 Hosting also as a wealth of options to access the support team. Compared to GoDaddy, A2 Hosting offers less on the whole. Though, this isn’t a knock on the latter. What’s here is focused on solid, stable hosting – especially if you’re a WordPress user. If you’re after good all-around hosting without the bells and whistle that come attached to GoDaddy, this is a top-notch option. 💲 Use our A2Hosting Coupon to get up to 51 % off Get A2Hosting 2. WP Engine Next up, WP Engine is a perennial host within any discussion on the topic. Even so, it more than matches up to GoDaddy in a number of ways. WP Engine bills itself as a ‘Digital Experience Platform (DXP)’. Rather than focus only on hosting, WP Engine looks to provide an all-around solution for managing your online presence. The idea behind a DXP is that your brand can be where your users are, through homogenized social media and other branding channels. This is in contrast to the traditional passive approach. Given this, its no surprise that WP Engine offers solutions catered to marketers and developers. It’s a fully-managed host with three different options for your site. Each of these has five tiers. It can be confusing, but no more so than other hosts. Though, the price for using WP Engine is clear. It’s more expensive than most other competitors, including GoDaddy. This isn’t always a negative, though. There’s a lot packed into each tier. If you have everything you need to run your site, it’s money well spent.
Continue readingProfilePress Draws Criticism For WP User Avatar Rebrand
[ad_1] Hey, WordPress fans. We are checking in with your latest dose of weekly WordPress news. This week, ProfilePress turned WP User Avatar, a single-purpose custom avatar solution into a full-fledged membership management plugin. The unexpected change has drawn criticism from the community and the plugin users. The surge in one-star ratings knocked the plugin’s 4.4 ratings down to 3 in a few days. Beyond that, there are some exciting block editor updates you should check out. We also have some great tutorials and promos for you. Let’s get to all of this week’s WordPress news… WORDPRESS NEWS AND ARTICLES TUTORIALS AND HOW-TOS RESOURCES [ad_2] Source link
Continue readingProgrammatically Search WordPress Posts By Date Range
[ad_1] TL;DR: The code shared in this post shows how you can modify the query that runs on the All Posts page so you can limit how you search posts to a specified date range. It’s been a little while since I last wrote about using the post_where filter for modifying the search query that runs on a given page, such as the All Posts area of WordPress. But given the fact that there are a variety of uses for retrieving posts – and custom post types – in different ways, there’s a variety of ways to use this single filter. Search Posts By Date Range In order to search posts by date range, here’s what needs to happen: Register a callback with the posts_where filter, Make sure the function accepts the string for where and the instance of WP_Query that’s running on the page Get todays date and time and the date and time for four weeks ago Prepend the where clause to constrain the results to the date return the updated query. <?php add_filter( ‘posts_where’, function ( string $where, WP_Query $query ) : string { global $wpdb; $todays_date = gmdate( ‘Y-m-d H:i:s’, strtotime( ‘now’ ) ); $four_weeks_ago = gmdate( ‘Y-m-d H:i:s’, strtotime( ‘-4 weeks’ ) ); $prepend = $wpdb->prepare( ” AND {$wpdb->posts}.post_date > %s”, $four_weeks_ago ); $prepend .= $wpdb->prepare( ” AND {$wpdb->posts}.post_date < %s”, $todays_date ); return $prepend . $where; }, 101, 2 ); The result of this function is a modified query that restricts the posts that are returned by the specified date and time. Namely, four weeks ago up to the hour, minute, and second. You can change this by updating the -4 weeks string passed to the strtotime function (but I recommend reviewing the PHP manual page linked below to understand how this function works with language like this). References [ad_2] Source link
Continue readingThe Best Managed WordPress Hosting (Learn Why)
[ad_1] If you’re searching for the best managed WordPress hosting, Kinsta is probably a name you’ve come across. There’s a reason for that – Kinsta is one of, if not the, best managed WordPress hosts in 2021. The objective data backs that up, with Kinsta consistently leading the pack in data from review aggregators and third-party surveys. But we’re getting ahead of ourselves – to help you decide whether Kinsta is the best host for you, we’ll take you through some of its pros and cons and make some recommendations for how to pick the best host for your needs. By the end, you should have a better idea of the best hosting solution for your site, whether that’s Kinsta or another option. Quick Summary of Our 2021 Kinsta Review If you’re in a hurry, here’s a quick rundown on how Kinsta is doing in 2021… Simply put, Kinsta is one of the best options for managed WordPress hosting. Kinsta hits all the important things you need in a host with fast performance, rock-solid reliability, excellent 24/7 support, and convenient features. This is why, when we aggregated data from third-party sources like TrustPilot, WhoIsHostingThis, CodeinWP’s survey, and Review Signal, Kinsta was #1 out of all the hosts we looked at with an impressive 96% satisfaction rating across all those sources. Here’s the aggregated data for popular hosts: You can see that Kinsta leads the pack, even beating out similarly-priced hosts like WP Engine and Flywheel. So – to learn why Kinsta has such satisfied customers, let’s dig into the pros and cons. Five Things Kinsta Does Really Well Let’s start with the best parts of hosting with Kinsta.. Objectively Great Performance One of Kinsta’s biggest advantages is that it offers excellent performance, which is the most important consideration in any WordPress host. To objectively assess a host’s performance, we rely on Review Signal’s exhaustive performance benchmarks, which challenge hosts in a variety of ways including some pretty heavy-duty load testing. Though Kinsta didn’t participate in the most recent 2020 Review Signal benchmarks, Kinsta was a regular participant in the prior years. In the 2019 benchmarks, Kinsta participated in five different pricing tiers: $25-$50 per month $51-$100 per month $101-$200 per month $201-$500 per month $500 per month (enterprise) Kinsta earned Top Tier status (the highest designation) in every single tier. That means Kinsta earned Top Tier from its $30 per month starter plan all the way up to its enterprise plans, which is pretty impressive. So what’s behind that Top Tier performance? Kinsta runs the following stack: Google Cloud infrastructure with your choice of 25+ data centers spread around the world. Pure Nginx. MariaDB. Server-level caching with Nginx Fast_CGI cache, along with a custom companion plugin to purge the cache from your WordPress dashboard. Built-in CDN powered by KeyCDN. Automatic database optimization once per week. For advanced users, Kinsta also offers free Application Performance Monitoring to really dig into your site’s performance at a more technical level. This tool aims to fill the same role as premium monitoring services like New Relic without forcing you to pay an extra fee or integrate a third-party service. Kinsta also offers some useful guides on how you can use these features to improve performance for WooCommerce stores and membership sites. Top-Notch Live Chat Support Kinsta offers excellent live chat support that’s available 24/7 via the user-friendly Intercom widget. You can get help from anywhere in your dashboard just by opening the widget, and all of your chat histories are automatically saved. You can also click around to different areas of your dashboard without losing your chat, which is surprisingly useful: As for support quality – it really is good and the support team knows their way around WordPress. For example, in CodeinWP’s 2018 hosting survey, CodeinWP asked users to rate their hosts’ overall support and WordPress-specific support (out of five). Kinsta scored 4.9 on both metrics, which was good for first place out of all the hosts that respondents were using. If you’re wondering, WP Engine was second at 4.7 for both, while Flywheel had 4.6 for overall support and 4.8 for WordPress-specific support. Convenient Managed WordPress Features Kinsta is a true managed WordPress host, so you get all those convenient managed WordPress features to make your life easier. Basically, you’ll have a partner that works to make your site more reliable, secure, and quick-loading. I already covered what Kinsta does on the performance front – you won’t have to worry about configuring caching or a CDN because Kinsta handles all that for you. On the security front, Kinsta implements: A WAF (web application firewall) to proactively stop threats. Daily malware scans. Uptime monitoring to automatically detect issues on your site. Free SSL certificates via Let’s Encrypt. If something does happen to your site, Kinsta also offers a free hack fix guarantee to get your site working again. To keep your site’s data safe, Kinsta offers automatic daily backups with 14 days of storage. If you want more frequent backups, you can pay $50/month/site for backups every six hours or $100/month/site for backups every hour. There’s also an external backup add-on to send your backups to your own Amazon S3 or Google Cloud Storage account, which costs $2/month/site + $1/GB bandwidth. Finally, you also get staging sites to safely test changes to your site and then push them live with a single click. Well-Designed Custom Dashboard and Useful Tools Like many other managed WordPress hosts, Kinsta uses its own custom hosting dashboard rather than a pre-built dashboard like cPanel or Plesk. What stands out about Kinsta’s dashboard, though, is that it’s really well-designed and user-friendly. You’ll be able to easily manage things like backups, staging sites, etc. You also get some useful tools, such as dedicated tools to enable WordPress debug mode with a single click or run a search/replace on your site’s database without the need for a plugin: If you’re working as part of a team, you’ll also get different
Continue readingWordSesh 2021 is Approaching • WPShout
[ad_1] Next week(!) is WordSesh. For those who aren’t familiar, WordSesh is a free online-first (has been doing it since before it became how all events are ;p) WordPress conference. It is totally free for live (and nearly-live attendance). (If you’re a more-than-24-hours-after-conference-end slow poke on a talk, you’ll just have to become a WPSessions member to see talk recordings.) Our friend Brian Richards (most known for WPSessions) has been running the conference for the last few years, and this years lineup looks set to be great as ever. I’m probably not going to prioritize attending in real-time but that the recordings will be available for free for the whole-event-duration after certainly has my attention. I doubt I’m alone in feeling a little “behind and overwhelmed” as we swing into the second year of COVID-19-infected reality. So attending WordSesh may be just the thing to get me “back on the horse.” (And if not, that’s OK too ❤️) Visit wordsesh.com → [ad_2] Source link
Continue readingCSS Neon Lights • WPShout
[ad_1] Longtime readers may have caught on to the fact that I’m a big sucker for cool CSS techniques I would have never come up with or figured out. And this is one more example on that. Over at CSS-Tricks, Silvia O’Dwyer offers a guide to making some really compelling “neon light” effects with CSS. Honestly the visuals of the effect were enough to convince me this was cool enough to share. But she takes it a step further and covers both adding a “pulsating” effect, and even reminds us to turn it off for motion-sensitive visitors. It’s just an all around great little tutorial. Give it a look 🙂 Visit css-tricks.com → [ad_2] Source link
Continue readingGood Interview with Matt Mullenweg & Josepha Haden Chomposy • WPShout
[ad_1] I really enjoyed watching this little interview with between Mark & Keith from Highrise Digital and Matt Mullenweg and Josepha Haden Chomposy (who are probably the two most influential people shaping WordPress today). Nothing that anyone said was really a surprise or revelation to me, but it was all helpful and “orienting” to hear again what their thought process is, what’s been happening lately, etc. For myself, I actually left the interview thinking that “the future or WordPress themes” is even to these important and influential people still an open question. Which I think is both appropriate and a bit annoying. I seems clear that “full-site editing” is reshaping themes in important ways, but not knowing where we’re going leaves one a little unsure what to do. But it also means there’s time to jump in and influence the direction, if that’s something you’ve got interest and time for 🤓 Visit youtube.com → [ad_2] Source link
Continue reading