The form action needs to specify what page will process the form.
In your case, it needs to specify what page will take the form data, parse it, make sure it's safe, connect to the database and insert it. This is all server side work, and needs to be coded in a server side language.
Since you don't want the the form to call another page, you can just leave the "action" tag in the HTML form blank. The page will then call itself. This requires that the page contains the necessary code to take the form data, parse it, make sure it's safe, connect to the database and insert it.
As you're posting this in a PHP forum, I guess you're hoping to develop the server side code in PHP which is perfectly sound thinking.
Does that help answer your question? If it doesn't, I'm afraid you may need to re-evaluate your understanding of "the method".