javascript - how to echo data as it is in the DB the same format? -


i developing web application data in database

" 10 functions   touch control   lcd display    electric programmer with:   minute minder,  automatic start   automatic end of cooking end cooking acoustic alarm additional menu programmes:  showroom mode  limited power  consumption mode   ecologic (nominal power < 2.3 kw)  locking function (child safety lock) electronic temperature control  rapid pre-heating   temperature range: 30-280 °c   large 72 litres cavity (+ 35% volume)  5 cooking levels " 

as see data in db formatted each 1 in line when data db using php , echo it appear paragraph not each data in line ...and want data echoed above format should do?

i have data not stored in useful/sensible way, if has newline @ end of every line need convert newline's html understands, <br> tags.

so try this

echo nl2br($database_column_value); 

Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

gradle error "Cannot convert the provided notation to a File or URI" -

ios - Possible to get UIButton sizeThatFits to work? -