Showing "301 Moved Permanently", while I'm using AngularJS doc.
cause: as it it using
but the protocol has been changed from http to https. So it is showing this type of error.
Is there any fix/patch/hack available, which I can apply to my current NetBeans IDE to solve this issue?
Reffered to this Bug: http://hg.netbeans.org/web-main/rev/ffaeea96715a
Just re-created the org-netbeans-modules-html-angular.jar
NetBeans is using URLConnection and Reader class to get the doc from web. It first looks into the cache directory if it is available or fetches from web and writes the content to the Cache('ajs-doc' directory for Angular js).[for online doc]
Extracted the org-netbeans-modules-html-angular.jar using WinRar/7zip.
Decompiled the Directive.class using JD-GUI decompiler.(you can get the source from https://netbeans.org/community/sources/)
[stored the Directive.java in Directive.class directory of the extracted files]
Changed old http link to https and doc version in Directive.java.
Compiled the Directive.java using org-netbeans-modules-html-editor-lib.jar and org-netbeans-api-annotations-common.jar
javac -classpath [PATH to dir]\org-netbeans-modules-html-angular;org-netbeans-modules-html-editor-lib.jar;org-netbeans-api-annotations-common.jar [PATH to dir]\org-netbeans-modules-html-angular\org\netbeans\modules\html\angular\model\Directive.java
jar -cvfm org-netbeans-modules-html-angular.jar * MANIFEST.MF
[ Tested in Windows 7, NetBeans 7.4, JDK 7 ]
[NetBeans: Help->About: to view Cache and User directory path]
-> Closed the IDE
-> Replaced the "org-netbeans-modules-html-angular.jar" file with the generated one in the netbeans modules directory.
"C:\Program Files\NetBeans 7.4\ide\modules" and "C:\Users\<Username>\AppData\Roaming\NetBeans\7.4\modules"
-> Removed the "ajs-doc" directory from the NetBeans Cache. [NetBeans is storing the temp doc files here]
-> Now started the IDE and typed "ng-app" in a div/body. used control+space to call the API-Doc window.
Now its working. I can get the doc without any 301 error.
You can use NetBeans 8.0 where it was fixed