doutuo4285 2017-11-10 17:23
浏览 61
已采纳

重定向到类似于获取网址的网址[已关闭]

I am designing a website similar to Facebook, Instagram... Which have a profile page for each user. My question is: If a user wants to view the profile of another one, is this technique usable? (the user id here will be for example 123)

http://localhost/viewprofile.php?user_id=123

Then I will get the user_id from $_GET and retrieve the user information from the database and display them.

  • 写回答

1条回答 默认 最新

  • douqiaotong8682 2017-11-10 17:26
    关注

    Yes it is a good technique, user gets the profile using the GET parameter, otherwise you can use POST but since there is no delicate information so this approach as you mentioned is fine.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?