Site logo

Archived topic

Gravity Form php

4 replies · Started by Farokh on January 21, 2018

Viewing posts 1–5 of 5

Hi Tom,
I got this code from gravity docs (to manually convert GF to RTL while my WP languadge is English), which should be palced "in the header.php file of your active theme just before the wp_head() function call".

I use a child theme, so I added it to my child theme's php file. But it does not work.
Where should I place it? Can you help, please?

add_action( 'gform_enqueue_scripts', 'enqueue_custom_script' );
function enqueue_custom_script() {
    $min = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG || isset( $_GET['gform_debug'] ) ? '' : '.min';
    wp_enqueue_style( 'gforms_rtl_css', GFCommon::get_base_url() . "/css/rtl{$min}.css", null, GFCommon::$version );
}

THANK YOU

I have already tried adding it to my child theme's functions.php file, but it didn't work.

This is the link to the doc. Can you pleas take a look? Maybe I misunderstood something.

3. Manually include RTL stylesheet

THANK YOU>

From what I can see, that should work. Have you reached out to GF support?

This archived topic is closed to new replies.