what to do if feature service work with only version 4.7 ?

913
14
Jump to solution
08-28-2018 02:42 PM
Rocky_
by
Occasional Contributor

I am using few urls as feature layers for graphical representation..but when I tried to use 4.8 ArcGIS JS version it gives me error..

works fine with 4.7..

What to do to work same urls in 4.8 vs of ArcGIS JS...

Any suggestion..

Thanks a lot..

0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Esteemed Contributor

Your fix to this would be quit using Chrome Web Server extension and start using your machines IIS and the machine name in the url. Then you will not have any issue.

View solution in original post

14 Replies
RobertScheitlin__GISP
MVP Esteemed Contributor

Raj,

   Are you using localhost or file in the url? If so that is the issue i 4.8 you have to use your machine name in the url when developing

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

What is the url that you are using to develop your app?

0 Kudos
Rocky_
by
Occasional Contributor

yes I am using localhost.

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

Raj,

  No, not the url of a service you are using but the url that you have in your browser to run your app.

0 Kudos
Rocky_
by
Occasional Contributor

when am trying to do spatial filter it shows me these errors..

Failed to load resource: net::ERR_CERT_AUTHORITY_INVALID

[esri.layers.FeatureLayer] #load() Failed to load layer

Promise rejected: Error loading

Promise rejected: esri/config: esriConfig.request.proxyUrl is not set. If making a request to a CORS-enabled
server, please push the domain into esriConfig.request.corsEnabledServers.

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

OK, but you understanding my question about the url you are using when accessing your developed application likely has a large impact on that error. So when I am developing on my laptop I have my html files in a certain directory (say c:/JSWorkspace) and that folder in setup as a virtual folder in IIS so that I can access it using a url like http://gislap183/js/ in my web browser. So if I am working on testing.html then the url I use to debug and run my app is http://gislap183/js/testing.html. Now if you are using file:///C:JSWorkspace/testing.html in your browsers url then that is what I mean by file system url. If you are using http://localhost/js/testing.html that that is what I mean by localhost. Neither of those urls will working in JS API 4.8 properly.

Rocky_
by
Occasional Contributor

I totally understand that. .

I am using Web Server for Chrome extension to run program..

but I think web service need some modifications..

its not properly working in 4.8..only works with 4.7

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

RAJ,

   I have no experience using Web Server for Chrome extension. But it is likely running into the same issue that 4.8 does when you use localhost or file based urls. Does your machine not have IIS installed?

0 Kudos
Rocky_
by
Occasional Contributor

No, don't have IIS... can you tell me one thing. even the feature layer is not working with 4.8... only working with 4.7 JS...

Is there any possiblity to use the same url with 4.8..

Or need to update service itself..

0 Kudos