⊗ppPmAuPf 427 of 447 menu

Profile Implementation in PHP

Let's now implement viewing a user profile. By profile, we mean the information that this user provided during registration.

Let's make it possible to view the profile of any of the users. To do this, we will create a page profile.php, to which we will pass the user's id as a GET parameter.

On the profile page, we will not show all the information the user provided about themselves. For example, it's definitely not worth showing the password there. Furthermore, most likely, showing the email would also be unnecessary, as in this case spammers could collect these emails with parsing programs and send spam to them.

Suppose during registration we asked the user for login, password, first name, patronymic, last name, date of birth. Display in the user's profile all this data except the password.

Modify the previous task so that instead of the date of birth, the current user's age is displayed.

Create a page users.php where any user of our site can see a list of all registered users of our site in the form of links. Each link will lead to the corresponding profile.

English
AfrikaansAzərbaycanБългарскиবাংলাБеларускаяČeštinaDanskDeutschΕλληνικάEspañolEestiSuomiFrançaisहिन्दीMagyarՀայերենIndonesiaItaliano日本語ქართულიҚазақ한국어КыргызчаLietuviųLatviešuМакедонскиMelayuမြန်မာNederlandsNorskPolskiPortuguêsRomânăРусскийසිංහලSlovenčinaSlovenščinaShqipСрпскиSrpskiSvenskaKiswahiliТоҷикӣไทยTürkmenTürkçeЎзбекOʻzbekTiếng Việt
We use cookies for website operation, analytics, and personalization. Data processing is carried out in accordance with the Privacy Policy.
accept all customize decline