How can add custom options title in drop down of product in magento

Located in app/code/core/Mage/Catalog/Block/Product/View/Options/Type/Select.php

find this function in above file “public function getValuesHtml()”

now in second if loop you can see this select method

                    ->addOption(”, $this->__(‘– Please Select –‘));

add this line at above of code

$getOptionName = ucwords($_option->getTitle());

now code look like as

$getOptionName = ucwords($_option->getTitle());
->addOption(”, $this->__(‘– Please Select ‘.$getOptionName.’ –‘));

Now go to frontside and option name will be display in drop down.

For reference


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s