need some help with dealing with pdf's

Discussion in 'PHP' started by stephan2307, Feb 9, 2011.

  1. #1
    Right so I have this script that handles some pdf's. For some reason certain pdf's crash the script (not even an error_log file is created). After loads of research and chatting with the hosting support I discovered the problem.

    The PDF that crashes has been created using Distiller and for some reason there is something different in the xref part of the file.

    So I thought that if I can create a "new" pdf file then it should be ok. So played with an online conversion tool here and it works.

    So I need now a script that basically reads in a pdf document and creates a new pdf file from it.

    Can anyone help?
     
    stephan2307, Feb 9, 2011 IP
  2. seafrontsteve

    seafrontsteve Peon

    Messages:
    451
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Not sure what you are trying to do or why you want to do it online?
    For standard (no clickable links) just use a print driver on your PC, such as Cutepdf - it's free.
    You can also use it to print from a pdf to create a new copy.
     
    seafrontsteve, Feb 9, 2011 IP
  3. stephan2307

    stephan2307 Well-Known Member

    Messages:
    1,277
    Likes Received:
    33
    Best Answers:
    7
    Trophy Points:
    150
    #3
    because it is a online software that I have written and I need to make it so that if someone uploads such a pdf file that it won't crash the system. So I want to create a new pdf file with the same content as the original one so that the system won't crash.

    Doing it manually is not an option as the software is used by many customers and they like the simplicity of it. doing manual stuff would put them off using it.
     
    stephan2307, Feb 9, 2011 IP
  4. yelbom

    yelbom Greenhorn

    Messages:
    36
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    16
    #4
    Google MPDF42
    I have been using this php script for 1 year in a user system without error
     
    yelbom, Feb 9, 2011 IP