473,651 Members | 2,635 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How can I make my echoed out for break automatically

1 New Member
In my website I am making I have a comment box, and I would like to know how I can get the comment to automatically do a line break instead of going of the page when I echo the comment out form the MySQL data base. Here is and example of the echo statement.

echo '<center>' . '<font color="blue">' . $name . '</font>' . '<br />' . $comment . '<br />' . '</center>' . $date . '<br />';

The "$comment" is what I want to automatically break. Can you help me?
Apr 20 '12 #1
2 1698
Bharat383
93 New Member
echo '<div><center> ' . '<font color="blue">' . $name . '</font>' . '<br />' . $comment . '<br />' . '</center>' . $date . '</div>';
Apr 21 '12 #2
Bharat383
93 New Member
echo "<div>".$name." </div>";
echo "<div>".$commen t."</div>";
echo "<div>".$date." </div>";
echo "<hr>"; <------ if you wish to make separate comment ....--->
Apr 21 '12 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

5
3330
by: Martin Lucas-Smith | last post by:
Is there any need to keep the final break in a switch which uses a default at the end? I.e: switch ($data) { case 'foo': # Action break;
37
12727
by: ajay | last post by:
How to make a web page getting refreshed after a given time interval automatically. HTML Code plz. Tx Ajay
2
2020
by: Matt Silberstein | last post by:
Is there a way to have a style that gives me a "paragraph" break automatically. I have a calendar that is vertical on one page and horizontal on the other, but has the same content. If I could change that with the style sheet it would be great.
18
20518
by: Gustaf Liljegren | last post by:
IE does, and I can't remember this used to be a problem in Netscape. I guess someone in the Mozilla team just came up with a Smart Idea about the True Semantics of the Hyphen Minus character. :-( How do I make IE and Firefox agree to make hyphens trigger a linebreak? Gustaf
0
1278
by: michael | last post by:
On my ASP.NET pages, it seems that _after_ any web or user control - an extra (small) line break or space is inserted automatically right after the Control. This is unwanted since it messes up vertical alignment preventing me of having things "touch" each other. I have tried surrounding the controls in a DIV tag with padding set to 0 but this still does not help. What must I do to prevent this line-break or space to happen after a...
3
3978
by: michael | last post by:
On my ASP.NET pages, it seems that _after_ any web or user control - an extra (small) line break or space is inserted automatically right after the Control. This is unwanted since it messes up vertical alignment preventing me of having things "touch" each other. I have tried surrounding the controls in a DIV tag with padding set to 0 but this still does not help. What must I do to prevent this line-break or space to happen after a...
0
1169
by: robert_payne | last post by:
Hi all, I have a little problem with page breaking on XP IE6. I can force a page break on page 1 where I intend but the subsequent page then breaks automatically where it would have done without the first break. The browser seems set to break after what it thinks as a page full of lines even though that happens to be half way down the next page. I am ofcourse using 'page-break-after:always'. Any suggestions much appreciated. Rob
16
8371
by: matt | last post by:
hello, ive been trying to figure something out, largely thru trial & error. thought perhaps someone else may have knowledge. i have an html table that consists of blocks of related data -- each block contains three rows. this table is destined for paper printing. i would like to tell the browser *not* to bust up my blocks. rather, i would like it to smartly insert a page break inbetween <tbody>s if the last one cannot be rendered...
4
1347
by: dannyboy | last post by:
Hi I'm trying to echo some php into a piece of javascript that checks that the selectedIndex in a given select name is not 0, and gives an alert if this is so: //// <script language="JavaScript"><!-- function validate(form) { if (form2.pmethod.selectedIndex == 0) { alert('You have not selected a postage method. Please select one.'); return false; }
7
4196
by: jeddiki | last post by:
Hi, I am using a function called htmlwrap() which states that it does NOT add a "<br>" to the 70 character line so that it forces a line wrap. ( the script safely wraps long words without destroying html tags which wordwrap has a tendency of doing! )) What I want to do is add that line break so that it DOES force a line wrap - but I am not sure where to insert it in the function
0
8349
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
1
8460
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7296
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6157
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5609
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4143
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2696
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1906
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1585
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.