How to resolve issue with OSLC workshop, getting error "Javascript is either disabled or not available in your Browser"
![]() I am going through the oslc workshop, for "whoami" service I got the user and while trying with the same user with below url as mentioned in oslc workshop I am getting a html response instead of xml response saying "Javascript is either disabled or not available in your Browser".
URL: https://xxxx:yyyy/jts/users/admin
Response:
</head>
<body class="claro">
<noscript>
<div id="net-jazz-ajax-NoScriptMessage">Javascript is either disabled or not available in your Browser</div>
</noscript>
<div id="net-jazz-ajax-InitialLoadMessage">Loading...</div>
<div id="net-jazz-ajax-WorkbenchRoot"></div>
<script type="text/javascript">
djConfig = {
isDebug: false,
usePlainJson: true,
baseUrl: "/jts/web/dojo/",
locale: "en-us",
localizationComplete: true
};
/null/
net = {jazz: {ajax: {}}};
net.jazz.ajax._contextRoot = "/jts";
net.jazz.ajax._appPath = "/jts/auth/authrequired";
net.jazz.ajax._webuiPrefix = "/web/";
</script>
<script type="text/javascript" src="/jts/web/_js/?include=J~&etag=Hv2vIC3eM0p_en_US&_proxyURL=%2Fjts&ss=MKn89&locale=en-us"></script>
<script type="text/javascript">
require("dojo/main").getObject('jazz.core.loader', true)._serverStartup="MKn89";
require("dojo/main").getObject('jazz.core.loader',true)._loaded=["J"];
</script>
<script type="text/javascript">
/
<![CDATA[ /
dojo.addOnLoad( function() {
net.jazz.ajax.ui.PlatformUI.createAndRunWorkbench("net.jazz.web.app.authrequired");
});
/ ]]> /
</script>
</body>
</html>
I am getting proper response only for rootservices(https://xxxx:yyyy/jts/rootservices)
For all other services I am getting same html response with error "Javascript is either disabled or not available in your Browser" after trying with removing cache(mentioned in oslc document) facing same issue.
|
Accepted answer
![]()
Ralph Schoon (62.0k●3●36●43)
| answered Jan 15 '18, 3:52 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER edited Jan 15 '18, 5:17 a.m. This is the symptom for getting an HTML page (with javascript) back instead of an XML/JSON response body. The response HTML has JavaScript and the REST Client can not interpret that.
Titas Dutta selected this answer as the correct answer
Comments Hi Ralph,
I followed the steps mentioned in OSLC workshop document,
2. Request Header- accept : application/rdf+xml
3. As per document no login credentials required in header
4. Already logged in to the application before hitting through postman/restclient.
I checked all these 4 reasons but facing same issue.
No, you are apparently not. I just followed the steps (you fail to say which steps, so I did up to Lab 2.2 page 34 and all the steps worked for me.
If I log out and post again, I get exactly your result.
Thanks for your answer Ralph..after reinstalling REST client it's working fine, I am getting expected result now. ![]() FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Good to Know. I started to use POSTMAN (based on a Crome app) last time I did REST, because it saves requests. I liked it better than the Firefox REST Client.
|
One other answer
![]() You need to authenticate first in CLM in order to share the cookie with the REST client.
|