Results 1 to 4 of 4
  1. #1
    Join Date
    Oct 2008

    Post Unanswered: User Profile Storage


    I've been programming in C++ and Java for some time, so I have limited experience in MySQL, but there are some design issues I'm not sure of.

    Right now, I'm working on an advertisement mapping program. Basically, I need to make SQL tables to manage information for advertisers, users, and the ads themselves. I've got the general structure worked out, but there are three trouble points.

    First, I'm not sure what the best way is to store advertisement descriptions. I expect that some descriptions will be one sentence, and others will be four or five. Should the description itself have a field in the SQL table, or should it instead contain a link to a .txt file where the description will be stored (I assume this is how you do images).

    Second, I have no idea how to really make the tables secure. Can anyone point me to some good articles?

    Finally, I can't find any good examples of how to take user sign up information. For example, when I signed up for this forum, I entered, name, address, and number. However, my service should be available to other countries. How do I make it so that I can accept international numbers and addresses? Are there any good examples or articles on international SQL table planning?

    Thanks so much for your help. Looking forward to becoming part of the forums.


  2. #2
    Join Date
    Oct 2008
    1) No external .txt file. Use one of the 4 text types in mysql: TINYTEXT, TEXT, MEDIUMTEXT, or LONGTEXT. Which one you should use depends on how long you expect the advertisement descriptions would be. Take TINYTEXT if you expect descriptions with a maximum of 255 characters, take TEXT for descriptions with a maximum of 65535 characters. Take also a look at the storage requirements:

    2) What do you mean with "secure" tables? Do you mean the access to your table, then google for "mysql privileges" - you will find enough to read. Or do you mean that the data in your table should be verified before inserted (and in that way it is somehow "secure")? If that's the case you should google for "mysql triggers" or take a look in the mysql manual.

    van de Roobje

  3. #3
    Join Date
    Oct 2008
    Thanks, Van. That information is quite helpful. All that's left is to figure out how to handle the user signup forms. Any suggestions?

  4. #4
    Join Date
    Jun 2007
    I just did a search in Google for "php user registration form" and it came up with sites like these or I haven't looked through them but they seemed to be going along the right lines.

    Assuming your OK with PHP you just need to present a form where users can put in their details i.e. name and email. At this point you would often have an image containing text that the user needs to type in - this tends to stop robots from setting up 1000's of accounts. Normally you would then email them a random password. Then they login with this password and change it to a password of their choice.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts