One of our customer requested a code snippet to write a function which will check that if current post or page has a specific Oxygen template assigned.
Here’s a PHP snippet that you can use to return a custom link to a specific language for the current page using WPML. This will output the custom link for the specified language code and can be used on any page. Example 1: This will output a link that says “Switch to French” and links…
This php snippet will provide you with a more efficient way of organizing and keeping track of your blocks in Oxygen builder.
Here is an example code snippet for creating a custom gallery slider for WooCommerce products: In this example, we are using the woocommerce_product_thumbnails action hook to add a custom gallery slider to the product page. We are using the Owl Carousel jQuery plugin to create the slider and enqueueing its required CSS and JS files.…
Note : The use-cases for this are below : 1. Using Swiper Slider and want to edit all the slides in Oxygen and show slider view only on front-end. 2. Using Scripts that runs only on front-end or load after the page-load. In Oxygen builder they displays an error like ‘SCRIPTNAME’ is not defined or…
This code will add additional categories into oxygen block library
Video Tutorial Basic oxygen structure with:div.container > list wrapper (with image inside) + menu element Front end preview Front end preview for mobile
If you need to pause the Oxygen Slider Element on hover, it is not there by default. Just use the below Javascript (jQuery) in a code-block on the and add the below code to JS section. Note : Just comment the PHP/HTML content middle Line.
If you want to remove the widget title conditionally just use the below code-snippet. I’m using Scripts Organizer to add it, you can also do it via any Code Snippet or functions.php if you are using a theme. Steps to use it in Scripts Organizer : Add a new code block, Set Trigger Location to…
The Oxygen slider element shows all slides once in a flash on page load then go correct styling. This is called FOUC (Flash Of Unstyled Content). If you are facing the same issue, here is the solution. Just follow steps. Copy your slider element ID in somewhere like notepad and add an extra class to…
If you are importing frameworks such as Bootstrap, Tailwind CSS, Bulma, Materialize … you may not want that Oxygen Builder defaults overwrite some of frameworks styles. Thats why we offering solution do remove Oxygen CSS. Keep in mind that if you disable Oxygen CSS non of Oxygen CSS’s will be added on the website: Oxygen…
I put this code-snippet to every Oxygen site i develop, because it is faster to go to the settings by admin bar,I use Scripts Organizer to use this as below : Add a code-block with Trigger location set to EVERYWHERE put the code and you are done.
Use the following code to add extra required classes during Oxywind worker compiling / cache generation when you are ready for production. You may want to do this if you want to use tailwind classes in your HTML code outside of oxygen elsewhere in wordpress or a 3rd party / custom plugin. This will save…
Setup daisyUI CDN Ready For Development Add the following code to use the full daisyUI CDN while developing, this includes all daisyUI elements. These will be later purged by the Oxywind worker so only the elements you use will be included in your production site. Add daisyUI To Oxywind Worker Configuration In the Oxywind settings…
if you do not use it. Keep add elements sidebar clean. Solution to hide If you are using Scripts Organizer download code snippet Solution to Disabled Thanks to Suppa Mike for providing second solution.
This will allow you to create a button that uses the history states to go back with pure HTML. You will then have to style it to make it look as required. It is useful if you end up on checkout pages or forms that have no headers or footers and wish to give the…
Add the following PHP code snippet in your favorite code manager plugin like Scripts organizer and set it to load on front end
3rd party plugins admin after_body Alt archive Blocks Category clean up composite elemenets core CPT CSS Custom Custom Post Dashboard flexslider Front End FSE full site editing Gallery hook HTML Image load styles Must Have notice Oxygen Password Permalink plugins Post List Publish Date repeater settings page share single product Taxonomy Taxonomy Term themes Tips Topbar WooCommerce wordpress WP Admin WPML
Notifications