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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T17:10:39+00:00 2026-05-31T17:10:39+00:00

The code I’m working with looks something like this: <% MessageInfo msg= hp.getInfo(transactionName, checkpointLoc);%>

  • 0

The code I’m working with looks something like this:

        <% MessageInfo msg= hp.getInfo(transactionName, checkpointLoc);%>
    <form name='editinfo' action="/editmessage.jsp" method="post">
                <table align=center colspan = "3">
                    <tr>
                        <td><u><b>Currently Editing:</b></u></td>
                    </tr>
                    <tr>
                        <td>Name:</td>
                        <td><input type="text" name="tname" style="width:254px" value=<%= msg.getName() %>/></td>
                        <td><%= msg.getName()%></td>
                    </tr>
                    <tr>
                        <td>Search Method:</td>
                        <td><input type="text" name="searchmethod" style="width:254px" value=<%=msg.getSearchMethod() %>/></td>
                    </tr>
</table>
</form>

Right now, it’s displaying oddly in the text boxes.

In the first text box, it is only displaying the first word of the string its supposed to be displaying, but when I do not place the string in a text box, the full string is displayed. For example if “Hello world” was to be displayed, “Hello” would be the only thing displayed in the text box.

For the second text box, I’m having a different kind of problem. This time, a ‘/’ character is being appended to the end of the string. This ‘/’ character does not appear when I have the JSP display it outside of a textbox. In this case, the string is only one word such as “XPath”, and the textbox is displaying “XPath/”

What is causing these text boxes to display oddly?

  • 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-31T17:10:41+00:00Added an answer on May 31, 2026 at 5:10 pm

    In both cases, the cause is likely the same – you’re missing quotes from the value attribute:

    value=<%= msg.getName() %>
    
    value=<%=msg.getSearchMethod() %>
    

    Change to

    value="<%= msg.getName() %>"
    
    value="<%=msg.getSearchMethod() %>"
    

    Without those quotes, you’re generating bad HTML, and relying on gracious behaviour from the browser.

    Also, to be safe make sure that the Strings returned from those methods are properly HTML-ecapaped.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Code Currently my code looks like that. $stmt = $this->db->prepare(SELECT m.id, m.from_id, m.to_id, m.subject,
Code like this often happens: l = [] while foo: # baz l.append(bar) #
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
Code 1: var Something = { name: Name, sayHi: function(){ alert(Something.name); } } Code
Code that was working fine last week is suddenly throwing this exception: System.Data.SqlClient.SqlException (0x80131904):
Code below is not working as expected to detect if it is in design
Code below sets default values for new row if row is added using form.
Code goes first: void foo(int x) { void bar(int); //is this forward-decl legal? bar(x);
I have this code to decode numeric html entities to the UTF8 equivalent character.
Code: LinkButton linkButton = new LinkButton(); linkButton.OnClientClick=changecolor;--i need to change this to on mouse

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.