What's the correct way to do this? Right now I have these two functions in different php files, but I want everything in the main Wordpress plugin file.
<form action="plugin-path/plugin.php->writepost()" method="get"> or <form action="plugin-path/plugin.php->scandir() method="get">
The bad part about having these functions in different php files is that when somebody finds out the URL of the php with the writing function, with the right HTTP GET variables he can write posts on my site without authenticating at all!