How to output data from fields created via Redux. WordPress open

How to output data from fields created via Redux. WordPress

Approved. Code works!
This is exactly the working code that is verified by the moderator or site administrators

After creating the settings page of your plugin or theme through Redux Framework.

We can output this data anywhere in the template or theme.

The created data is stored in the global variable whose name we specified when creating the options. In our case name is – mythemename_options

For example, let’s display our data in a template header.php
Insert the code below in the place you need

<?php
global $mythemename_options; // This variable stores all the data 
echo $mythemename_options['text-example']; // We will receive the field created by us through its id
?>

And now we will also display the logo we created, the data of which is a multilevel array

<?php
global $mythemename_options; 
echo $mythemename_options['logo']['url']; 
?>
0

More

Leave a Reply

Your email address will not be published. Required fields are marked *

How many?: 22 + 22

lil-code© | 2022 - 2024
Go Top
Authorization
*
*
Registration
*
*
*
*
Password generation