Convert String to HTML Format

Hi Techie,

I am working on a process, trying to read PDF data and sending the same in email, but when I am sending this data, everything has disintegrated.

It’s because I’m sending HTML data in an email.

Solution: I think I need to convert this to HTML format. Is there any other and better approach?

If this is
Email Contetnt.txt (3.5 KB)

Hi @JSR_Techno_Talk_s

Can you please try using the following HTML content for the same?

<!DOCTYPE html>
<html>
<head>
   <style>
      table.GeneratedTable {
         width: 100%;
         background-color: #ffffff;
         border-collapse: collapse;
         border-width: 2px;
         border-color: #0b0b0a;
         border-style: solid;
         color: #000000;
      }

      table.GeneratedTable td,
      table.GeneratedTable th {
         border-width: 2px;
         border-color: #0b0b0a;
         border-style: solid;
         padding: 3px;
      }

      table.GeneratedTable thead {
         background-color: #3dd6cc;
      }
   </style>
</head>
<body>
   <h4>Hi JYOTI THAKUR,</h4>
   <p>Thanks For using our Travel buddy BOT</p>
   <p>We are Sending you the <b>Goa</b> Trip Itinerary For the Date <b>Jun 14 2023</b>.</p>
   <p><b>You are traveling By Flight - Happy journey</b></p>
   <p><h3>Flight Details:</h3></p>
   <table class='GeneratedTable'>
      <thead>
         <tr>
            <th>Flight Name</th>
            <th>Price</th>
            <th>Date</th>
         </tr>
      </thead>
      <tbody>
         <tr>
            <td>IndiGo</td>
            <td>₹ 4,662</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>IndiGo</td>
            <td>₹ 4,662</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>AirAsia</td>
            <td>₹ 4,720</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>IndiGo</td>
            <td>₹ 4,897</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>AirAsia</td>
            <td>₹ 4,959</td>
            <td>Jun 14 2023</td>
         </tr>
      </tbody>
   </table>
   <p><h3>Hotel Details:</h3></p>
   <table class='GeneratedTable'>
      <thead>
         <tr>
            <th>Hotel Name</th>
            <th>Booking Price</th>
            <th>Date</th>
         </tr>
      </thead>
      <tbody>
         <tr>
            <td>The Shalimar Hotel</td>
            <td>₹ 5,676</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>Hotel Manama</td>
            <td>₹ 3,066</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>Hotel Planet Residency</td>
            <td>₹ 3,120</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>The Paradise by Tunga</td>
            <td>₹ 5,492</td>
            <td>Jun 14 2023</td>
         </tr>
         <tr>
            <td>Niranta Transit Hotel at Arrivals</td>
            <td>₹ 5,748</td>
            <td>Jun 14 2023</td>
         </tr>
      </tbody>
   </table>
   <p>
      Day 1
      <br>
      Start your day with a visit to the Basilica of Bom Jesus, a UNESCO World Heritage Site. Explore the church and its beautiful architecture.
      <br>
      Next, head to the Dona Paula View Point, a popular tourist spot in Goa. Enjoy the stunning views of the Arabian Sea and the Mormugao Harbour.
      <br>
      Afterwards, take a stroll along the Baga Beach. Enjoy the sun, sand, and the sea.
      <br>
      In the evening, visit the Anjuna Flea Market. Shop for souvenirs and enjoy the vibrant atmosphere.
      <br>
      End your day with a delicious dinner at one of the many restaurants in the area.
      <br>
      Thanks For using our BOT 1/25/21/23, 9:33 PM Form
      <br>
      Day 2
      <br>
      Start your day with a visit to the Aguada Fort. Explore the fort and its history.
      <br>
      Next, head to the Dudhsagar Falls. Enjoy the stunning views of the waterfall and the surrounding nature.
      <br>
      Afterwards, take a boat ride on the Mandovi River. Enjoy the views of the river and the surrounding nature.
      <br>
      In the evening, visit the Arpora Night Market. Shop for souvenirs and enjoy the vibrant atmosphere.
      <br>
      End your day with a delicious dinner at one of the many restaurants in the area.
      <br>
      Day 3
      <br>
      Start your day with a visit to the Shanta Durga Temple. Explore the temple and its beautiful architecture.
      <br>
      Next, head to the Colva Beach. Enjoy the sun, sand, and the sea.
      <br>
      Afterwards, take a stroll along the Calangute Beach. Enjoy the stunning views of the Arabian Sea.
      <br>
      In the evening, visit the Saturday Night Market. Shop for souvenirs and enjoy the vibrant atmosphere.
      <br>
      End your day with a delicious dinner at one of the many restaurants in the area.
      <br>
      Thanks For using our BOT 2/2
   </p>
</body>
</html>

Hope this helps,
Best Regards.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.