i am new to OPENGL and i am trying to use the light functions. the problem is that the objects are colored by the light color not by their original color. how can i solve this… i’d like to see some examples if there are any available ones…

Obviously you did domething wrong there, lighting just modulates the object color.
See NeHe’s lessons :