Stanley Yelnats IV (Shia LaBeouf) is a hard-luck kid who always seems to be at the wrong place at the wrong time. Walking beneath an overpass, he is hit in the head by a pair of sneakers. Not just any sneakers, mind you; they happen to belong to a famous baseball player and were stolen from an auction raising funds for a homeless shelter.

Stanley's father (Henry Winkler) isn't much help since he is spending every moment of his life trying to find a cure for foot odors. Stanley's grandfather (Nathan Davis) is convinced that the boy's bad luck is the fault of his "no-good-rotten-pig-stealing-great-great-grandfather." (Back in Latvia during the eighteenth century, this handsome young man fell in love with a beautiful maiden but could not get her father to agree to let him marry her. He consulted Madame Zeroni [Eartha Kitt], a gypsy, who gave him a solution to his problem, but when he disregarded her orders, she put a curse on him and his family.)

Stanley's bad luck continues when a judge gives him a choice between prison or 18 months at a place called Camp Green Lake. He eagerly chooses the latter only to find out that it is a juvenile detention center in the Texas desert. Upon his arrival, he is told by Mr. Sir (Jon Voight) that each day he will be getting up before dawn to dig a hole in the desert that's five feet in every direction. This rigorous hard labor in the relentless sun is supposed to build his character.

Mr. Sir adds that the camp has no fences since they have the only water within a hundred miles. Stanley is warned to watch out for yellow-spotted lizards, whose bite results in a slow and painful death. The camp counselor, Dr. Pedanski (Tim Blake Nelson), tells him that only one person is responsible for his present situation, and that is Stanley Yelnats IV.

On the first day, the newcomer gets very thirsty, and by evening, his hands are covered with blisters. Stanley finds that X-Ray (Brenden Jefferson), the leader among the inmates, has singled him out for harassment. He's given the nickname "Caveman" after he discovers a fossil, although no one is very interested in it. His bad luck takes a swerve once he makes friends with Zero (Khleo Thomas), the runt at Camp Green Lake. Turns out that Zero is the fastest digger of holes even though he is the smallest in size. No one is able to get him to speak until Stanley does.

When Stanley digs up a gold-colored tube with the initials KB on it, the warden (Sigourney Weaver) is immensely impressed and orders the boys to begin an intensive dig in the area. (KB stands for Kate Barlow [Patricia Arquette], the Texas schoolteacher who turned outlaw after the murder of her forbidden lover, an African American onion seller [Dule Hill]; KB was known to have buried the loot from a series of robberies in the Green Lake area.)

Holes, as you might have guessed by now, is an outrageously inventive movie based on the 1999 Newbery Award-winning book of the same title by Louis Sachar. In a recent poll by Read magazine of the most popular books among children, Holes ranked #1 — beating even Harry Potter and the Sorcerer's Stone. The melding of three different stories from eighteenth-century Latvia, the Old West, and contemporary Camp Green Lake is pulled off with aplomb by director Andrew Davis, whose magical realism in his unheralded Steal Big, Steal Little proved to be fine practice for this film. Sachar's clever screenplay conveys the oddball wit of the story where Stanley's first and last names are the same spelled forward and backward, where the warden's nail polish is laced with poisonous rattlesnake venom, and where onions and peaches combined create a magic potion.

Stanley starts out thinking that he is cursed and winds up realizing that he's actually blessed. His journey is filled with coincidences and hints of grace that shower upon him at a place called God's Thumb. In the rollicking finale, Stanley and Zero share an adventure that reveals their destiny. Holes is a hoot from start to finish, one of the most deliciously imaginative children's films to hit the screen in many a moon.