Change title of a node programmatically before displaying it
To modify the node title while displaying, I had to do changes in the theme.

Implement the hook (don't remember if it was already there) in template.php file:

function themeName_process_page(&amp;$variables)


And then had to add this part of custom code at the end of the function:

// Raj: To Append the scientific name and it's desciber to the title
$nodesArray = $variables['page']['content']['system_main']['nodes'];
if (!empty($nodesArray))
{
    foreach ($nodesArray as $speciesNode)
    {
        if (!empty($speciesNode['field_common_names']))
        {
            $scientificNameArray = $speciesNode['field_scientific_name_1'];
            if (!empty($scientificNameArray))
            {
                $theScientificName = '&lt;span id="ScientificNameDIV" class="ScientificNameSuffixClass"&gt;' . $scientificNameArray[0]['#item']['first'] . '&lt;/span&gt;';
                $theDesciber = '&lt;span id="ScientificNameSimpleDIV" class="ScientificNameSimpleClass"&gt;' . $scientificNameArray[0]['#item']['second'] . '&lt;/span&gt;';
                $prominentName = $variables['title'];
                $sciFiNameAndDescriber = $theScientificName . ' ' . $theDesciber;
                $variables['title'] = $prominentName. ' ' . '&lt;span id="ScientificNameSimpleDIV" class="ScientificNameSimpleClass"&gt; ( &lt;/span&gt;' . $sciFiNameAndDescriber . '&lt;span id="ScientificNameSimpleDIV" class="ScientificNameSimpleClass"&gt; ) &lt;/span&gt;';
                $variables['title'] = '&lt;div id="CommonNameAndScientificName" class="CommonAndScientificClass"&gt;'.$variables['title'].'&lt;/div&gt;';
                break;
            }
        }
    }
    unset ($speciesNode);
}


Please see that in the above code, most of it belongs to the context of my website where I had to append the scientific name of the species to the title of the species inside brackets. The point here is, you need to modify the $variables['title'] inside process_page() hook.

Also most important, to see the changes in affect, clear the cache. I had a rough time thinking that the changes are not working, only very late did I realize that I was doing everything right but did not clear cache. It's a learning experience for me.