Web graphics in general are fixed in pixel dimensions. As such, completely ignore the DPI setting.
If you are asked to provide a 600px wide banner, simply make your image 600px wide. (the exception is if you also need to support high density screens. For example, an iPhone 5 may also require a 1200px wide version of that same graphic).
How to compress graphics is a broad topic, but, in general:
- if it's flat art, GIF or PNG are typically better
- if it's photographic in nature, JPG is better
You can shrink GIFs further by reducing the color pallet. You can shrink PNGs further by using various PNG compression tools (one common one is ImageOptim). You can reduce JPGs file sizes by changing the amount of JPG compression.
Beyond that, you need to show us the image for us to make specific suggestions.