function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Nilesh ManeNilesh Mane 

How can I login in to Customer Portal on a button click from VF page???

Hi All,

 

Hope you are doing well....!!!!

 

I want to login in to my customer portal on a button click.

I am creating a customer portal user, through apex. On same vf page I have created a button 'Login As Portal User'.

After creating a portal user, we need to click on 'Login As Portal User' button to login in to Customer portal.

 

Any idea? 

How can I login in to Customer Portal on a button click from VF page???

 

PLz help, its urgent.

 

Regards,

Nilesh.

Best Answer chosen by Admin (Salesforce Developers) 
Navatar_DbSupNavatar_DbSup

Hi,

 

On the button click open the below link and pass the required parameter orgid in oid, portal user id in suportaluserid and portal id in suportalid.

 

servlet/servlet.su?oid=00D90000000L4fo&suportaluserid=00590000000KXqs&targetURL=%2Fhome%2Fhome.jsp&suportalid=060900000004rWR

 

Try the below code sniipet as reference:

 

<apex:page >

<Apex:form >

<apex:commandLink target="_blank" action="/servlet/servlet.su?oid=00D90000000L4fo&suportaluserid=00590000000KXqs&targetURL=%2Fhome%2Fhome.jsp&suportalid=060900000004rWR" value="open portal" />

 

</Apex:form>

</apex:page>

 

Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved. 

All Answers

Navatar_DbSupNavatar_DbSup

Hi,

 

On the button click open the below link and pass the required parameter orgid in oid, portal user id in suportaluserid and portal id in suportalid.

 

servlet/servlet.su?oid=00D90000000L4fo&suportaluserid=00590000000KXqs&targetURL=%2Fhome%2Fhome.jsp&suportalid=060900000004rWR

 

Try the below code sniipet as reference:

 

<apex:page >

<Apex:form >

<apex:commandLink target="_blank" action="/servlet/servlet.su?oid=00D90000000L4fo&suportaluserid=00590000000KXqs&targetURL=%2Fhome%2Fhome.jsp&suportalid=060900000004rWR" value="open portal" />

 

</Apex:form>

</apex:page>

 

Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved. 

This was selected as the best answer
Nilesh ManeNilesh Mane

Hello Navatar_DbSup,

 

Thanks a lot.

Its working fine.

 

Regards,

Nilesh.