Jump to content
Zohaib-fk

disable back-office form field

Recommended Posts

Hi,

I want to disable file upload field in back-office. Like in html we use disabled, I want to know is there any way to disable field in prestashop.

 

<input type="text" name="lname" disabled>
array(
                    'type' => 'file',
                    'label' => $this->l('Upload Image File'),
                    'name' => 'sfk_image_name',
                    'display_image' => true,
                    'required' => true,
                    'desc' => $this->l('Upload an image from your computer. When doing edit record old image will be used if no image uploaded.')
  ),

 

Share this post


Link to post
Share on other sites

For disabling field in form you need set :

array(
                    'type' => 'text',
                    'label' => $this->l('Name'),
                    'name' => 'name',
                    'required' => true,
                    'disabled' => true
                ),

add parameter disabled

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More