2 quick point-
1)Are you running portal application and ucm at same machine (localhost) ? Need to verify .
2) Which user want of see Site studio Contributor mode ? Does he has the sufficient priviledge/permission for editing? Need to verify.
Thanks for response.
1. I have given an example in the code snippet, even thought I have provided host name of the CS server (CS in separate machine and portal running in separate) ,still the issue persists.
2. I am using user (weblogic) and he has sufficient privileges to create and manage content in content server.
Requesting you to please suggest.