2011-12-16, 11:36:59
n00dles101 Wrote:its the begin jquery script
change it to this...
Code:// begin Jquery
echo "<script type=\"text/javascript\">";
//For Each User XML Filed, Print jQuery To Show/Hide The 'Edit User' And 'Add User' Sections
foreach (glob($dir) as $file) {
$xml = simplexml_load_file($file) or die("Unable to load XML file!");
echo "\$(\".edit-user$xml->USR\").click(function () {";
echo "\n";
echo "\$(\".edit-user$xml->USR\").slideUp();";
echo "\n";
echo "\$(\".hide-user$xml->USR\").slideDown();";
echo "\n";
echo "\$(\".hide-div$xml->USR\").css('display','block');";
echo "\n";
echo "});";
echo "\n";
echo "\$(\".hide-user$xml->USR\").click(function () {";
echo "\n";
echo "\$(\".edit-user$xml->USR\").slideDown();";
echo "\n";
echo "\$(\".hide-user$xml->USR\").slideUp();";
echo "\n";
echo "\$(\".hide-div$xml->USR\").css('display','none');";
echo "\n";
echo "});";
echo "\$(\"hideagain\").click(function () {";
echo "\n";
echo "\$(\".edit-user$xml->USR\").slideUp();";
echo "\n";
echo "\$(\".hide-div$xml->USR\").css('display','none');";
echo "\n";
echo "});";
echo "\$(\"#add-user\").click(function () {";
echo "\n";
echo "\$(\"#add-user\").slideUp();";
echo "\n";
echo "\$(\".hide-div\").slideDown();";
echo "\n";
echo "});";
}
echo "</script>";
Awesome, thanks.