문제

I have a table in MySQL. I want to create a new file in my directory, to each row will have a unique page. The only problem, is that many rows are related to the same user, (same ID). I want to make sure users will only see their pages. Any idea how can I do that?

도움이 되었습니까?

해결책

You can use .htaccess file and virtual address like:
www.site.com/128.html
htaccess code for up address is:

RewriteRule (.*)\.html$ index.php?user_id=$1 [L]

You can check user id with $_GET['user_id'] variable.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top