link is , http://www.alibdaa.com/course.php?type=type&term=1

********************course.php*********
<html>
<head>
<meta name="GENERATOR" content="Microsoft FrontPage 6.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<?php

        <table>
        <tr>
        <td>
        
  if (!$type || !$term)
  {
     echo "Please go back and try again.";

     exit;
  }
  
  $searchcat = addslashes($type);
  $searchterm = addslashes($term);

  include("file path for  Connecting to database");

 if (!$db)
  {
     echo "Error: Could not connect to data.  Please try again 
later.";

     exit;
  }
include("file path for database name");   

// get the catogry from Table
$query1 = "SELECT * FROM TableName WHERE FiledName 
like ".$searchterm ;
  $result1 = mysql_query($query1);

  $trow = mysql_fetch_array($result1);

                // tables here//  
echo "<table width='510' border='1' cellspacing='0' cellpadding='2' 
bordercolorlight='#FFFFFF' bordercolordark='#FFFFFF' style='border-
collapse: collapse' bordercolor='#111111' id='tblmain'>";
        echo "<tr>";
        echo "<td  align='center' bgcolor='#0071BB' valign='top' 
bordercolorlight='#FFFFFF' bordercolordark='#FFFFFF' colspan='6'>";
    echo "<p align='center'>";
    echo "<span style='font-weight: 700'>";
        echo "<font face='Tahoma' style='font-size: 9pt' 
color='#FFFFFF'>";
        echo stripslashes($trow["typename"]);
        echo "</font>";
        echo "</span></td></tr>";
    echo "<tr>";
        
    echo "<td width='16' height='1'  align='center' 
bgcolor='#CDDDEF' valign='top' bordercolorlight='#FFFFFF' 
bordercolordark='#FFFFFF' bordercolor='#000000'>";
    echo "&nbsp;</td>";
    echo "<td width='43' height='1'  align='center' 
bgcolor='#CDDDEF' bordercolor='#000000'>";
    echo "<font color='#005588' face='Tahoma' style='font-size: 
8pt'>";
    echo "<span lang='ar-kw'><b>Titel 1 </b></span></font></td>";
    echo "<td width='41' height='1'  align='center' 
bgcolor='#CDDDEF' bordercolor='#000000'>";
    echo "<font face='Tahoma' style='font-size: 8pt'><span lang='ar-
eg'><font color='#005588'>";
        echo "<b> Titel 2</b></font></span><font 
color='#005588'><span lang='ar-
kw'><b></b></span></font></font></td>";
    echo "<td width='338' height='1'  align='center' 
bgcolor='#CDDDEF' bordercolor='#000000'><b>";
    echo "<font color='#005588' face='Tahoma' style='font-size: 
8pt'>Titel 3</font>";
        echo "</b></td><td width='47' height='1'  bgcolor='#CDDDEF' 
align='center' bordercolor='#000000'><span lang='ar-kw'>";
        echo "<font color='#005588' face='Tahoma' style='font-size: 
8pt'><b>Titel 4 </b></font></span></td>";
    echo "<td width='45' height='1'  align='center' 
bgcolor='#CDDDEF' bordercolor='#000000'><b>";
        echo "<font color='#005588' face='Tahoma' style='font-size: 
8pt'>Titel 5</font>";
        echo "</b></td> </tr>";
// end table header //


include("file path for database name");  
  $query = "select * from TABLEname  where ".$searchcat." 
like '%".$searchterm."%'";
  $result = mysql_query($query);
    $num_results = mysql_num_rows($result);
  
  for ($i=0; $i <$num_results; $i++)
  {
  $in = $i+1;
    $row = mysql_fetch_array($result);
        echo "<tr><td height='20' width='16'  bgcolor='#CDDDEF' 
align='center' bordercolor='#000000'>";
          echo "<font color='#005588' style='font-size: 8pt' 
face='Tahoma'>" .$in. "</font></td>";
          echo "<td height='23' bgcolor='#EAEAEA'  width='43' 
align='center' dir='rtl' bordercolor='#000000'><font face='Tahoma'>";
          echo "<span style='font-size: 8pt'>";
                  echo stripslashes($row["date"]);
                  echo "</span></font></td>";
          echo "<td height='23' bgcolor='#EAEAEA'  width='41' 
align='center' dir='rtl' bordercolor='#000000'><font face='Tahoma'>";
          echo "<span style='font-size: 8pt'>";
                  echo stripslashes($row["month"]);
              echo "</span></font></td><td height='23' 
bgcolor='#EAEAEA'  width='338' align='center' 
bordercolor='#000000'>";
          echo "<font face='Tahoma'><span style='font-size: 8pt'>";
                  echo stripslashes($row["name"]);
                  echo "</span></font></td><td height='23' 
bgcolor='#EAEAEA'  width='47' align='center' bordercolor='#000000'>";
                  echo "<p><font face='Tahoma'><span style='font-
size: 8pt'>";
                  echo stripslashes($row["location"]);
                  echo "</span></font></td><td height='23' 
bgcolor='#EAEAEA'  width='45' align='center' 
bordercolor='#000000'><font face='Tahoma'><span style='font-size: 
8pt'>";
                  echo stripslashes($row["cost"]);
          echo " $</span></font></td> </tr>";

  }
        echo "<td height='20' width='100%'  bgcolor='#FFFFFF' 
align='center' bordercolor='#000000' colspan='6'><b>";
        echo "<font color='#CC3300' style='font-size: 8pt' 
face='Tahoma'>Last line ;</font>";
        
    echo "</table>";
// end table //
?>

</html>


********************************************

> > Best regards 
> > Mohamed Ziada
> > +20124974449
> > =================








Community email addresses:
  Post message: [email protected]
  Subscribe:    [EMAIL PROTECTED]
  Unsubscribe:  [EMAIL PROTECTED]
  List owner:   [EMAIL PROTECTED]

Shortcut URL to this page:
  http://groups.yahoo.com/group/php-list 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php-list/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to