Don’t hesitate to contact us if you have any feedback.

Author: Victor

  • WordPress – Remove auto p in excerpt

    WordPress – Remove auto p in excerpt

    WordPress automatically applies paragraph formatting to excerpts using the <p> tag, which can sometimes disrupt the desired layout or styling of your website. If you’re looking to have more control over how your excerpts are displayed, the following PHP code snippet allows you to remove WordPress’s default automatic paragraph tagging and gives you the option…

    Read more

  • WordPress – Boost GraphQL query limits

    WordPress – Boost GraphQL query limits

    When working with GraphQL in WordPress, you might encounter limitations on the number of queries you can execute. By default, GraphQL imposes a cap to ensure performance and server health. However, there are scenarios where you need to increase this limit to accommodate larger data sets or complex queries. The following snippet of code allows…

    Read more

  • WordPress – Handle theme.json RGB color transparency

    WordPress – Handle theme.json RGB color transparency

    WordPress’s theme.json has brought unparalleled ease to theme customization. However, the default color settings, which are typically in hexadecimal format, lack support for transparency. To enhance your theme’s color capabilities, we’ve developed a solution that introduces RGB color values with transparency. Find out how to do it with HSL here. The Code Our custom PHP…

    Read more

  • WordPress – Handle theme.json HSL color transparency

    WordPress – Handle theme.json HSL color transparency

    WordPress’s full site editing capabilities have revolutionized theme customization, allowing for an extensive range of configurations through the theme.json file. However, one limitation has been the inability to handle color transparency effectively with traditional hexadecimal color codes. To address this, we’ve crafted a solution to enhance your theme’s color system. Find out how to do…

    Read more

  • SCSS – Min-Max interpolation

    SCSS – Min-Max interpolation

    Responsive design often requires fluid scaling of elements to fit different screen sizes. A typical use case is scaling typography, where font sizes should adjust between a minimum and maximum size based on the viewport/container-size. To facilitate this, we use min-max interpolation techniques. SCSS Helper Functions The SCSS code includes several functions designed to enable…

    Read more

  • SCSS – Remove units from numbers

    SCSS – Remove units from numbers

    In the realm of CSS preprocessing, we often encounter situations where we need to perform calculations or pass values to functions that expect unitless numbers. However, numbers in CSS often come with units like pixels (px), ems (em), or percentages (%), which can be problematic in such cases. Introducing the strip-unit Function To address this…

    Read more

  • SCSS – Internationalization of Quotation Marks

    SCSS – Internationalization of Quotation Marks

    In written language, different cultures use different symbols to denote quotations. For instance, English typically uses “curly quotes,” while French favors «angle quotes», and German uses „bottom quotes“. Ensuring that the correct quotation marks appear based on the language of the text is an important detail for maintaining the authenticity and readability of multilingual content…

    Read more

  • WordPress – How to remove default theme colors

    WordPress – How to remove default theme colors

    Crafting a unique look and feel for your WordPress site often involves overriding the default color palettes, gradients, and typography sizes that come with the core or themes. The following PHP code snippet is designed to help you start with a clean slate by removing these defaults. The Code This snippet should be added to…

    Read more

  • WordPress – Enhance Rest API security with Nonce

    WordPress – Enhance Rest API security with Nonce

    The WordPress REST API opens up a world of possibilities for developers by allowing programmatic interaction with site data. However, with this power comes the need for heightened security to ensure that only authorized requests are processed. The following PHP snippet demonstrates how to secure REST API access using a nonce—a unique number used to…

    Read more

  • WordPress – Remove sensitive Rest API Endpoints

    WordPress – Remove sensitive Rest API Endpoints

    WordPress’s REST API provides a flexible way to interact with your site’s data. However, there might be instances where certain endpoints can expose sensitive information or provide vectors for potential attacks. The following PHP snippet helps tighten security by removing specific endpoints from the WordPress REST API. The Code This snippet should be placed in…

    Read more