For all the talk that is often given in film reviews to such aspects as the direction or the performances of the actors, it is the process of casting said actors that is often even more important. A film can have a brilliant screenplay and director and a cast filled with talented actors but if they aren't the right actors for the roles--if there is never a time that they seem right or comfortable in those parts on the screen--the entire project is practically doomed from the start despite the efforts of all involved. There are many, many problems with the raunchy new comedy "Bad Teacher" but the fundamental one that sinks the entire enterprise is that it is the victim of one of the more inexplicable casting decisions to come around in recent memory, one so monumentally ill-advised that it arguably qualifies as the funniest joke (okay, second-funniest) in the entire enterprise.

The film stars Cameron Diaz as Elizabeth Halsey, a monstrously greedy and self-absorbed babe who plans on quitting her junior high teaching gig at the end of the school year in order to marry a rich dope and finally live the life she feels that she deserves. Alas, just as the school year ends, the dope wises up and dumps her and three months later, with nowhere else to turn, Elizabeth is forced to return to school and endure another year with the likes of uber-perky super-teacher Amy Squirrel (Lucy Punch), amiably shaggy gym teacher Russell Gettis (Jason Segel) and a group of kids whose obnoxious desire to learn continually gets in the way of her hangovers. Hoping to ride out the year (largely by playing educational-themed DVDS for her students ranging from "Stand & Deliver" to "Scream") while saving enough money to afford the breast-enlargement job that she is convinced will win her a new benefactor, Elizabeth is convinced that she has hit the potential mother lode when rich, handsome, idealistic and rich Scott Delacorte (Justin Timberlake) arrives to begin what is apparently the longest substitute teaching gig in the history of education. Elizabeth sets her cap, among other thing, for Scott but finds the ultra-competitive Amy competing for his affections as well, one that intensifies when Elizabeth learns that the teacher with the highest GPA on the upcoming statewide tests gets a bonus that will ensure that her cups will indeed spilleth over at last and sets about snaring that prize by any means necessary.

Even if it didn't have a strikingly similar title--which I am sure is only a big coincidence--most observers would likely find themselves comparing "Bad Teacher" with "Bad Santa," the 2003 cult comedy that was also about a greedy and self-absorbed jerk who found himself employed in a job that had him constantly exposed to little children--a department store Santa in this case--as part of a scam designed to line his coffers with ill-gotten gains. "Bad Santa" was pretty hilarious and while some of that was due to the outrageous nature of the material at hand--especially the stuff found in director Terry Zwigoff's preferred cut that eventually made its way to DVD--a lot of the success of that film was due to the pitch-perfect casting of Billy Bob Thornton in the central role. All it took was one look at his eternally world-weary face to convince viewers that this was a person whose lifetime of questionable personal and professional decisions had led him to the point where holiday-based felonies seemed like the most logical thing to do. Additionally, Thornton was both brave enough to throw himself fully into the part to the degree that he plumbed seedy depths rarely seen in the lead character of an American film, especially a comedy aimed at mass audiences, and talented enough so that when he needed to shift gears in the final scenes and act slightly more noble (ever so slightly), the change seemed like a real move on his part and not just a convenient screenplay contrivance. For "Bad Teacher" to work, it requires an actress able to pull off a high-wire act similar to the one done by Thornton--it needs someone who is able to be convincingly and effortlessly hateful and vulgar in virtually every frame while at the same time come across as alluring enough to distract people, at least those possessing a Y chromosome, from fully recognizing her otherwise obviously repellent nature. If I were to think of actresses off the top of my head who could potentially pull off that combination, people like Rose McGowan or Uma Thurman or Angelina Jolie immediately spring to mind--hell, if there was any evidence that she had a comedic bone in her body, Megan Fox might have made for an ideal fit.

While Cameron Diaz more than adequately fulfills the babe-related requirements (and then some), it only takes but a few scenes to realize that she is otherwise a completely disastrous choice for the role of Elizabeth. Simply put, ever since making her splashy debut back in 1994's "The Mask," Diaz has been one of the most reliably cheerful and sunny presences to grace the multiplexes--so much so that in "My Best Friend's Wedding," she went head-to-head with Julia Roberts, then at the height of her reign as America's Sweetheart, and just plain stole both the movie and the hearts of most audiences in the process--and that persona simply doesn't jibe with the character that she is asked to play here; casting her in such a role is akin to hiring someone as sunny as Drew Barrymore and then asking then to play someone as monstrous as Lucretia Borgia or my prom date. This isn't to say that Diaz can't play darker or more complicated roles--she did just that in films as diverse as "Being John Malkovich," "Vanilla Sky" and "Gangs of New York"--but in order to pull them off, she needs strong material to work with to help achieve that transformation. Needless to say, she doesn't get that here and while I suppose that she deserves some credit for at least giving it the old college try, she is never particularly convincing in the part--her bitchiness seems forced throughout and only serves to highlight the inconsistencies and inexplicable aspects of the role, starting with the fundamental question of why someone who hates kids so much would go into teaching in the first place and ending with the last-minute change of heart that Elizabeth undergoes that would feel like a hasty and especially idiotic last-minute mandate from nervous studio executives if it weren't just as ineptly written and executed as everything preceding it.

That said, the failure of "Bad Teacher" to generate many laughs should not be laid exclusively at Diaz's feet. The screenplay by Gene Stupnitsky & Lee Eisenberg, the geniuses who previously gave us the comedic black hole that was "Year One" and who are now currently charged with writing the projected new "Ghostbusters" film, is a complete mess filled with inconsistent characterizations (Timberlake's character veers from being an overly sensitive dreamboat to a weirdo horn dog virtually from scene to scene and without rhyme or reason), plot developments that are introduced only to go virtually nowhere and a finale so arbitrarily slapped together that it feels as if they just gave up on even trying to resolve things in anything resembling a coherent form. The once-promising director Jake Kasdan, whose previous accomplishments have included the wonderful "Zero Effect," the underrated "Orange County" and numerous episodes of the late, great "Freaks & Geeks," offers up what barely makes the grade as hackwork on his end--instead of presenting a biting satire of either the current education system or of movies about noble educators trying to buck said system, he instead gives us a wan attempt to approximate the Judd Apatow school of filmmaking that it resembles only in the sense that it goes on for far too long even though it only clocks in at just over 90 minutes. As for the other members of the cast, Justin Timberlake and Lucy Punch, both of whom have demonstrated keen comedic chops in the past, are largely wasted in roles that make little sense and which make even less use of their abilities On the other hand, Segel lights up the screen (in more ways than one) in his scenes as Diaz's low-key pursuer--his lines have such an immediate comedic snap to them that I can only assume that he came up with most of them himself. He also participates in the film's single funniest moment in which he gets into an argument with one of his students about the relative abilities of LeBron James in comparison to Michael Jordan-it is a bit that has admittedly been played to death in the commercials but it still works and at the screening I attended, it was greeted with actual applause.

The good news about "Bad Teacher" is that it is funnier than "The Hangover: Part II" but the bad news is that it isn't that much funnier in the long run. From the slapdash nature of the whole enterprise, it seems as if the people involved came up with the title and the poster, both of which are admittedly good, and then pretty much decided that their work was done. With the exception of the writers, all of the key people involved with this project have done good things before and will no doubt do good things again in the very near future. Unfortunately, they haven't done so here and as a result, "Bad Teacher" is a film limp and lazy enough to make one yearn for the glory days of "Teachers" instead.