In my last post I tracked down how to get the attachment ID of an attachment by one of its thumbnail URLs. Today, I go a step beyond that and show how to get the thumbnail path by its URL.Continue reading Get attachment thumbnail path by its URL in WordPress
Working with attachments in WordPress is always somewhat special to me, because I always learn something new about its handling. In this case, I needed to get the attachment ID of an attachment via one of its thumbnail URL.Continue reading Get attachment ID by its thumbnail URL in WordPress
For a specific condition I needed to customize the result set of WordPress’
get_posts function. Since I struggled a bit with it, I want to make sure that never happens again with this post.
Last week, I published a SCSS code to fix inaccurate color contrast calculations. It is a Dart Sass implementation and based on an older implementation. However, for another project I needed yet another implementation that was built with scssphp, which has an own implementation.Continue reading WCAG 2 compliant SCSS color contrast function with scssphp
When it comes to accessibility, the most common errors are contrast errors. And with an auto-contrast function in SCSS they seem to be fixed easily. But unfortunately, the vast majority of color contrast functions don’t work they way they should. At least not according to the WCAG 2 specifications.Continue reading Fix your SCSS color contrast function
While there is a
did_filter to determine how often an action or a filter has been called, it works different then you might expect. Both work similar and only count whether
apply_filters have been executed. They don’t check whether they have been actually used.
In your Mastodon profile, you can define up to four links individually. These links can be verified that they belong to you. So instead of using just plain links that look boring on your Mastodon profile, add them with the proper attribute to your website to get verified links.Continue reading Properly add a Mastodon link to your WordPress site
WordPress websites typically have a specific purpose, which also means that there are some legal requirements in what you need to run the website. One of them is an imprint or at least a provider identification. But when do you need one of those and what information must it contain?Continue reading Do I need an imprint on my WordPress website?
Sometimes, you need to store unique data to a block to identify it later on. So you need to prevent having duplicate block attributes. In my case, I want to store a unique block ID. For this the
clientId is useful as it’s already unique per definition (it’s a universally unique identifier generated on every editor load for every block).