Dialog box limitations?

hey folks,
i m working on a web app. making its pop up box into dialog boxes. though i made some but now i am faced with a problem. the dialog box which is called (the abc.php) has some php code and form tag, when i click the button the page (abc.php) splashes (just open n closes), on much testing when i commented the form tag in abc.php. and when i clicked on button which call the abc.php in dialog opened just fined. now i am not guru of jQuery or Php, but i wanted to ask are there any limitation to dialog box or some rules other than a xhtml markup that my page is behaving that way? though i m a developer, the engineering guy’s will tackle the problem but i wanted to know for my knowledge