473,378 Members | 1,343 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

how to change the font style in php

Hello My PHP code is

Expand|Select|Wrap|Line Numbers
  1. <?php
  2. $headers .='From: support@epcindex.com';
  3.  
  4. $link = mysql_connect("localhost", "username", "pwd") or die                      
  5. ("Error connecting to mysql:");
  6.  
  7. mysql_select_db("dbname",$link) or die("Unable to select database: . mysql_error()");
  8.  
  9. $emailid = $_POST["EmailId"];
  10.  
  11. $result = mysql_query ("select Password from USER_ACCOUNT where EmailId = '$emailid' ");
  12. if($row = mysql_fetch_array($result)) 
  13. {
  14. $password = $row["Password"];
  15.  
  16. $row['body'] . " " . $row['emailid'];
  17. $row['emailid'] . " " . $row['Password'];
  18.  
  19. $body = 'Hi,<br /><br /> The requested Account Details:<br /><br />';
  20.  
  21. $result = mail($emailid,$body,$password,$headers);
  22. mysql_close($link);
  23. }
  24. ?>
This code is working but my problem is font style of the code.
In the Output we have the different font stlye, Emailid and Password are in one style and the body in another style.I want same font style for all the above.I easily change the body font style by using the <font style=" "></font>.But i don't know how to change the EmailId and Password font style.

Please any one help to solve the problem

Thanks in Advance,
Geethu.
Feb 19 '07 #1
2 6255
ak1dnar
1,584 Expert 1GB
Hi I think you need to send HTML email apart from PLAIN Text.
To send html formatted email via php mail() function you have to
put these headers with the other headers. this is not for PHP mail() actually,
this for your email client with out these headers your mail client
cant understand the html format . Try it and format the mail body as u wish by using html tags.

[php]
$headers .= 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
[/php]

:) get back for any doubts.
Feb 19 '07 #2
Hi I think you need to send HTML email apart from PLAIN Text.
To send html formatted email via php mail() function you have to
put these headers with the other headers. this is not for PHP mail() actually,
this for your email client with out these headers your mail client
cant understand the html format . Try it and format the mail body as u wish by using html tags.

[php]
$headers .= 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
[/php]

:) get back for any doubts.

ok thank you for ur kind help
Feb 19 '07 #3

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

Similar topics

3
by: bigoxygen | last post by:
Hi. I have a list that is similar to this: -Evaluation +test +test -Students +test I would like to change the "-" bullet only, but I cannot. My
2
by: RWD | last post by:
I am trying to figure out how to change the target frame in my hyperlink on a DHTML menu. The menu is in one frame and the target frame is called "main" The code is below: Thanks in advance...
2
by: Pete Kipe | last post by:
I'm not a JavaScript programmer...but I'm trying to put together a simple menu system for a new website and need a little help. I have the following script: <SCRIPT language=javascript> <!--...
0
by: Annick | last post by:
I would like to change the format of a cell depended on the value of the data. I wrote the following script, which works fine. .. . . Function function_ChangeFormat(ByVal value_01) Dim...
3
by: Jim in Arizona | last post by:
I have a gridview that's being populated from an access db query. The problem I'm having is that the date/time fields in access that are populating the gridview are showing both date and time, when...
10
by: IchBin | last post by:
I am trying to set the state of a radio button. I do not see what I am doing wrong. Sorry, I am new at this.. I need another set of eyes to look at this snip of code. I am trying to set the radio...
7
by: moondaddy | last post by:
in asp.net 2.0, i have a link buttonand want to change the forecolor in a mouse over event. how can I do this? -- moondaddy@noemail.noemail
7
by: =?Utf-8?B?QnJpYW4gQ29vaw==?= | last post by:
I want to change the font color and weight at a specific position in the text. I am not sure where or what I need to do. It will be at position 155/156 from the left on each line. Here is the...
18
by: wizdom | last post by:
Help - change text on click - text has another onclick inside with php variables ---------- I think what I'm trying to do is simple. I have a 2 buttons on a page. 1 button allows a thread of...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.