I currently have a very simple intranet that we are using for some basic company documentation. The site has a navigation bar across the top of the page that has drop down lists containing links to all the documents.
At present, if someone needs to add a new document, I have to manually go in and create a list item with the link to that document, in order for it to be added to the drop down.
Is there is a way I can save myself a job, using a script that can auto create these list items based on the folder contents?
If there is a PHP option, this would be ideal as this is what I am most familiar with.
Using
glob()you can easily get a list of files in a directory and output them: