title: Using PHP post and get with a form to the same page
body: <p>I am making a PHP application, testing out Object Orientation with it as I am trying to learn OO as opposed to procedural programming. </p>
  
  <p>Basically I have a list of courses the user can book using the system, and they appear in the users profile. From the profile I want a "remove" link next to each booked course which when clicked, removes the course.</p>
  
  <p>Will I have to use a html form for this? I have started doing it but it doesnt seem right. I have a function called "delete_course" which does the stuff I want it to do, and all I need to pass over is the ID of the post in the DB. So... my question is... would it be best practice to post over the ID in a form to a page with the function call?</p>
  
  <p>And if this is the best way, is it best to post it to the SAME (current) page the user is on, or post to another page, say, "cancel_course.php"??? What are the benefits?</p>
  
  <p>Thanks</p>
  
  <p>Oh and btw, I am relatively new to PHP but have done plenty of JS so I know ajax is a better option, just trying to learn PHP :)</p>