Jump to content

displaying multiple files with seperate topic names


friedice

Recommended Posts

hmm im having some trouble tackling this problem

 

i have a database table with topicname then 3 columns with 3 pdfs in each one

all the files are stored in a directory called topicfiles in the server

so like 3 topicnames with 3 files in each one

 

with this page i want to make

i want to display each topic name with the files under it calling it from the server

like

 

topic 1
    file1.pdf
    file2.pdf
    file3.pdf

topic 2
    file4.pdf
    file5.pdf
    file6.pdf

topic 3
    file71.pdf
    file8.pdf
    file9.pdf

 

i tried using dhandler to access all files in the folder and only managed to display all of the files in rows using foreach loop

was thinkin of using mysql query to access the topic name and then each file for that topic but not sure hmmm

 

nah not like that

i meant like the page keeps loading dynamically from the db/server each time

so it keep loading topics with files if theres any new added ones

 

like there are 2 topics now with 3 files each (6 files in directory)

uploads 2 more topics with 3 files each again

so when the page loads again

it will display 4 topics now with 3 files under each other

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.