well, assuming (and I do) that you are not storing the entire pdf file in the database, why not just store the name of the document in a table, and set a sitewide variable that holds the pdf document location? Then you can query the table, and looping through the result, print (example code, not real) <a href="$sitewide_var_path_to_pdf_file/$loop_name_from_query">$loop_name_from_query