“We had 90% unused CSS because everybody was afraid to touch the old stuff”

Category Image 052

Over at the JS Party podcast:

[Kend C. Dodds]: […] ask anybody who’s done regular, old CSS and they’ll tell you that “I don’t know if it’s okay for me to change this, so I’m gonna duplicate it.” And now we’ve got – at PayPal (this is not made up) we had 90% unused CSS on the project I was using, because everybody was afraid to touch the old stuff. So we just duplicated something new and called it something else. And you might just say that we’re bad at CSS, but maybe CSS was bad at us, I don’t know… [laughter]

[Emma Bostain]: Well, that’s why styled-components and CSS-in-JS was so pivotal; it was like “Oh, hey, we can actually encapsulate all of this logic inside the component that it’s touching and don’t have to worry about bleeding code anymore.” It’s so much easier to delete things, and add things, and all of those things.

[Kend C. Dodds]: Yeah, you’re precisely right. That was the problem that those things were made to solve.

Audio clip:

I’ve heard this exact story before several times, usually from large companies. Lots of developers, typical developer turnover… nobody knows what CSS is actually used and what isn’t because that is a very hard problem.

That’s one of the reasons I sometimes like component-based-styling solutions (CSS-in-JS, if you’re nasty). Not because I love complex tooling. Not because I like JavaScript syntax better than CSS. Because of the co-location of styles and componentry. Because nobody is afraid of the styles anymore — they are tightly coupled to what they are styling. It’s not needed on every project, but if you’re building with components anyway (an awfully nice way to architect front-ends that doesn’t require JavaScript), you might as well style this way.

For this reason, I’m excited that “scoped styles” are making a bit of a comeback in standards discussions.

I remember an ancient idea (that maybe even shipped in browsers for a minute?) where you’d just chuck a <style scoped> block right in the HTML and whatever the parent was, the styles were scoped to that parent. That was so cool, I wish we could have that again.

But it seems like the newer stuff (here’s Miriam’s original proposal) has some more clever stuff that that basic concept doesn’t cover — like being able to set a lower-boundary in addition to an upper-boundary, making it possible to scope “donut-shaped” styles in the DOM (a Nicole Sullivan term). Whatever happens, shadow DOM-free scoped styles with zero tooling is huge.


The post “We had 90% unused CSS because everybody was afraid to touch the old stuff” appeared first on CSS-Tricks. You can support CSS-Tricks by being an MVP Supporter.

WhoisXML API Expands Domain Monitoring and Research Offering

Featured Imgs 23

WhoisXML API, a self-proclaimed cyber intel provider, has launched a new white-label version of the company’s solution for domain brand monitoring and research. The launch is meant to expand the reach of WhoisXML API’s offering to include a more broad set of organizations.

The company notes that building custom Domain Name System (DNS) databases integrations can be time-consuming and expensive:

How to Improve Domain Authority of Your WordPress Site

Featured Imgs 23

How to Improve Domain Authority of Your WordPress SiteIf you’re a marketing expert and know about SEO, you have surely come across the term Domain Authority. It’s a useful metric that many SEO professionals use to assess how likely content is to rank in the SERPs. Everyone interprets the relevance of domain authority differently. That makes the concept quite confusing. This blog post […]

The post How to Improve Domain Authority of Your WordPress Site appeared first on WPExplorer.

digital marketing services in united kingdom

Featured Imgs 20

Branding is basically increasing the value of the brand, that is all activities that are diverted towards portraying the image of the brand and strategizing ways to put forward the positive image of the brand. Nowadays branding of the companies is also conducted via digital ways as it has a wide reach of consumers and efficient marketing can be done with the help of these ways.

#digitalmarketingcompany #digitalmarketingagency #digitalmarketingstrategy #digitalmarketingexpert #digitalmarketingconsultant

for more information visit: https://www.sdlccorp.com/digital-marketing/
or call +1 (618) 6154906

How to Add a Post Creation Limit for WordPress Users

Wp Plugins

Are you looking for a way to limit the number of posts a user can publish or submit for review?

Limiting post creation is helpful if you’re running a multi-author website or have many members submitting content. It allows you to control the number of articles a user can submit, so you can easily manage content on your site.

In this article, we will show you how to add a post creation limit for users on your WordPress site.

How to Add a Post Creation Limit in WordPress

Who Needs to Limit Post Creation in WordPress?

There are several use-cases where you may want to limit the number of posts created by authors within a specific period of time.

A common scenario is if you run a multi-author blog, then you may want to limit the number of posts each author can submit per day, per week, or even by month.

Limiting posts per author makes it easier for you to manage the content on your website and improve the editorial workflow. You’ll have more time to review multiple articles and assign topics to different authors.

Or, let’s say you have a WordPress membership site that gives its members the ability to promote their content through announcements.

In that case, you may want to limit the number of announcements each member can post per week or month.

Another great use case is a listing directory of some kind. For example, you may have a real-estate website where you allow agents to add properties. You can limit the number of properties each agent can add per day or month.

That being said, let’s take a look at how to limit post submissions and creations by users in WordPress.

How to Limit Posts by Users in WordPress

You can easily limit posts for different users using a WordPress plugin without having to touch a single line of code.

For this tutorial, we’ll be using the User Post Limit plugin. It’s a free plugin, and you can use it to set up post limits in just a few clicks.

First, you’ll need to install and activate the User Post Limit plugin on your website. For more details, you can follow our guide on how to install a WordPress plugin.

Once the plugin is active, simply head over to Settings » Posts Limit from your WordPress dashboard. From there, you’ll see options to set post limits based on different user roles.

In the ‘text’ field, the plugin lets you edit the notification that a user will receive when they exceed the limit. There are more advanced options you can change, but the default settings will work for most users.

User Posts Limit settings

Next, you can select a user role for which you’d like to set up a post limit. For example, you can select Author, Editor, Administrator, or any other roles from the dropdown menu.

After selecting the user role, go ahead and choose which type of content you’d like to limit. You’ll see multiple options in the dropdown menu like posts, pages, media, revisions, and more.

Once that’s done, enter a limit for the number of posts a user can submit and select a cycle, such as days, years, months, or weeks. When you’re done, don’t forget to click the ‘Save Changes’ button.

Change post limit settings

If you want to set up post limits for different user roles on your WordPress website, then change the Rules number and repeat the steps.

For example, you can set a post limit for authors, and then create a higher post limit for editors.

To create a new rule, simply change the Rules number to 2 and select a user role, such as Editor. Next, select the content type and enter the limit and cycle.

When you click the Save Changes button, you’ll see your new rule added under the first rule. You can go ahead and create as many post limit rules as you want for each user role.

Two different rules for post limits

That’s all. When users try to create more posts than the set limit, they will receive a notification like this:

Post limit notification

We hope this article helped you to add a post creation limit for WordPress users on your site. You may also want to check our guide on how to improve your editorial workflow in multi-author blogs and the best email marketing services.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

The post How to Add a Post Creation Limit for WordPress Users appeared first on WPBeginner.

What benefits SEO offers to any business?

Featured Imgs 11

#1. SEO RESULTS TO HIGHER CONVERSION RATE
Search engine optimization can significantly increase the conversion rate of your site. Once your business becomes more popular long enough, your target market will realize the quality of the work you do. This initiative will aid you in establishing and maintaining your authority in your field.
#2. IT ENHANCES BRAND AWARENESS
Besides converting users into customers, improving your rankings also increases brand awareness. Even if you only reach the top and then climb your way up to the top of SERPs, you'll generate in-numerable touchpoints. Despite not clicking into your website, potential customers will associate your brand with the solutions you offer by simply being there.
#3. IT IS POSSIBLE TO DO SEO ON A BUDGET
Unlike other marketing strategies such as pay-per-click, SEO does not cost you any money other than your time if you manage it yourself. Search engines crawl A website 24/7, which promotes your crucial content and provides new customers organically. Invest some time reviewing the content on top-ranking sites in your niche, and aim to write better content than theirs. Once you've created content, post the information on your social networks.

what is Right-to-Use (RTU) License?

Category Image 041

"I am a technology practitioner who has just entered the data communication industry. I have always hoped to increase the port speed through my efforts and achieve a smoother and stable network connection, whether it is for enterprises, operators or homes. Maybe your distance from the optimized network is just a license!
Recently I saw a very surprising technical guide, which introduced in detail the important concepts of switch licenses, and provided instructions for the use of a variety of service licenses and typical operating methods. I don't want to be the last person to know it!
This is the link:
https://support.huawei.com/enterprise/en/doc/EDOC1100195306"

Tabs in HTML?

Category Image 052
You know what tabs are, Brian.

I mean… You use them every day, on every OS. Everybody knows they exist in every toolbox. All that’s left is to “just pave the cowpaths!” But when you get right down to it, it’s a lot more complicated than that.

Brian Kardell shares a bit about the progress of bringing “Tabs” to HTML. We kinda think we know what they are, but you have to be really specific when dealing with specs and defining them. It’s tricky. Then, even if you settle on a solid definition, an HTML expression of that isn’t exactly clear. There are all kinds of expressions of tabs that all make sense in their own way. Imagine marking up tabs where you put all the tabs as a row of links or buttons up top, and then a bunch of panels below that. They call that a “Table of Contents” style of markup, and it makes some kind of logical sense (“the markup looks like tabs already”). But it also has some problems, and it looks like sections-with-headers is more practical (“If you have the heading, you can build the TOC, but not vice-versa”). Spicy sections are a totally different pattern. And that’s just one problem they are facing.

I don’t envy the work, but I look forward to the progress in no small part because authoring tabs is tricky business. Not hard to do, but very hard to do right. I’ve talked in the past about how I’ve built tabs many times in jQuery where just a click handler on a row of links hides or shows some matching divs below. That “works” if you ignore accessibility entirely (e.g. how you navigate between tabs, focus management, ARIA expectations, etc).

Here’s the ShopTalk discussion and here’s a different perspective in a chat I had with Stephen on CodePen Radio where we get into our <Tabs /> React component on CodePen.

Direct Link to ArticlePermalink


The post Tabs in HTML? appeared first on CSS-Tricks. You can support CSS-Tricks by being an MVP Supporter.

Variable not recognised

558fe5180e0e8fc922d31c23ef84d240

From the below, how can I make the variable $new_status recognisable within those brackets?

$sendData = '{ "messages" : [ { "content" : "Your order is $new_status.", } ] }';

Problem: The above sends out text message successfully on status update, but the variable $new_status does not get updated.

I think within the those brackets php is not recognising the $new_status as a variable. I notice that if i insert one apostrophe (') just before $new_statusn like this '$new_status the variable turns green meaning it is recognised, however i get error in php that says Unexpeted T Variable

php variable issue

558fe5180e0e8fc922d31c23ef84d240

I need to add variable called $new_status, but its not being recognised on php, any suggestions.

$sendData = '{ "messages" : [ { "content" : "Your order is $new_status.", } ] }';