How to use and access web sharing with Mac OS X Lion? I am new to Mac OS X, and I have a MacBook Pro. I am developing a web application with PHP and MySQL. I already installed XAMPP on my Mac. I discovered the option for hosting in System Preferences > Sharing > Web Sharing, but I don't know how to use it or how to tell my friend to view my web application remotely. Can someone help me?
Web Sharing opens port 80 (http) on your machine and points any incoming requests to ~/Sites. You'll want to put your PHP app there for it to work through Web Sharing. I'm not sure if there is any further configuration you have to do on the PHP/MySQL side since I don't know anything about either of those languages. That's probably a question for SuperUser.

As far as accessing it remotely, you'll need to open port 80 on your router and point it to your computer's internal IP address. Then you'll want to give your friend either your domain name or your current IP address from your ISP and have them type it in their web browser.