Shrek is probably one of the most successful animated motion picture series. Each of the movies are supported by stellar cast and none of them is replaced since the original movie. The formula works because Shrek incorporates many fairy-tale characters that are dear to us, young and old. Compare to Walt Disney Pictures, where sequels of the animated movies are generally not shown on movie theatres. Do you know that Disney actually has sequels for The Lion King, Lilo & Stitch, to mention a few here?
Someone actually wrote in to the newspaper forum section to complain about the adult content of Shrek, and how they portray the bad side of the fairy-tale characters. All I can say is that Shrek is a movie for grown-ups. Even Spider-Man 3 is not a kids movie. I'd say only 10% of the screen time is catered for kids - mostly on the action and the silly comedic scenes. The rest, is revenge, hatred, evil, romance.