Skip to main content
added 3 characters in body
Source Link
Manoj Deswal
  • 5.8k
  • 25
  • 28
  • 50

after some research got a solution for this , add new property "value" in addField method with

add new property "value" in addField method

with the value you need. see the example:

        $fieldset->addField(
            'user_image',
            'image',
            [
                'name' => 'user_image',
                'label' => __('Image'),
                'id' => 'user_image',
                'title' => __('Image'),
                'value' => $value_that_you_need,
                'required' => false,
                'note' => 'Allow image type: jpg, jpeg, png'
            ]
        );

iI hope it will help samesome of you ..

after some research got a solution for this , add new property "value" in addField method with the value you need. see the example:

        $fieldset->addField(
            'user_image',
            'image',
            [
                'name' => 'user_image',
                'label' => __('Image'),
                'id' => 'user_image',
                'title' => __('Image'),
                'value' => $value_that_you_need,
                'required' => false,
                'note' => 'Allow image type: jpg, jpeg, png'
            ]
        );

i hope it will help same of you ..

after some research got a solution for this

add new property "value" in addField method

with the value you need. see the example:

        $fieldset->addField(
            'user_image',
            'image',
            [
                'name' => 'user_image',
                'label' => __('Image'),
                'id' => 'user_image',
                'title' => __('Image'),
                'value' => $value_that_you_need,
                'required' => false,
                'note' => 'Allow image type: jpg, jpeg, png'
            ]
        );

I hope it will help some of you ..

Source Link

after some research got a solution for this , add new property "value" in addField method with the value you need. see the example:

        $fieldset->addField(
            'user_image',
            'image',
            [
                'name' => 'user_image',
                'label' => __('Image'),
                'id' => 'user_image',
                'title' => __('Image'),
                'value' => $value_that_you_need,
                'required' => false,
                'note' => 'Allow image type: jpg, jpeg, png'
            ]
        );

i hope it will help same of you ..