You need to sign in to do that
Don't have an account?
Radnip
List of limitations of Salesforce sites? Is HttpRequest() permitted?
Firstly I'm trying to find out if you can do an HttpRequest using Salesforce sites my code is:
Http h = new Http(); HttpRequest req = new HttpRequest(); req.setEndpoint('http://website.net/test.php?e=teststs'); req.setMethod('GET'); h.send(req);
But I keep getting "Authorisation Required" appearing... do I need to set some other permissions?
Also is there a list of things you can't do with Salesforce Sites?
Thanks
Francis
You would have to register the site you are trying to access in the remote site setting - see this article http://wiki.developerforce.com/page/Apex_Web_Services_and_Callouts
Hit the "Preview as Admin" link from the Sites page to launch your Site with the ability to see errors. Odds are there is something off in your code that is throwing an exception.
-Andy
I can't use Preview as Admin as based on your permissions different information is displayed and the error doesn't occur running as admin.
If you don't get the error as admin, the first thing I'd check is to see if you are referencing objects that you haven't assigned proper "Public Access Settings" to.