Ver Mensaje Individual
  #5 (permalink)  
Antiguo 28/08/2013, 11:32
xabihost
 
Fecha de Ingreso: agosto-2013
Mensajes: 18
Antigüedad: 10 años, 8 meses
Puntos: 1
Respuesta: Realizacion de un PDF EN PHP

Puedes hacer en vez de un pdf, un rtf, le metes una plantilla que diga por ejemplo %NOMBRE% y luego guardas.

Código:
$nombre = 'PEPITO';
$rtf_temp = file_get_contents('Archivo_de_plantilla.rtf'); // Cargas la plantilla
// Haces un STR REMPLACE
$FINAL = str_replace('%NOMBRE%', $nombre, $rtf_temp);
file_put_contents('archivofinal.rtf', $FINAL);
Y luego ya, cuando tienes el rtf lo combiertes en pdf con la siguiente api:
http://www.convertapi.com/richtext-pdf-api

suerte.