1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

going crazy - PHP to PDF?

Discussion in 'PHP' started by Phoenix CG, Apr 10, 2012.

  1. #1
    I'm trying to send some code to print as avery labels using PDF, it's proving to be a nightmare. could anyone give me a hand, i've tried everything, making it into a function and using fpdf to print the function, didn't work...i'm going mad, 48hours working on the same problem (i am new to php, just my first week).
    <div class="label" style="background-image:url(<?php echo $user_background;?>); background-size:100%;">
    <header id="header">
      <div class="header-stuff">
    		  <a href="<?php echo $home; ?>">
    			  <img width="150" border="0" alt="<?php echo $sitename; ?>" src="account/img/logo.png">
    		  <span class="user-name" style="margin-left:50px; margin-top:-1px;"><?php echo  $user; ?></span>
    <!-- qr code -->
    <div align="center" style="width:120px; height:120px; background-color:#fff; margin-left:10pt; margin-top:30pt;">
    <table height="100%"><tr><td valign="middle">
    <?php			echo '<img src="http://www.avatar.es/'.$user.'" alt="QR code" widhtHeight="100" />';
    <!-- footer -->
    <div style="width:100%; background-color:#0B0B0B; bottom:0; margin-top:31px;" align="right">
    		  <span class="user-name" style="font-size:30px; margin-right:10px;"><?php echo  $name; ?></span>
    i'm going meeeeeeeental. please help.
    Phoenix CG, Apr 10, 2012 IP
  2. Phoenix CG

    Phoenix CG Member

    Likes Received:
    Best Answers:
    Trophy Points:
    ok so mpdf is now loading a pdf but it's not loading any of the php variables...
    Phoenix CG, Apr 10, 2012 IP
  3. stephan2307

    stephan2307 Active Member

    Likes Received:
    Best Answers:
    Trophy Points:
    can you post the rest of php code so we can see where you are trying to load the variables etc?
    stephan2307, Apr 11, 2012 IP