Answer the question
In order to leave comments, you need to log in
What is the best way to deal with data storage?
I need to make a profile of a person, which will indicate the areas of activity. These areas of activity a person chooses from the list himself. That is, there is a table of data on directions.
If I use the VK API to get the user ID, full name and picture, do I need to store them in my database so that this user can use the service?
The question is that I do not want to store a person's personal data in my database, but I doubt that the system will work.
Situation
Many people have started using the service. Will they be able to find each other through a site search if the data received through the VK API is not stored on the site?
If you use the usual registration and authorization system using a database, then the question is excluded, since all IDs and other key fields will be stored in my database, and I can easily set up links and so on. But if you do everything through the VK API, will you need to store data or how will it work?
Relatively speaking, through VK, authorization on the site is going on: will a person be able to maintain his profile (choose directions), will others be able to search for him (subject to a search being made).
Answer the question
In order to leave comments, you need to log in
If I use the VK API to get the user ID, full name and picture, do I need to store them in my database so that this user can use the service?No. Keep only the ID. To display user data, request a picture and full name dynamically from the interface, directly from the visitor's browser.
Will they be able to find each other through a site search if the data received through the VK API is not stored on the site?Depending on what signs to look for. According to the "areas of activity" - they can. They will receive a set of VK id, display their avatars, full name and links to profiles.
id, id-vk, id_naprav
(or you can get by with two columns, without a simple id, declaring the primary index to be two-column). id_naprav
one is from the list. Collected id_vk
that meet the criteria. Sent to the interface. They asked for avatars and full names from VK for these id, showed.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question