PHP Classes

File: ajax.php

Recommend this page to a friend!
  Classes of Neda Divbandi   PHP jQuery UI MySQL Tabs   ajax.php   Download  
File: ajax.php
Role: Example script
Content type: text/plain
Description: ajax File
Class: PHP jQuery UI MySQL Tabs
Show master detail MySQL records using tabs
Author: By
Last change:
Date: 10 years ago
Size: 843 bytes
 

Contents

Class file image Download
<?php
 
include 'class.tabs.php';



if(isset(
$_POST['TabsgettmasterName'])){
$ui = new jqueryTabs('localhost', 'root', '', 'onlineexam');
    echo
$ui->createTabs(
        array(
'table' => $_POST['TabsgettmasterName'], 'title' => $_POST['TabsgettmasterField'], 'PK' => 'id')
      
    );
}
   
if(isset(
$_POST['getMFKTab'])){
   
mysql_connect('localhost', 'root', '');
     
mysql_select_db('onlineexam');
     
mysql_query("SET NAMES UTF8");
     
$param=$_POST['getMFKTab'];
     
$tableD=$_POST['getDTTableNameTab'];
      
$tableDField=$_POST['getDTableFieldTab'];
      
$myquery=mysql_query("SELECT * FROM `$tableD` WHERE `lessonId` =$param ");
       if(
mysql_num_rows($myquery)>0){
       while (
$result= mysql_fetch_assoc($myquery)){
           echo
$result[$tableDField];
       }
       }
}


?>