0

I am creating a website, now it's time to decide how the URL for different posts should look like.

For SEO purposes, I am planing to add the post URL, like

example.com/post.php?v=a-very-interesting-title

To prevent URL crashing, I was thinking to add the post ID to the URL, like

example.com/post.php?v=a-very-interesting-title-32

What do you think about adding the post ID to the URL, any security concerns? Should I hash the ID before adding to the URL? How should I do that?

unor
  • 92,415
  • 26
  • 211
  • 360
pabloBar
  • 177
  • 2
  • 12
  • What is "url crashing" ? –  Dec 29 '16 at 07:42
  • assume i want to add another post which happens to have the same title as another old post – pabloBar Dec 29 '16 at 08:43
  • 1. What kind of posts are these? Do they have a publication date? 2. Is there a reason why you use the query component instead of the (typically more human-friendly) path component (e.g., `example.com/posts/title`)? 3. Why do you think having the ID in the URL could be problematic for security? How do you use the ID? – unor Dec 30 '16 at 00:18
  • @unor 1-let say each post represents an sport event, like team A vs Team B, and no, there isnt any publication date but rather a start time for the event. 2- no, not sure how to make the url follow the structure you provided. 3- i dont think id is bad for security, just curious if its possible to be used in any malicious way – pabloBar Dec 31 '16 at 02:10

0 Answers0