Your existing program is close. Can you see the pattern with the number of spaces as compared to the number of stars? Your looping conditions are your problem.
Edit: Also you can put [output] before your christmas tree and then [/output] after to make it keep the leading spaces, otherwise the forum removes the leading spaces. Similarly, you can use [code][/code] around your code to syntax highlight it:
I fixed your program's formatting (I noticed you used pre-increment, you're automatically awesome!) and ran it myself: http://ideone.com/4JC5f7
The problem is the loop condition for your spaces. It is the same as your loop condition for your stars, meaning 1 star = 1 space. You need to use a tweak to make the space loop run more times at the beginning of the outer loop and less times at the end: http://ideone.com/5XgHaZ