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

 

Link to comment
Share on other sites

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

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.