I\'m trying to draw 2 squares side by side of different colours, my problem is I can\'t get glTranslatef to move my second square to the right, the second square just draws over
You cannot translate inside a glBegin/glEnd block, you have break it up into two blocks.
glBegin/glEnd
I recommend to start using glGetError() in your code, it will help you find mistakes like this.
glGetError()