Grant Holmes Posted February 27, 2008 Share Posted February 27, 2008 I have created a four field table: id [int(4) auto_increment] code [char(2)] country [varchar(50)] flag [blob] On my PC,I have: a CSV file with 252 two-digit country codes (US) and country names (United States) A folder with 252 png common-sized flag images (the flag names correspond to the country codes) I want to populate my table with this information, so I can later compare a user country and display their flag next to their name. I've searched the general web and this forum for a simple upload script, but everything seems to be based on forms and user uploads, resizing, blah, blah, blah. I just need to populate this table with this information, and obviously keep the flags in the right record. Is there a way to write a script to parse a local folder for the data, or if I created a folder on the site, would that be easier. Two important points: 1-I know next to nothing about writing PHP, but I can edit the heck out of it!! 2-My client is on Yahoo, so there are some dumb PHP restrictions and I'm stuck with that for the moment. As always your kind help is appreciated. Quote Link to comment Share on other sites More sharing options...
Grant Holmes Posted February 27, 2008 Author Share Posted February 27, 2008 just found a tutorial that surrounds this issue without really answering it. It says it may be better to just store images in the site folder structure. Then in the table, just store the server path (flagimages/xxx.jpg) for each record. In my case all the flag images are 32x20 px and 1k in size, so space is not really an issue, is it? Quote Link to comment Share on other sites More sharing options...
Grant Holmes Posted February 27, 2008 Author Share Posted February 27, 2008 Last ping. No help? Even a "you're asking too much" would be nice at this point. 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.