Gamma-ray bursts (GRBs) are the brightest electromagnetic explosions in the Universe. Current observations show that their redshifts are in the range of 0.1-6.3. Gamma-ray photons with energy from tens of keV to MeV, if produced at high redshifts, suffer from no extinction before they are detected. These properties would make GRBs become an attractive probe of the universe. Recently, measuring cosmology with GRBs has been studied widely since several intrinsic standard candle-like correlations were proposed. In this paper, we discuss these correlations simply and review constraints on cosmological parameters with GRBs. In particular, we discuss the constraints in several dark energy models by combining GRBs with supernovae Ia (SNe Ia). We see that the cosmological constraints obtained only with GRBs are larger than those obtained with SNe Ia for a Friedmann-Robertson-Walker cosmology with mass density ΩM and vacuum energy density ΩΛ. Two reasons for this result are the current small sample of bursts and the lack of low-redshift events that are needed to calibrate the correlations. However, a combination of two types of explosion makes the constraints smaller. So, GRBs are complementary to other cosmological probes such as SNe Ia.