Voodoo Jai Posted March 14, 2008 Share Posted March 14, 2008 I have a db that has 2 fields area code telephone number I also have a file that uses both these fields as a unique file name. So what I would like to know is? is it correct to concat both fields and add a suufix to it to give me the file name which can then used within PHP code. area code "01224" telephone number "456456" suffix ".zip" giving a filename "01224456456.zip" I then call this file name in my page to be able to download it. Link to comment https://forums.phpfreaks.com/topic/96165-just-a-question-thats-all/ Share on other sites More sharing options...
eddierosenthal Posted March 14, 2008 Share Posted March 14, 2008 the question is whether you can count on the phone company to give you a unique phone number? if you wanted to trust to that i think it would be ok. Possibly better for you would be to control the unique file names by adding or just using a unique key you generate for yourself. inserting into a database with an autoincrement pk field would give you the unique primary key you could use for that file, and by association you could also stick the filename into the database record. also the date, and any related record info. hth Link to comment https://forums.phpfreaks.com/topic/96165-just-a-question-thats-all/#findComment-492254 Share on other sites More sharing options...
Voodoo Jai Posted March 14, 2008 Author Share Posted March 14, 2008 That great many thanks for your help Voodoo Jai PS how do I mark this as solved now Link to comment https://forums.phpfreaks.com/topic/96165-just-a-question-thats-all/#findComment-492263 Share on other sites More sharing options...
eddierosenthal Posted March 14, 2008 Share Posted March 14, 2008 apparently there is supposed to be a link for that... http://www.phpfreaks.com/forums/index.php/topic,118755.0.html in case you don't find a link, just send a check Link to comment https://forums.phpfreaks.com/topic/96165-just-a-question-thats-all/#findComment-492359 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.