We help IT Professionals succeed at work.

Form that will spit out information into a greeting card format

Medium Priority
448 Views
Last Modified: 2013-11-19
I'm wondering if there is a Form program out there that will allow the user to enter their information, pick a photo, and enter a personalized greeting and then translate it into a greeting card format.

I have attached an example of what we would like the card to look like.
eCard-Preview.pdf
Comment
Watch Question

Michel PlungjanIT Expert
CERTIFIED EXPERT
Top Expert 2009

Commented:
Not on a client only.

You will need a server process (php, asp?) that can create an html attachement
Most Valuable Expert 2011
Author of the Year 2014

Commented:
I use PHP and the FPDF class to create PDF documents.  My sense is that what you're looking for might require some custom programming, but it is not anything that would be too lengthy or involved.

I would recommend that you keep the user information in a data base so you can "remember" their history and preferences.  For this, I would recommend MySQL (probably MySQLi).  PHP, MySQLi and FPDF are all free and open source software.  Almost every web hosting provider would have these available.  Hosting costs less than a dollar a day.

Is this specifically for Heifer?
Zion PhilPresident

Author

Commented:
This is not specifically for Heifer. It's for a non-profit City Garden Project.
Most Valuable Expert 2011
Author of the Year 2014

Commented:
Not the Aberdeen project?!
Zion PhilPresident

Author

Commented:
No not the Aberdeen project. It's an 8 million dollar volunteer only funded garden project in America for the public. We are web designders and experienced IT professionals, but we do not have experience in programming PHPor MySQL or MySQLi. At best we are script kiddies. What level of experience would be needed to achieve this? Thanks.
Most Valuable Expert 2011
Author of the Year 2014
Commented:
It's an intermediate project, in my opinion.  Anyone who has a year or two of PHP programming can figure it out.  The FPDF part of things is "fiddly."  It takes a while to get everything set up and positioned in the PDF document object.  But once that is done, FPDF is lightning fast and highly dependable.  I recently used it to generate a 600-card mailing for a property I am renovating.  With a mashup from county tax records, I was able to create custom postcards for everyone in a two mile radius to announce an open house.

I think a little refinement and consolidation of thought would be useful.  For example, in the PDF attached to this EE question, I see a full 8.5x11 document.  I think an e-card would normally be smaller.  And links like "close window" are not particularly useful in a PDF.  But these are design concepts that can be refined as the work is completed.

Here is a programming example that shows the "hello world" exercise for FPDF.  Getting your e-card to look good is mostly a matter of extending this code to position cells with images and text.

<?php // RAY_fpdf_hello_world.php
error_reporting(E_ALL);


// DEMONSTRATE THE BASICS OF FPDF


// SOME VARIABLES FOR OUR TESTS (COULD COME FROM DATA BASE, ETC)
$font = 'Arial';
$text = 'Hello World!';

// BRING IN THE PDF THING
require_once('fpdf16/fpdf.php');

// SYNTHESIZE THE PDF FILE INFORMATION
$pdf_file_link
= DIRECTORY_SEPARATOR
. 'RAY_junk'
. DIRECTORY_SEPARATOR
. 'temp_pdf_blue'
. '.pdf'
;
$pdf_file_name
= getcwd()
. $pdf_file_link
;

// DO THE HELLO WORLD EXERCISE IN WHITE ON A BLUE BACKGROUND
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont($font, 'B', 16);
$pdf->SetFillColor(  0,   0, 255);
$pdf->SetTextColor(255, 255, 255);
$pdf->Cell(40, 10, $text, 0, 2, 'L', TRUE);

// WRITE THE PDF TO DISK
$pdf->Output($pdf_file_name, 'F');

// PRESENT A LINK
echo '<a target="my_PDF" href="' . $pdf_file_link . '">Blue PDF</a>';



// START OVER FOR A NEW PDF
unset($pdf);
echo PHP_EOL . "<br/>";

// SYNTHESIZE THE PDF FILE INFORMATION
$pdf_file_link
= DIRECTORY_SEPARATOR
. 'RAY_junk'
. DIRECTORY_SEPARATOR
. 'temp_pdf_red'
. '.pdf'
;
$pdf_file_name
= getcwd()
. $pdf_file_link
;

// DO THE HELLO WORLD EXERCISE IN WHITE ON A RED BACKGROUND
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont($font, 'B', 16);
$pdf->SetFillColor(255,   0,   0);
$pdf->SetTextColor(255, 255, 255);
$pdf->Cell(40, 10, $text, 0, 2, 'L', TRUE);

// WRITE THE PDF TO DISK
$pdf->Output($pdf_file_name, 'F');

// PRESENT A LINK
echo '<a target="my_PDF" href="' . $pdf_file_link . '">Red PDF</a>';

Open in new window

Documentation for FPDF is in the "manual" link on this page.
http://www.fpdf.org/

Best regards, ~Ray
Most Valuable Expert 2011
Author of the Year 2014

Commented:
Please see http://www.experts-exchange.com/help/viewHelpPage.jsp?helpPageID=26

Was there something wrong with the answer?  Why did you mark the grade down to a "B?"  What did you expect?

Explore More ContentExplore courses, solutions, and other research materials related to this topic.