so I could format the text much faster and easier without using of the HTML code.
Well, I wouldn't agree, 'cause I think that if you're typing the text, you might as well type the tags, too. I think it's faster than moving your hands away from the keyboard, go to the mouse, move the pointer to the bold button, and then type the text you want bolded.
But anyway, the bold, italics, etc, buttons work with JavaScript, not PHP, so just check the JavaScript source code.
Diego