smarchand291 Posted September 6, 2011 Share Posted September 6, 2011 Hi everyone, I'm building a website for a music band and want to automate the adding of new album/disc so they wont have to update a php file to print out . I mean, a new album is release , then dump the mp3's, lyrics, cover pics in their respective directory using naming convention so my php read the directory structure and so one... but my problem is the php function opendir read the filesystem... is there a more secure way to do this ? and I presume the web host wont let me do this... thanks for any tips and tricks steph Quote Link to comment Share on other sites More sharing options...
Psycho Posted September 6, 2011 Share Posted September 6, 2011 The web host should let you do this - it's your web space. But, you will be restricted to only accessing your areas. You might want to consider putting the storage folder outside the web accessible directory. Aside from that, I would suggest using glob() to access the files. Quote Link to comment Share on other sites More sharing options...
requinix Posted September 6, 2011 Share Posted September 6, 2011 but my problem is the php function opendir read the filesystem... is there a more secure way to do this ? and I presume the web host wont let me do this... If they block opendir() then you need to find another host. It'd be like a driver's ed. school teaching that you should never use the radio because it might distract you from the road. Kinda. Directories are fine. Do you specifically want to do that rather than, say, have the band go to some kind of "add album" webpage, fill in some details and upload some files? Quote Link to comment Share on other sites More sharing options...
smarchand291 Posted September 6, 2011 Author Share Posted September 6, 2011 the idea of a webpage to let them input information is, I would say, deja vu, but a working solution. But if the opendir or scandir or whatsoever works on my host, I would prefer. that would be neat for 250$ for the coding, put in place and domaine name, for 1 year let say it's because they are friends to me... the alternative input page is a nice one but require coding from my side thanks, it helped just reading your replies steph Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.