• Resolved surathchandra15

    (@surathchandra15)


    I want to change the order of the fields when it shows up on my site. I am using divi. Is there a way to do this without creating a child theme?

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Gemini Labs

    (@geminilabs)

    To change the order of the fields in the submission form:

    /**
     * Customises the order of the fields used in the Site Reviews submission form.
     * @param array $order An array of the field keys
     * @return array
     */
    add_filter('site-reviews/submission-form/order', function ($order) {
        // Simply change them to the desired order.
        $order = [
            'rating',
            'title',
            'content',
            'name',
            'email',
            'terms',
        ];
        return $order;
    });

    If you don’t want to create a Child Theme, you can use the Code Snippets plugin instead of pasting it in your theme’s functions.php file.

    Thread Starter surathchandra15

    (@surathchandra15)

    Okay, I will try it out with code snippets.

    Thread Starter surathchandra15

    (@surathchandra15)

    It worked for the submission form. But i want to change the order of fields of the displayed reviews. Not the submission form.

    Looking forward to your reply.

    Plugin Author Gemini Labs

    (@geminilabs)

    That is only possible to do by using a custom template in a child theme.

    Thread Starter surathchandra15

    (@surathchandra15)

    Can it be done placing the custom template in the theme folder itself? I won’t be updating the theme so won’t be loosing the changes. But is it possible?

    Plugin Author Gemini Labs

    (@geminilabs)

    If you are never going to update your theme, then yes.

    1. Create a folder in your theme called “site-reviews”.
    2. Copy the template files that you would like to customise from “/wp-content/plugins/site-reviews/templates” into this new folder.
    3. Open the template files that you copied over in a text editor and make your changes.

    Thread Starter surathchandra15

    (@surathchandra15)

    okay. I will try. Please stay in touch.

    Thread Starter surathchandra15

    (@surathchandra15)

    Hi. I was able to do it in the child theme and it worked. Thank you.

    But the title is now shifting a bit towards the left.

    https://www.swingingtales.com/clientele/

    How can I allign them towards left?

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘How to change the positioning of the fields in divi’ is closed to new replies.