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

  • Home
  • SEARCH
  • 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 8410723
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T00:15:11+00:00 2026-06-10T00:15:11+00:00

I am following a tutorial http://css-tricks.com/sending-nice-html-email-with-php/ to send mail in html format. My string

  • 0

I am following a tutorial http://css-tricks.com/sending-nice-html-email-with-php/ to send mail in html format.

My string looks like

$message = '<html><body>';
$message .= '<img src="http://css-tricks.com/examples/WebsiteChangeRequestForm/images/wcrf-header.png" alt="Website Change Request" />';
$message .= '<table rules="all" style="border-color: #666;" cellpadding="10">';
$message .= "<tr style='background: #eee;'><td><strong>Dear:</strong> </td><td>" . strip_tags($part_name). "</td></tr>";
$message .= "<tr><td><strong>.$user_name.has fixed an appointment with you on  :</strong> </td><td>" . strip_tags($time). "</td></tr>";
$message .= "<tr><td><strong>In:</strong> </td><td>" .  strip_tags($meeting_name) . "</td></tr>";
$message .= "<tr><td><strong>Please click on:</strong> </td><td><a href=" . strip_tags($approve_url). "</a> To approve</td></tr>";
$message .= "</table>";
$message .= "</body></html>";

//   CHANGE THE BELOW VARIABLES TO YOUR NEEDS

$subject = 'Appointment Request ';

$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html; charset=ISO-8859-1\r\n";

But the received mail is not html formatted it is looking like

<html>
    <body>
        <img src="http://css-tricks.com/examples/WebsiteChangeRequestForm/images/wcrf-header.png" alt="Website Change Request" />
        <table rules="all" style="border-color: #666;" cellpadding="10">
            <tr style='background: #eee;'>
                <td>
                    <strong>Dear:</strong> 
                </td>
                <td>Depu</td>
            </tr>
            <tr>
                <td>
                    <strong>.pandit.has fixed an appointment with you on  :</strong> 
                </td>
                <td>
                </td>
            </tr>
            <tr>
                <td>
                    <strong>In:</strong>
                </td>
                <td>anyp</td>
            </tr>
            <tr>
                <td>
                    <strong>Please click on:</strong>
                </td>
                <td>
                    <a href=http://192.168.0.178/UI/user/approvemeeting.php?meetingid=REG_939300945&key=3107</a> To approve
                </td>
            </tr>
        </table>
    </body>
</html>

Please tell me what i am doing wrong why the mail is not coming html formatted

  • 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-06-10T00:15:12+00:00Added an answer on June 10, 2026 at 12:15 am

    Use PHPMailer instead.

    It allows you to send SMTP and normal emails (PHP’s mail() function or expliciting all the SMTP params), and most important it lets you sepecify HTML message, plain text alternative message (but don’t specify it otherwise some clients won’t display the HTML one, such as bloody Lotus Notes).

    It allows you to specify headers, mime, etc…

    http://phpmailer.worxware.com/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm following this tutorial on creating buttons with CSS. http://www.secondpicture.com/tutorials/web_design/css_ul_li_horizontal_css_menu.html The background for the
I'm following this tutorial and am trying to modify it to my use: http://net.tutsplus.com/tutorials/html-css-techniques/how-to-build-a-kick-butt-css3-mega-drop-down-menu/
I was following a dropdown menu tutorial: http://net.tutsplus.com/tutorials/html-css-techniques/how-to-create-a-drop-down-nav-menu-with-html5-css3-and-jquery/?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed:%20nettuts%20(NETTUTS)&utm_content=Netvibes What I really want to do
I'm using the following tutorial http://developer.android.com/resources/tutorials/views/hello-mapview.html in order to create a map view and
I was following this tutorial: http://www.vogella.com/articles/AndroidLocationAPI/article.html --> Paragraph 6.0 Problem: My emulator runs perfectly
I'm following this tutorial: http://developer.android.com/training/basics/firstapp/running-app.html#Emulator In it there is a simple code for a
I'm following this tutorial http://www.vogella.com/articles/AndroidIntent/article.html for having some data transfered to parent activity by
I am using following tutorial: http://framework.zend.com/manual/en/learning.quickstart.create-model.html When I try to insert record in database
I am following the following tutorial ( http://www.highoncoding.com/Articles/642_Creating_a_Stock_Widget_in_ASP_NET_MVC_Application.aspx ) on using ajax to render
I am doing the following tutorial http://msdn.microsoft.com/en-us/library/ms731835%28v=vs.100%29.aspx and the program is working perfectly fine.

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.