the answer for all question about Oxygen Builder plugin and WordPress

Hey OxySnorters,

Hey OxySnorters,

So I’m using a Repeater with Default query to display Woocommerce products in the archive pages (Archive & Category). That’s easy.

Now, I need to display these products in a specific order. So I create a custom field ‘product_seq_no’ and give a few numbers to the products. That’s easy as well.

Then I added a code block with the below code to sort the products. That’s easy too –

query_vars[‘post_type’]) && $query->query_vars[‘post_type’] == ‘product’ ) {
$query->set(‘orderby’, ‘meta_value’);
$query->set(‘meta_key’, ‘prod_sequence_number’);
$query->set(‘order’, ‘ASC’);
return $query;
add_action(‘pre_get_posts’, ‘my_pre_get_posts’);

But it didn’t work! I think it should have, but it didnt!
Any experts here to tell me where I messed up? xD


Leave A Reply

Your email address will not be published.

Oxyrealm Docs