Sure, post your code, and we'd be more than happy to help you debug it.
If you don't have any code, go to HotScripts.com and you will find plenty to choose from.
Otherwise, you may want to take a trip to your local book store to find a PHP/MySQL book. Most of them have a tutorial right in them for how to do that... (and a lot of the books out there include a CD with source code.)