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 8452223
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T11:26:41+00:00 2026-06-10T11:26:41+00:00

I am going to design front end using JSP containing Start date, End date

  • 0

I am going to design front end using JSP containing Start date, End date etc.. Finally i have to read these into Java object and write it as XML file. How could i accomplish this.. Please Help me on this requirement.

Thanks,
Narayan

  • 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-06-10T11:26:42+00:00Added an answer on June 10, 2026 at 11:26 am

    You need to get the input in JSP and pass it to the Servlet. Then you can use XStream to write to the XML.( I assume that you write the XML on the server, if you need to write the XML on the client computer – just import the xstream package iito your JSP header and put the servlet code snippet in your JSP)

    <%@ page import="java.io.*,java.util.*, javax.servlet.*, com.thoughtworks.xstream.XStream" %>
    <html>
        <head>
             <title>Handle Current Date & Time</title>
        </head>
        <body>
            <center>
                <h1>Display Current Date & Time</h1>
            </center>
            <%
                Date date = new Date();
                // initialize date from input
                // ...pass the date to the servlet
            %>
        </body>
    </html>
    

    in the servlet code :

    Date date = /* get the date from the request*/
    // then do something like this:
    XStream xstream = new XStream();
    xstream.alias("date", Date.class);
    String xml = xstream.toXML(date);
    // write the xml string to the file.
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a project going on, and I am in charge of the front-end
I have a Spring-MVC based webapp with a JSP front end. It is your
I have a class which is going to need to use the strategy design
I am a front-end developer/designer collaborating with a Rails back-end developer. Basically I design
i have a split front-end and back-end access database. i am planning to move
I've currently coded all of the front-end design to work 100% correctly in Chrome.
I am going to design an App for iPhone 4s where user will have
I am going to design a site using asp.net, and after watching a tutorial
I'm going to write an ASP.NET MVC 2 application using Domain Driven Design. I'm
I have an N-tier application, ASP.Net front end, then a .Net C# Business and

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.