cancel
Showing results for 
Search instead for 
Did you mean: 

Setup status enabled by default

SOLVED

Setup status enabled by default

Hi!

Do you know how to setup the status enabled by default withouth selecting everytime?

Thank you!

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Setup status enabled by default

The easiest way would be to directly edit app/design/adminhtml/default/default/template/catalog/product/edit.phtml and add following snippet somewhere within <script type="text/javascript"> and </script>.

 

if(document.getElementById('status').value == ""){
    document.getElementById('status').options[1].selected = true;
}

 

The problem in this solution is that this file potentially can be overwritten during next Magento upgrade, so you'll have to repeat this process.

 

Better solution would be to make adminhtml theme, for example in app/design/adminhtml/default/custom, and there you can put modified template into app/design/adminhtml/default/custom/template/catalog/product/edit.phtml

 

If this response was helpful to you, consider giving kudos to this post.

If this response solved your problem, click accept as solution to help others solve this

If this response was helpful to you, consider giving kudos to this post.
If this response solved your problem, click accept as solution to help others solve this issue

View solution in original post

2 REPLIES 2

Re: Setup status enabled by default

It is so sad that the "answer" to my question was a private message

 

Hi,   Regarding your forum topic,  Setup status enabled by default   We would like to introduce our company Netleaf Tech and we have never compromised on the quality and the services provided to the customer. We believe in keeping the customers happy and providing them with products at a very competent price.   We have 6 year experience in Magento, we will fix your site

 

https://netleaftech.wordpress.com/

 

Re: Setup status enabled by default

The easiest way would be to directly edit app/design/adminhtml/default/default/template/catalog/product/edit.phtml and add following snippet somewhere within <script type="text/javascript"> and </script>.

 

if(document.getElementById('status').value == ""){
    document.getElementById('status').options[1].selected = true;
}

 

The problem in this solution is that this file potentially can be overwritten during next Magento upgrade, so you'll have to repeat this process.

 

Better solution would be to make adminhtml theme, for example in app/design/adminhtml/default/custom, and there you can put modified template into app/design/adminhtml/default/custom/template/catalog/product/edit.phtml

 

If this response was helpful to you, consider giving kudos to this post.

If this response solved your problem, click accept as solution to help others solve this

If this response was helpful to you, consider giving kudos to this post.
If this response solved your problem, click accept as solution to help others solve this issue