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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T05:51:17+00:00 2026-05-30T05:51:17+00:00

We have a text box in this we are allowing 100 characters per line

  • 0

We have a text box in this we are allowing 100 characters per line and saving to DB. Here our problem is that if a user writes 50 characters, presses enter to insert a newline and then repeats this procedure with 40 then 30 then 20 etc. characters per line it’s saving like continues in single line.

Ex : user enter given following


The integration system test environment

is also the first environment

where testers can simulate real attack

scenarios as can be potentially executed

by a malicious, external or internal user of the application

but when saving into our DB it’s saving like following.

The integration system test environment is also the first environment where testers can simulate real attack scenarios as can be potentially executed by a malicious, external or internal user of the application.

We are disabling by default all html tags only we need to display text as user given by adding automatic “br”.

  • 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-30T05:51:19+00:00Added an answer on May 30, 2026 at 5:51 am

    First of all: The text you get from the text box may contain line breaks and they will be stored in SQL Server, but you won’t see it in the Management Studio. It will appear to be one line even though it isn’t.

    I suspect the problem you’re having is that reading the text from the database and displaying it on the web site does not use any line breaks – this is because line breaks are not used in HTML to break lines. The <br /> tag is used to break lines in HTML. So what you’d need to do is:

    1. Read text from database
    2. Replace \r\n with <br />
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a program which has a text box that the user can edit.
I have a text box that I have turned on HTML rendering for. This
I have a custom dialog page that contains a text box. When the user
I have this bit of script to widen a text box on mouseover and
I have asp.net TextBox with ontextchanged event this is search text box in my
I have this html page which is very simple, it contains a text box
I have text box on 1.php like this <input type=text id=1 value=somevalue> & text
I have a simple control that has a masked text box: xmlns:extToolkit=http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit/extended ... <extToolkit:MaskedTextBox
I have a text box on a page, and when the user clicks Submit
I have a text box like this <TextBox x:Name=SA1 Grid.Row=1 Grid.Column=1 TextAlignment=Center/> I need

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.