I was wondering if there was any way to get the API Server Url in apex code
ex . API.Partner_Server_URL_280
Or how to pass the value from VisualForce to apex.
I tried
<apex:param name="apiSessionId" value="{!$Api.Session_ID}" />
<apex:param name="apiServerURL" value="{!$Api.Partner_Server_URL_280}" />
<apex:outputText value="API Session Id: {!apiSessionId}"/><br></br>
<apex:outputText value="API Server URL: {!apiServerURL}"/><br></br>
and
public class TestController {
public String apiSessionId {get;set;}
public String apiServerURL {get;set;}
public TestController() {
}
}
but my Visual force page always says nothing.
Any help would be appreciated! Thanks