Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 893817
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T14:16:52+00:00 2026-05-15T14:16:52+00:00

I am using Jboss and Netbeans to create Spring MVC web application on windows.

  • 0

I am using Jboss and Netbeans to create Spring MVC web application on windows.
it runs on http://localhost/myapplication/

My project path is D:\Myapplication\

My JSP Views are in D:\Myapplication\web\jsp\

My Javascripts are in D:\Myapplication\web\js\

Controllers are in D:\Myapplication\web\src\java\controller\

I have created 1 controller which needs to create a HTML file at javascript location i.e. D:\Myapplication\web\js\

I am using Jquery.sheet to create a web spreadsheet.
and I want to use this HTML to load the Jquery.sheet for this i just want that Relative URL of that HTML stored in JAVASCRIPT location.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T14:16:53+00:00Added an answer on May 15, 2026 at 2:16 pm

    That depends on the request URL of the page for which jQuery.sheet is been executed.

    First check in the browser address bar the absolute URL of the webpage which uses jQuery.sheet. It may be for example http://localhost/myapplication/jsp/page.jsp.

    Then check/test in the browser address bar the absolute URL of the generated HTML file in question. It may be for example http://localhost/myapplication/js/generated.html.

    The common path for both is only one folder level up: ../ which will end up in http://localhost/myapplication. From there you can just access the JS folder and the generated HTML file by js/generated.html.

    Summarized, the relative URL you need is ../js/generated.html.


    Update: as per the comment it turns out that you’ve elaborated your problem in a completely different perspective. You were talking about URL’s in client side perspective while you actually meant about local disk file system paths at the server side. In that case, just use ServletContext#getRealPath() to convert a relative web path to an absolute disk file system path.

    String relativeWebPath = "/js";
    String absoluteDiskPath = servletContext.getRealPath(relativeWebPath);
    File generatedHtml = new File(absoluteDiskPath, "generated.html");
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am making a web application using JBoss Seam 2.2.0, and I want to
Given a web application built using Jboss seam with following details: dynamic web module:
I'm using JBoss Web Services for a payment service application. At some point I
I'm developing a web project with Java EE using JBoss 5. My WebContent folder
I have recently started using Netbeans with following stack Liferay, icefaces with jBoss. Is
I'm using Jboss 7.1.1.final and i have an application with heavy use of JMS.
I am project I will be using following tech. JSF 2.0, Hibernate, Spring, jBPM,
I am using JBOSS AS 7.0.2. I want to create a connection to mysql
I am using jboss 4.2.3 with metro. I deploy an EJB 3.0 web service
Using jboss-esb 5.1.0.GA I have a web service that an EJB that I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.