• Join the Best Wordpress and Elementor Support forum

    Provide or get advice on everything Elementor and Wordpress, ask questions, gain confirmation or just become apart of a friendly, like minded community who love Wordpress and Elementor


    Join us!

Elementor media control is not working on live website (Works on editor)

D

davidxoma

New Member
I have Media control code in elementor. This control is about to show default image on posts archive when the post has not featured image. Everything works perfect on left side editor, when I choose default image, posts without featured images displaying choosen image, but when I open live website it shows Elementor's default image, placeholder.png (as you see in the code its a default image if did not choose anything). Did print_r the $settings variable and image_def's url is blank. For some reason image that I choose is not saved for live website. Have no idea what is happening
PHP:
$this->add_control(
        'image_def',
        [
            'label' => __( 'Choose DEF image', 'plugin-domain' ),
            'type' => \Elementor\Controls_Manager::MEDIA,
            'default' => [
                'url' => \Elementor\Utils::get_placeholder_image_src(),
            ],
        ]
    );
 
D

davidxoma

New Member
Ask me any information about my plugin code e.c Can't post it fully because its so big
 

Latest Resources

Other Elementor Resources

elementor official

Still stuck? Ask the forum

Post your question with a screenshot and a link if you can, and a member will usually reply within a day. Free to join, no sales pitch.

Create a free account
Top