Solved

Notepad and <TextArea>

Posted on 2008-10-28
4
317 Views
Last Modified: 2010-04-09
In Notepad and the <TextArea>, I set the same font type, Lucide Console, wrote the same text:
first line was Chinese characters, then ENTER, 5 spaces, number 678, ENTER, 5 spaces, number 678.
In Notepad, it displayed as expected:

L-ýW
     678
     678

However, in <TextArea>, the first 678 shifted to left hand side

L-ýW
    678
     678

What I can do to make the text in <TextArea> looks the same as in Notepad?
0
Comment
Question by:markdot
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 

Expert Comment

by:prlamnguyen
ID: 22826705
I think in TextArea of HTML you should use &nbsp; at the begin of the text if you have more than 1 space.
So, did you try: Ctrl + Shift + Space ?
0
 
LVL 44

Accepted Solution

by:
scrathcyboy earned 125 total points
ID: 22827413
"What I can do to make the text in <TextArea> looks the same as in Notepad?"

Nothing.  Text area HTML style contains no formatting at all, it is just a TEXT area.  If you want something different that can retain all formatting, then consider rich text area -- that does all the formatting you need --

www.textarearich.com/
www.dynamicdrive.com/dynamicindex16/richtexteditor/index.htm
www.tcpiq.com/tcpIQ/HTMLRichTextArea/
www.topshareware.com/HTML-Rich-Text-Area-download-1456.htm
0
 

Author Comment

by:markdot
ID: 22827434
Thank you.
I mean the content in TextArea, am not considering after posting the content.
I want the text in <TextArea> looks the same as in Notepad.
0
 

Author Comment

by:markdot
ID: 22827489
scrathcyboy,

sorry, I didn't read your comment when I typed mine.
What I need is a TextArea that accepts any continuous spaces and tabs WHEN THE USER PASTE TEXT FROM OTEHR TEXT EDITOR, and uses monospace. If a rich text area can do this, can you tell me how to include it in Html?
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
output in HTML format powershell 6 49
responsive menu pushes content down instead of going over top 3 29
Incorrect css styling in footer 3 24
Error Handler 8 42
This article discusses how to create an extensible mechanism for linked drop downs.
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question