Domanda

i had written a javascript in home page component.it'll load as soon as we login to the salsforce and its working fine. but if i open Visualforce page it throws "sf:invalid code...invalid session id." How to resolve this issue. following is the session code i used in javascript.

sforce.sessionId = getCookie('sid'); sforce.connection.sessionId=sforce.sessionId;

È stato utile?

Soluzione

If you want get session id, you can try to use next JS code:

var __sfdcSessionId = '{!GETSESSIONID()}';
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top