Custom post ID & display information related to this ID

I’m new to WordPress and I want users to be able to retrieve a post by its ID.

For that I will be using a form in the homepage asking an ID and submitting the form will redirect user to the post’s URL.

I see that as 2 steps:

  1. use dynamic permalinks
  2. display post information based on the ID (I am using CPT UI and ACF)

For step 1, I went to wp-admin/options-permalink and set it to "simple > http://.com/?p=123". Hopefully it’s the good way, correct?

For step 2, how can I retrieve the ID from the URL and display the informations related to a particular post?

  • should I edit a particular page like posts.php?
  • how to edit this page? FTP or add-on?
  • is there a way to do such thing from the UI directly?