Where to write stored procedure in mysql

Where do I need to write stored procedure in mysql? Do I need to write them in a php file or in some other interface?

stored procedures are defined right in mysql, the same way that tables are defined right in mysql

so i have to write and storte procedures in phpmyadmin itself? if so where in phpmyadmin?how can i access the already created stored procedures in phpmyadmin. pls explain in details as I dont have much idea

no

phpmyadmin is a front-end tool for mysql (and, in my opinion, not a very good one)

when you use a “point-and-click” interface, it’s actually just building SQL queries underneath

and while there is a “friendly” way to create a table by filling in form fields in phpmyadmin, you can always create a table using ordinary SQL, the CREATE TABLE statement, and execute it in the SQL window that phpmyadmin provides

my advice is to learn the SQL so that you are not limited by what the front-end interface can do, but rather, you can do everything yourself

read the manual on the CREATE PROCEDURE statement