Category: Plugins
With articles also related to:
Aleš Sýkora wrote:
Oxygen Pro Menu Vertical divider between items
November 28, 2023 in Custom Code, Oxygen Builder, Plugins, WordPress
If you want to add a vertical dividers between menu items, it’s simple. Just add the border-right to each (but not last) item in the menu. You can use and modify this code to add the vertical lines: Change the .pro-menu-class to your class: And customize the border-right values – width, type of border and…
Aleš Sýkora wrote:
Load Gutenberg Styles only if page has blocks
November 28, 2023 in Custom Code, Oxygen Builder, Plugins, WordPress
Trying to speed up your site? You may want to disable Gutenberg block style libraries on pages and posts which doesn’t have any blocks. Add this code to your custom snippets and test it. It should disable loading of Gutenberg styles when not needed. It works with Oxygen Builder and Advanced scripts – I have…
Aleš Sýkora wrote:
Get ACF taxonomy field for current post in Query
April 5, 2022 in ACF, Oxygen Builder, Plugins, WordPress
For a situation where you need to display ACF taxonomy field for current terms assigned to the post in the WP Query, you may need the code below. Why to use ACF taxonomy field? It’s easy. I am using this for SEO purposes. How? I am creating website for language school. My taxonomy is called…
Aleš Sýkora wrote:
Display only parent posts with repeater dynamic query in Oxygen builder
November 28, 2023 in Oxygen Builder, Plugins, WordPress
If you need to display only parent pages or posts, you just need to put post_parent = 0 parameter to your dynamic query in Oxygen builder. So it will work like normal WordPress query:
Aleš Sýkora wrote:
Get first term of current post in WordPress query
March 24, 2022 in Custom Code, Oxygen Builder, Plugins, WordPress
If you want to display only one first term assigned to your post, add this code. It will add a link to the category with CSS class with category slug, so you can style it separately from other categories. This snippet will get all terms assigned to the post with get_the_terms function. You can also…
Aleš Sýkora wrote:
Query all posts from category with category__in instead of tax_query in Oxygen Advanced Query builder
November 28, 2023 in Custom Code, Oxygen Builder, Plugins, WordPress
If you want query some posts from one category, you don’t need to build the tax_query. You can use simpler solution, the category__in parameter. For example, you need to show 3 latest posts from media-mentions category. So go to the administration and find your taxonomy id. Mine is 13 so I will use it like…
Aleš Sýkora wrote:
Display WooCommerce variation price as main price in Oxygen Builder
December 6, 2023 in Custom Code, Oxygen Builder, Plugins, WooCommerce, WordPress
To display the variation price as the main price within Oxygen Builder and WooCommerce, you need the JS snippet.
Aleš Sýkora wrote:
Display product custom attribute description in WooCommerce
November 28, 2023 in Custom Code, Plugins, WooCommerce, WordPress
If you created custom attributes for product variation and you filled in their description, you may need to show the description on product page. Product attributes are saved as an taxonomy terms. So you need to take a look, how the taxonomy is called in URL. It starts with pa_ and usually copy the name…
Aleš Sýkora wrote:
Repeater pagination position FIX for Oxygen Builder
November 28, 2023 in Oxygen Builder, Plugins, WordPress
If you use repeater in Oxygen Builder you may already know, that pagination component is on same position as columns. So when you use the grid in repeater, you may encounter it at wrong position. How to fix it? Just add this to your CSS: For CSS Grid: For flexbox: And after that, position in…
Aleš Sýkora wrote:
How to use Highlight.js with WordPress and share your code
November 28, 2023 in Custom Code, Oxygen Builder, Plugins, WordPress
Would you like to use Highlighter for sharing your custom code in articles created in Gutenberg editor? No need to install plugins. Just use the Highlight.js library. This library will highlight everything between <pre><code>YOUR CODE</code></pre>. I was using Google highlighter in the past, but since it is deprecated, my favourite is highlighter.js. Today I will…