AnsweredAssumed Answered

How to login to rest services with javascript

Question asked by ismail_codar on Oct 11, 2011
Latest reply on Apr 22, 2012 by mak10
I'am using jquery. I can not run the following code.
Returns 405 Method Not Allowed http error.
If you remove line of the contentType: "application/json; charset=utf-8"  returns 415 Unsupported Media Type.

   <script type="text/javascript" src=""></script>
   <script type="text/javascript">
     type: "POST",
     url: "http://localhost:8080/activiti-rest/service/login",
     dataType: "json",
     contentType: "application/json; charset=utf-8",
     data: {
      "userId": "kermit",
      "password": "kermit"
     success: function(json) {