Solved

send Invoice in mail

Posted on 2016-11-17
4
56 Views
Last Modified: 2016-11-22
when we done the payment a automatically invoice send with message payment done or not. same like ecommerce site when payment done or not,  user get 2 mails one from payment getaway and other from site. i need same.


invoice sql

CREATE TABLE `invoice` (
  `invoice_id` int(11) NOT NULL,
  `employer_id` int(11) NOT NULL,
  `item_name` varchar(255) NOT NULL,
  `item_uid` int(11) NOT NULL,
  `item_quantity` int(11) NOT NULL,
  `item_price` int(11) NOT NULL,
  `order_id` int(11) NOT NULL,
  `status` enum('Success','Aborted','Failure','Pending') NOT NULL,
  `created_date` datetime NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Indexes for dumped tables
--

--
-- Indexes for table `invoice`
--
ALTER TABLE `invoice`
  ADD PRIMARY KEY (`invoice_id`);

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `invoice`
--
ALTER TABLE `invoice`
  MODIFY `invoice_id` int(11) NOT NULL AUTO_INCREMENT;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;

Open in new window


invoice Html

<table style="margin: 0 auto; width:50%; border: 1px solid #ccc;">
      <tbody>
		<tr>
			<td style="text-align:center; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%; font-size:20px;" colspan="3"><b>Test Pvt Ltd</b></td>
		</tr>
		<tr>
			<td style="text-align:center; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;" colspan="3">D-14/1 & 14/2</td>
		</tr>
		<tr>
			<td style="text-align:center; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;" colspan="3">New Delhi</td>
		</tr>
		<tr>
			<td style="text-align:right; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;" colspan="3">46055200 / 46055300</td>
		</tr>
		<tr>
			<td colspan="3" style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;">Email: test@gmail.com</td>
		</tr>
		<tr>
			<td style="text-align:center; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;" colspan="3"><b>Invoice</b></td>
		</tr>
		<tr>
			
					<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 50%;" colspan="2">Invoice # SCPL/2016-17/</td>
					<td style="text-align:right; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 50%;"colspan="2" >8/22/2016</td>
			
		</tr>
		<tr>
			<td colspan="3" style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;">Name of Buyer</td>
		</tr>
		<tr>
			<td colspan="3" style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;">Address of Buyer</td>
		</tr>
		<tr>
			<td  colspan="3"style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 100%;">Kind Attn : </td>
		</tr>
       
		<tr>
			
					<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">S. No.</td>
					<td style="text-align:center; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 60%;" >PARTICULARS</td>
					<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">Amount (in Rs.)</td>
			
		</tr>
		$i = 1;
         while($fetc = mysql_fetch_array()){
			<tr>
			
					<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">$i;</td>
					<td style="text-align:center; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 60%;" >$fetc["item_name"]</td>
					<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;text-align:right;">$fetc["item_price"]</td>
			
			</tr>
			$i++;
		 }
		<tr>
			
					<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">2</td>
					<td style="text-align:right; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 60%;" >Sub Total</td>
					<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;text-align:right;">5,200.00</td>
			
		</tr>
		
         
          <tr>
			<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">3</td>
            <td style="text-align:right; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 60%;">Service Tax @ 14 % .</td>
            <td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;text-align:right;">00.00</td>
          </tr>
		  <tr>
			<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">4</td>
            <td style="text-align:right; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 60%;">Swach Bharat Cess @ 0.5 %</td>
            <td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;text-align:right;">00.00</td>
          </tr>
		  <tr>
			<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">5</td>
            <td style="text-align:right; border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 60%;">Krishi Kalyan Cess @ 0.5%</td>
            <td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;text-align:right;">00.00</td>
          </tr>
		  <tr>
			<td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;">6</td>
            <td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 60%;">Total</td>
            <td style="border: 1px solid #ccc; line-height: 22px; padding: 2px; width: 20%;text-align:right;">200.00</td>
          </tr>
		</tbody>
		
      </table>

Open in new window

0
Comment
Question by:Amita Singh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 110

Expert Comment

by:Ray Paseur
ID: 41891410
I see you are not accepting suggestions for Gigs, but when the question is "I need" the E-E Gigs is really a good place to go.  If you have written some code and you're stuck on something we can answer questions about that sort of thing, but we cannot write your applications for free, sorry.
0
 
LVL 2

Author Comment

by:Amita Singh
ID: 41891638
@Ray,
Thank u for reply
I don't say you develop code and give me. maybe i not explain my question very well. and
i need
 does not mean i order you to solve my problem. i stuck somewhere thats why i post my question.
Thank You
0
 
LVL 2

Accepted Solution

by:
Amita Singh earned 0 total points
ID: 41892630
i get the solution. i found my code error.
0
 
LVL 2

Author Closing Comment

by:Amita Singh
ID: 41897240
Thanx
0

Featured Post

Business Impact of IT Communications

What are the business impacts of how well businesses communicate during an IT incident? Targeting, speed, and transparency all matter. Find out more in this infographic.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to write a Context Sensitive Help (an online help that is obtained from a specific point in state of software to provide help with that state) ,  first we need to make the file that contains all topics, which are given exclusive IDs. …
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
In this tutorial viewers will learn how to embed Flash content in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <object> tag to embed Flash content.: To specify that the object is Flash content, d…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question