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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T15:24:07+00:00 2026-05-11T15:24:07+00:00

I’m trying to achieve a layout in html that looks exactly like this when

  • 0

I’m trying to achieve a layout in html that looks exactly like this when printed:

 Comments: _____________________________________________ _______________________________________________________

…where the underlined portion is a single input tag of some kind — meaning it could also be a textarea or something else, as long as the user can input text and print it out.

The requirements:

  • The ‘Comments‘ text must be on the same line as the first line of input text
  • I cannot just put the word ‘Comments’ inside a textarea.
  • I cannot use multiple text inputs
  • Both lines of input should be underlined when printing
  • I can’t count on the page submitting before print: I have do nearly everything client-side.

The reason is that I have to visually re-create a paper document from an outside company to be an exact match when the page is printed from a browser. This is part of an internal ‘forms’ system that pre-dates me with this company. It’s set up so these forms automatically have margins and headers adjusted in the browser, so that’s not an issue. Getting this html formatted the way I need is.

  • 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. 2026-05-11T15:24:08+00:00Added an answer on May 11, 2026 at 3:24 pm

    Try using a relatively positioned div, it will contain a text area along with another div positioned absolutely.

    <div id='outer' style='position: relative'>     <textarea id='txtArea' style='text-decoration: underline;'></textarea>     <div style='position: absolute; left: 5px; top: 5px;'>Comments:</div> </div> 

    You’ll have to style the textarea a bit to get the effect you desire.

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

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
I've got a string that has curly quotes in it. I'd like to replace
I am trying to render a haml file in a javascript response like so:
I have this code to decode numeric html entities to the UTF8 equivalent character.
I would like to run a str_replace or preg_replace which looks for certain words
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I'm trying to create an if statement in PHP that prevents a single post

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.