0

I am trying to call a ExtJS application from a JSP file placed outside my Ext Application's root folder:

folder structure

How I am trying to do it is:

<script type="text/javascript" src="../UI-INF/LoginApp/CustomManifest.js"></script>
                 <script id="microloader" data-app="c320a89b-22a4" type="text/javascript" src="../UI-INF/LoginApp/bootstrap.js"></script>
                 <script type="text/javascript" src="../UI-INF/ext651/build/ext-all-debug.js"></script>
                   <script type="text/javascript" src="../UI-INF/LoginApp/app.js"></script> 

Manifest is unable to properly fetch classic.json due to which I am getting this error:

Unable to load classic.json properly into manifest

What is the proper way to do it?

Note: We cannot change the JSP location or our application location due to server constraints.

parv kothari
  • 91
  • 1
  • 6
  • ExtJS is using relative paths, and they are usually relative to the HTML file index.html. [Luckily, HTML provides a means to switch the base path for all relative paths](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base), so you can try whether `` works for you. – Alexander Mar 16 '18 at 14:47
  • Thanks @Alexander for your response.This kind of did the trick for me as it started loading respective js. But it then changed the location of jsp to UI-INF/LoginApp folder... Wherein I wanted to load the classic.json and all the relative files to WEB-INF/jsp folder.. – parv kothari Mar 22 '18 at 09:12
  • I got it working by changing the path in index.html to `"indexHtmlPath": "../../WEB-INF/jsp/login.jsp"` in app.json which changed the relative paths of all the files that were being fetched by classic.json. Also I wrote a custom manifest to load the classic.json from my desired location as `Ext.manifest = 'UI-INF/LoginApp/' + profile; // this name must match a build profile name` – parv kothari Mar 22 '18 at 09:15

0 Answers0