當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Mysql_error函數代碼示例

本文整理匯總了PHP中Mysql_error函數的典型用法代碼示例。如果您正苦於以下問題:PHP Mysql_error函數的具體用法?PHP Mysql_error怎麽用?PHP Mysql_error使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了Mysql_error函數的12個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: ceil

            } else {
                $strankovani .= '<a href="?m=objednavky&i_min=' . $i . '">' . ceil($i / 10) . '</a> &nbsp;&nbsp; | &nbsp;&nbsp;';
            }
        }
        $i++;
    }
    $strankovani = str_replace("| &nbsp;&nbsp; &end;", "", $strankovani . " &end;");
    $strankovani = str_replace("&end;", "", $strankovani);
    $strankovani .= '</center>';
    echo $strankovani;
}
/************************/
/* Zobrazení objednávek */
/************************/
/* -- Stránky -- */
$dotaz = Mysql_query("SELECT COUNT(uzivatelJmeno) FROM {$CONF['sqlPrefix']}objednavky WHERE uzivatelJmeno!='' ") or die(Mysql_error());
$radek = @mysql_fetch_array($dotaz);
$pocetObjednavek = $radek["COUNT(uzivatelJmeno)"];
$strankovani = '<center>';
$i = 1;
while ($i < $pocetObjednavek) {
    if ($i == 161) {
        $strankovani .= '<span style="cursor: pointer;" onClick="ukazSkryj(\'divOdkazyDalsi\');">Starší »</span> <div id="divOdkazyDalsi" style="display: none;">';
    }
    if ($i % 10 == 1) {
        if ($_GET["i_min"] == $i) {
            $strankovani .= '<a href="?m=objednavky&i_min=' . $i . '" style="text-decoration: none; font-weight: bold;">' . ceil($i / 10) . '</a> &nbsp;&nbsp; | &nbsp;&nbsp;';
        } else {
            $strankovani .= '<a href="?m=objednavky&i_min=' . $i . '">' . ceil($i / 10) . '</a> &nbsp;&nbsp; | &nbsp;&nbsp;';
        }
    }
開發者ID:GE3,項目名稱:GE3,代碼行數:31,代碼來源:objednavky.php

示例2: send

function send()
{
    // fonction appelée quand on clique 'OK' sur le formulaire
    global $sommaireformkeysommaire, $sommaireformgroupmenu, $sommaireformname, $sommaireformimage, $sommaireformlien, $sommaireformingroup, $sommaireformmoduleimage, $sommaireformmodulelink, $sommaireformmodulelinktext, $sommaireformcenter, $sommaireformhr, $sommaireformbgcolor, $sommaireformradio, $sommaireformclass, $sommaireformbold, $sommaireformnew, $sommaireformlistbox, $sommaireformeachcategoryclass, $sommaireformmodulegras, $sommaireformmodulenew, $sommaireformnew_type, $sommaireformnew_days, $sommaireformmodulenew_days, $sommaireformfirstnew_days, $sommaireformmoduleclass, $sommaireformclassformodules, $sommaireformfirstclass, $sommaireformdynamic, $db, $prefix, $sql;
    //	global $sommaireformmoduleimage0_0, $sommaireformmoduleimage0_1, $sommaireformmoduleimage0_2, $sommaireformmoduleimage1_0, $sommaireformmoduleimage1_1, $sommaireformmoduleimage1_2;
    $sommaireformnew_days = $sommaireformnew_type == "on" ? $sommaireformnew_days : "-1";
    //si les valeurs de 'groupmenu' (Poids) entrées dans le formulaire ne sont pas des nombres de 0 à 98, --> die
    for ($i = 0; $i <= $sommaireformkeysommaire; $i++) {
        if (!ereg("([0-9]{1,2})", $sommaireformgroupmenu[$i]) or $sommaireformgroupmenu[$i] == 99) {
            include "header.php";
            GraphicAdmin();
            OpenTable();
            echo "<div align=\"center\">";
            echo "" . _SOMINVALIDWEIGHT . "&nbsp;'{$sommaireformname[$i]}'&nbsp;({$sommaireformgroupmenu[$i]})";
            echo "<br>" . _SOMMUSTBENUM . "";
            echo "</div>";
            CloseTable();
            include "footer.php";
            return;
        }
        // si 2 catégories ont le même groupmenu (poids) --> die
        for ($j = 0; $j <= $sommaireformkeysommaire; $j++) {
            if ($i != $j) {
                if ($sommaireformgroupmenu[$i] == $sommaireformgroupmenu[$j]) {
                    include "header.php";
                    GraphicAdmin();
                    OpenTable();
                    echo "<div align=\"center\">";
                    echo "" . _SOMCATS . "&nbsp;'{$sommaireformname[$i]}'&nbsp;" . _SOMAND . "&nbsp;'{$sommaireformname[$j]}'&nbsp;" . _SOMSAMEWEIGHT . "&nbsp;({$sommaireformgroupmenu[$i]})";
                    echo "<br>" . _SOMMODIFWEIGHT . "";
                    echo "<br>NB :&nbsp;" . _SOMMUSTBENUM . "";
                    echo "</div>";
                    CloseTable();
                    include "footer.php";
                    return;
                }
            }
        }
    }
    // sinon, on insère les données dans les tables nuke_sommaire et nuke_sommaire_categories.
    // d'abord, on va effacer les données de ces 2 tables !
    $db->sql_query("DELETE FROM " . $prefix . "_sommaire");
    $db->sql_query("DELETE FROM " . $prefix . "_sommaire_categories");
    //détection de nuke v.7 : y a-t-il une gestion des groupes?
    global $user_prefix;
    $sql = "SELECT * FROM " . $prefix . "_modules LIMIT 1";
    $result = $db->sql_query($sql);
    $row = $db->sql_fetchrow($result);
    echo Mysql_error();
    if (isset($row['mod_group'])) {
        $sql2 = "SELECT * FROM " . $user_prefix . "_users LIMIT 1";
        $result2 = $db->sql_query($sql2);
        $row2 = $db->sql_fetchrow($result2);
        echo Mysql_error();
        $gestiongroupe = isset($row2['points']) ? 1 : 0;
    } else {
        $gestiongroupe = 0;
    }
    // à chaque ligne du formulaire, on fait une requête pour insérer les données.
    for ($i = 0; $i <= $sommaireformkeysommaire; $i++) {
        for ($j = 0; $j < count($sommaireformingroup[$i]); $j++) {
            $zeclass = $sommaireformfirstclass != $sommaireformclassformodules ? $sommaireformclassformodules : $sommaireformmoduleclass[$i][$j];
            $zeclass = $zeclass == "" ? $sommaireformclassformodules : $zeclass;
            //si la classe est vide, alors on remplit avec la classe par défaut.
            $zenew_days = $sommaireformfirstnew_days != $sommaireformnew_days ? $sommaireformnew_days : $sommaireformmodulenew_days[$i][$j];
            //si on n'a pas changé le nb jours dans l'admin, on recopie les valeurs précédentes.
            $zenew_days = $zenew_days == "" ? $sommaireformnew_days : $zenew_days;
            //si le nb de jour est vide, alors on remplit avec le nb de jours par défaut.
            if ($sommaireformingroup[$i][$j] == "Lien externe") {
                //si il y a un lien, on insère les données du lien
                $sql = "INSERT INTO " . $prefix . "_sommaire_categories (groupmenu, module, url, url_text, image, new, new_days, class, bold) VALUES ('{$sommaireformgroupmenu[$i]}', '" . $sommaireformingroup[$i][$j] . "', '" . $sommaireformmodulelink[$i][$j] . "', '" . $sommaireformmodulelinktext[$i][$j] . "', '" . $sommaireformmoduleimage[$i][$j] . "', '" . $sommaireformmodulenew[$i][$j] . "', '" . $zenew_days . "', '" . $zeclass . "', '" . $sommaireformmodulegras[$i][$j] . "')";
                $db->sql_query($sql);
                echo MySql_error();
            } elseif ($sommaireformingroup[$i][$j] == "SOMMAIRE_HR") {
                $sql = "INSERT INTO " . $prefix . "_sommaire_categories (groupmenu, module, url, url_text, image, new, new_days, class, bold) VALUES ('{$sommaireformgroupmenu[$i]}', '" . $sommaireformingroup[$i][$j] . "', '', '' , '', '" . $sommaireformmodulenew[$i][$j] . "', '" . $zenew_days . "',  '" . $zeclass . "', '" . $sommaireformmodulegras[$i][$j] . "')";
                $db->sql_query($sql);
                echo MySql_error();
            } else {
                if ($sommaireformingroup[$i][$j] != "Aucun") {
                    //sinon, (si il y a un module) on insère le nom du module, et pas de lien.
                    $sql = "INSERT INTO " . $prefix . "_sommaire_categories (groupmenu, module, url, url_text, image, new, new_days, class, bold) VALUES ('{$sommaireformgroupmenu[$i]}', '" . $sommaireformingroup[$i][$j] . "', '', '' , '" . $sommaireformmoduleimage[$i][$j] . "', '" . $sommaireformmodulenew[$i][$j] . "', '" . $zenew_days . "',  '" . $zeclass . "', '" . $sommaireformmodulegras[$i][$j] . "')";
                    $db->sql_query($sql);
                    echo MySql_error();
                }
            }
            // --> si 'Aucun' est sélectionné dans les modules, on n'insère aucune donnée !
        }
        // si la catégorie ne contient aucune donnée (complètement vide), alors on ne l'insère pas dans la DB.
        if ($sommaireformname[$i] == '' && $sommaireformimage[$i] == "noimg" && $sommaireformlien[$i] == '' && $sommaireformhr[$i] == '' && $sommaireformcenter[$i] == '' && $sommaireformbgcolor[$i] == '') {
        } else {
            $zeclass = $sommaireformeachcategoryclass[0] != $sommaireformclass ? $sommaireformclass : $sommaireformeachcategoryclass[$i];
            // si la class a été changée via l'admin, on indique cette classe pour toutes les catégories, sinon on recopie le nom de la classe utilisée auparavant.
            $zeclass = $zeclass == "" ? $sommaireformclass : $zeclass;
            //si la classe est vide, alors on remplit avec la classe par défaut.
            if ($gestiongroupe == 1 && $sommaireformradio == 2) {
                $invisible = 4;
            } elseif ($gestiongroupe == 1 && $sommaireformradio == 3) {
                $invisible = 5;
            } else {
                $invisible = $sommaireformradio;
//.........這裏部分代碼省略.........
開發者ID:BackupTheBerlios,項目名稱:domsmod-svn,代碼行數:101,代碼來源:sommaire.php

示例3: mysql_fetch_row

	unset($_SESSION["list_drug_reason"][$count-1]);
	unset($_SESSION["list_drug_reason2"][$count-1]);
	exit();
}

//************************** Ай╢╖црб║рцбрЦкИЮевм║  ********************************************************
if(isset($_GET["action"]) && $_GET["action"] == "drug"){
	
	if($_GET["search"] == "viat"){
		$where = "drugcode = '5FLES' OR ";
	}
	
	$sql = "Select prefix From `runno` where `title`  = 'passdrug' limit 1 ";
	list($pass_drug) = mysql_fetch_row(mysql_query($sql));
	$sql = "Select drugcode, tradname, genname,unit, stock, salepri, part, `lock`, lock_dr From druglst where ".$where." (drugcode like '%".$_GET["search"]."%' OR genname LIKE '%".$_GET["search"]."%' OR  tradname LIKE '%".$_GET["search"]."%') Order by drugcode ASC";
	$result = Mysql_Query($sql)or die(Mysql_error());

	if(Mysql_num_rows($result) > 0){
		echo "<Div style=\"position: absolute;text-align: center; width:760px; height:320px; overflow:auto; \">";

		
		echo "<table bgcolor=\"#FFFFCC\" width=\"740\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"><tr align=\"center\" bgcolor=\"#3333CC\"><td width=\"20\"><font style=\"color: #FFFFFF\"></font></td><td width=\"73\"><font style=\"color: #FFFFFF\"></font></td><td width=\"368\"><font style=\"color: #FFFFFF\"><strong>╙вХмбр</strong></font></td><td width=\"110\"><font style=\"color: #FFFFFF\"><strong>к╧Хгб</strong></font></td><td width=\"50\"><font style=\"color: #FFFFFF\"><strong>цр╓р</strong></font></td><td width=\"15\" bgcolor=\"#3333CC\"><font style=\"color: #FF0000;\"><strong><A HREF=\"#\" onclick=\"document.getElementById('list').innerHTML='';\">X</A></strong></font></td></tr>";


		$i=1;
		while($arr = Mysql_fetch_assoc($result)){
				
				if($arr["lock_dr"] != "Y"){
					
					if($arr["lock_dr"] =="N"){
						$obj = "бр╣я╢мм║";
開發者ID:robocon,項目名稱:shs,代碼行數:31,代碼來源:dt_drug.php

示例4: ddrugrx

                            break;
                        case "DSN":
                            $update = ",dsn=dsn+" . $salepri * $_POST["amount"];
                            break;
                    }
                }
            }
            $sql = "INSERT INTO ddrugrx(date,hn,drugcode,tradname,amount,price,item,slcode,part,idno, salepri, freepri,office ) VALUES ('" . $_GET["sDate"] . "','" . $hn . "','" . $_POST["drugcode"] . "','" . $tradname . "', '" . $_POST["amount"] . "','" . $_POST["amount"] * $salepri . "','" . $item . "','" . $_POST["slcode"] . "','" . $part . "','" . $_GET["nRow_id"] . "','" . $salepri . "','" . $freepri . "','" . $_SESSION["sOfficer"] . "');";
            $result1 = Mysql_Query($sql) or die("à¡Ô´¤ÇÒÁ¼Ô´¾ÅÒ´ã¹Ãкº ¡ÃÙ³Ò ¾ÔÁ¾ì˹éҨ͹ÕéäÇéãËéâ»Ãá¡ÃÁàÁÍÃì´Ù¤ÃѺ<BR> " . Mysql_error());
            $sql = "update ddrugrx set item = item+1 where idno='" . $_GET["nRow_id"] . "' AND date = '" . $_GET["sDate"] . "'  ;";
            if ($result1 == true) {
                $result2 = Mysql_Query($sql) or die("à¡Ô´¤ÇÒÁ¼Ô´¾ÅÒ´ã¹Ãкº ¡ÃÙ³Ò ¾ÔÁ¾ì˹éҨ͹ÕéäÇéãËéâ»Ãá¡ÃÁàÁÍÃì´Ù¤ÃѺ<BR> " . Mysql_error());
            }
            $sql = "update dphardep set item = item+1,price=price+" . $salepri * $_POST["amount"] . " " . $update . "  where row_id='" . $_GET["nRow_id"] . "' AND date = '" . $_GET["sDate"] . "' limit 1; ";
            if ($result2 == true) {
                $result3 = Mysql_Query($sql) or die("à¡Ô´¤ÇÒÁ¼Ô´¾ÅÒ´ã¹Ãкº ¡ÃÙ³Ò ¾ÔÁ¾ì˹éҨ͹ÕéäÇéãËéâ»Ãá¡ÃÁàÁÍÃì´Ù¤ÃѺ<BR> " . Mysql_error());
            }
            if ($result1 == true && $result2 == true && $result3 == true) {
                echo "ºÑ¹·Ö¡¢éÍÁÙÅàÃÕºÃéÍÂáÅéÇ<BR><A HREF=\"drxadddrug.php?sDate=" . urlencode($_GET["sDate"]) . "&nRow_id=" . urlencode($_GET["nRow_id"]) . "\">à¾ÔèÁÂÒ</A><BR>ËÒ¡äÁèà¾ÔèÁÂÒáÅéÇãËé»Ô´Ë¹éÒ¹ÕéàŤÃѺ\n\t\t\t<SCRIPT LANGUAGE=\"JavaScript\">\n\t\t\t\t\n\t\t\t\topener.location.reload();\n\t\t\t\tsetTimeout(\"window.location.href='drxadddrug.php?sDate=" . urlencode($_GET["sDate"]) . "&nRow_id=" . urlencode($_GET["nRow_id"]) . "';\",5000);\n\n\t\t\t</SCRIPT>\n\t\t\t";
            }
            exit;
        }
    }
}
?>

<FORM METHOD=POST ACTION="">
<TABLE>
<TR>
	<TD>ÃËÑÊÂÒ</TD>
	<TD><INPUT TYPE="text" NAME="drugcode"></TD>
開發者ID:robocon,項目名稱:shs,代碼行數:31,代碼來源:drxadddrug.php

示例5: CONCAT

		$sql = "Select   a.`row_id`, a.`vn`, a.`hn`, a.`an`, a.`dx`, a.`organ`, a.`maintenance`, a.`doctor`, CONCAT(b.`yot`,' ',b.`name`,' ',b.`surname`) as `full_name`, `age`, `list_ptright`, left(`time_in`,5) as `left2in`, left(`time_out`, 5) as `left2`, `cure`, `admit_ward`, `refer_hospital`, CONCAT(a.`time_in`,' ',date_format(a.`date`,'%H:%i:%s')) as `h_date`, `time_in`, left(`time_diag`,5) as `time_diag2`, date_format(`date_in`,'%d/%m/%Y') as `date_in2`, `type_wounded`, `repeat`, `type_patient`, `cause_refer`, `doc_refer`,  `nurse`,  `assistant_nurse`,  `estimate`,  `cradle`, `doc_txt`,  `no_estimate`, b.`phone`, a.`consult`, `er_tell`, `suggestion`  
		From (
						SELECT * 
						FROM `trauma` 
						WHERE ".$where."
					) AS `a`, 
		`opcard` as `b` 
		where a.`hn` = b.`hn`  
		Order by `date_in` ASC, `h_date` ASC ";
		//echo $sql;
		$echoka = "";
		$echoka1 = "";
		$i=0;

		$result = Mysql_Query($sql) or die("<!-- ".Mysql_error()." -->");
		$rows = Mysql_num_rows($result);
		?>
¨Ó¹Ç¹¢éÍÁÙÅ·Ñé§ËÁ´  <?php echo $rows;?>
<TABLE cellpadding="2" cellspacing="0" border="1" bordercolor="#000000" style='BORDER-COLLAPSE: collapse'>
<?php if($_POST["coder"] == "1"){?>

<TR>
	<TD align="center">ÅӴѺ</TD>
	<TD align="center">Ç.´.».</TD>
	<TD align="center">HN</TD>
	<TD>ÂȪ×èÍ-Ê¡ØÅ</TD>
	<TD align="center">ÍÒÂØ</TD>
	<TD align="center">Êѧ¡Ñ´</TD>
	<TD align="center">Dx.</TD>
</TR>
開發者ID:robocon,項目名稱:shs,代碼行數:30,代碼來源:report_trauma06.php

示例6: Mysql_query

$TmplModul->prirad("hlavicka.popis", "Umožňuje spravovat základní nastavení vašich stránek.");
//Editace nastavení
if ($_POST["akce"] == 'zakladni-nastaveni') {
    Mysql_query("UPDATE {$CONF['sqlPrefix']}nastaveni \n                 SET emailAdmin='{$_POST['emailAdmin']}', title='{$_POST['title']}', objednavky_autosender='{$_POST['objednavky_autosender']}' \n                 WHERE id=1") or die(Mysql_error());
}
if ($_POST["old_pass"] and $_POST["new_pass"]) {
    if ($_POST["old_pass"] == $_SESSION["heslo"]) {
        if ($_POST["new_pass"] == $_POST["new_pass_2"]) {
            $uzivatel = mysql_fetch_assoc(mysql_query("SELECT * FROM {$CONF['sqlPrefix']}uzivatele WHERE heslo=MD5('{$_POST['old_pass']}')"));
            if ($uzivatel["id"]) {
                Mysql_query("UPDATE {$CONF['sqlPrefix']}uzivatele SET heslo=MD5('{$_POST['new_pass']}') WHERE heslo=MD5('{$_POST['old_pass']}')");
                $_SESSION["heslo"] = $_POST["new_pass"];
                $TmplNastaveni->prirad("hlaska_heslo.text", "Heslo úspěšně změněno");
            } else {
                $TmplNastaveni->prirad("hlaska_heslo.text", "Špatně zadané staré heslo");
            }
        } else {
            $TmplNastaveni->prirad("hlaska_heslo.text", "Hesla nesouhlasí");
        }
    } else {
        $TmplNastaveni->prirad("hlaska_heslo.text", "Špatně zadané staré heslo");
    }
    Mysql_query("UPDATE {$CONF['sqlPrefix']}nastaveni \n                 SET emailAdmin='{$_POST['emailAdmin']}', title='{$_POST['title']}', objednavky_autosender='{$_POST['objednavky_autosender']}' \n                 WHERE id=1") or die(Mysql_error());
}
//Zobrazení aktuálních informací
$radek = mysql_fetch_assoc(Mysql_query("SELECT * FROM {$CONF['sqlPrefix']}nastaveni"));
foreach ($radek as $key => $value) {
    $TmplNastaveni->prirad($key, $value);
}
$TmplModul->prirad("obsah", $TmplNastaveni->getHtml());
echo $TmplModul->getHtml();
開發者ID:GE3,項目名稱:GE3,代碼行數:31,代碼來源:nastaveni.php

示例7: if

			echo "<CENTER><B>ºÑ¹·Ö¡¢éÍÁÙÅàÃÕºÃéÍÂáÅéÇ</B><BR><A HREF=\"#\" Onclick=\"window.location.href='trauma.php';\">&lt;&lt; ¡ÅѺ</A></CENTER>";

		}else{

			echo "<CENTER><B>äÁèÊÒÁÒöºÑ¹·Ö¡¢éÍÁÙÅä´é¡ÃسҵԡµèÍâ»Ãá¡ÃÁàÁÍÃì</B><BR><A HREF=\"#\" Onclick=\"window.location.href='trauma.php';\">&lt;&lt; ¡ÅѺ</A></CENTER>";

		}
		
		//echo "<META HTTP-EQUIV=\"Refresh\" CONTENT=\"2;URL=trauma.php\">";
		exit();
	}else if(isset($_GET["action"]) && $_GET["action"] == "del"){



		$sql ="Delete From trauma Where row_id = '".$_GET["id"]."' limit 1" ;
		$result = Mysql_Query($sql) or Mysql_error();
		
		$sql = "Delete From trauma_lst_labcare where for_id = '".$_GET["id"]."' ";
		$result2 = Mysql_Query($sql);
		$sql = "Delete From trauma_labcare where for_id = '".$_GET["id"]."' ";
		$result2 = Mysql_Query($sql);

		$sql = "Delete From trauma_cpg where for_id = '".$_GET["id"]."' ";
		$result2 = Mysql_Query($sql);

		if($result){
			
			echo "<CENTER><B>ź¢éÍÁÙÅàÃÕºÃéÍÂáÅéÇ</B><BR><A HREF=\"#\" Onclick=\"window.location.href='trauma.php';\">&lt;&lt; ¡ÅѺ</A></CENTER>";

		}else{
開發者ID:robocon,項目名稱:shs,代碼行數:30,代碼來源:trauma.php

示例8: date

    if ($freepri > $salepri) {
        $freepri = $salepri;
    }
    $dg_dsy = $freepri;
    $dg_dsn = $salepri - $freepri;
} else {
    $dg_dsy = 0;
    $dg_dsn = 0;
}
$today = date("Y") + 543 . date("-m-d H:i:s");
$query = "INSERT INTO ddrugrx(date,hn,drugcode,tradname,amount,price,item,slcode,part,idno, salepri, freepri, drug_inject_amount,drug_inject_unit, drug_inject_amount2,drug_inject_unit2,drug_inject_time,drug_inject_slip, drug_inject_type, drug_inject_etc,reason,DPY , DPN ,date_notsk ) VALUES ('0000-00-00 00:00:00','" . $rxHn . "','" . $drugcode . "','" . $tradname . "','" . $nostk . "','" . $nostk * $salepri . "','1','" . $slcode . "','" . $part . "','" . $idno . "','" . $salepri . "','" . $freepri . "','" . $drug_inject_amount . "','" . $drug_inject_unit . "','" . $drug_inject_amount2 . "','" . $drug_inject_unit2 . "','" . $drug_inject_time . "','" . $drug_inject_slip . "','" . $drug_inject_type . "','" . $drug_inject_etc . "','" . $reason . "','" . $dg_dsy * $nostk . "','" . $dg_dsn * $nostk . "','" . $today . "')";
//$commar = ",";
//$sub_drugcode1 = ord(substr($_SESSION["list_drugcode"][$i],0,1));
//$sub_drugcode2 = ord(substr($_SESSION["list_drugcode"][$i],1,1));
if ($insert1 == true) {
    $result2 = Mysql_Query($query) or die(Mysql_error());
}
//echo "<!-- ".$query." -->";
/*if($insert1 ==true && $result2 ==true){
		
		$_SESSION["nRunno"] = "";
		$_SESSION["list_drugcode"] = array() ;
		$_SESSION["list_drugamount"] = array() ;
		$_SESSION["list_drugslip"] = array() ;

		$_SESSION["list_drug_inject_amount"] = array() ;
		$_SESSION["list_drug_inject_unit"] = array() ;
		$_SESSION["list_drug_inject_amount2"] = array() ;
		$_SESSION["list_drug_inject_unit2"] = array() ;
		$_SESSION["list_drug_inject_time"] = array() ;
		$_SESSION["list_drug_inject_slip"] = array() ;
開發者ID:robocon,項目名稱:shs,代碼行數:31,代碼來源:drxremain.php

示例9: Mysql_Query

    				$result2 = Mysql_Query($sql2);
    				while($arr2 = Mysql_fetch_assoc($result2)){
    					$list[$i] = $arr2["code"];
    					$i++;
    				}
    
    				echo "<A HREF=\"#\" Onclick=\"addsuittolist('".implode("][",$list)."');\">".$arr["detail"]."</A><BR>";
    			}		
    			}*/
    echo "\t</TD>\n</TR>\n</TABLE>\n";
    exit;
}
//*****************************áÊ´§µÑǪèÇ Other********************//
if (isset($_GET["action"]) && $_GET["action"] == "other") {
    $sql34 = "Select distinct(other) from appoint where other like '%" . $_GET["search1"] . "%' limit 10 ";
    $result34 = Mysql_Query($sql34) or die(Mysql_error());
    if (Mysql_num_rows($result34) > 0) {
        echo "<Div style=\"position: absolute;text-align: center; width:400px; height:430px; overflow:auto; \">";
        echo "<table width=\"400\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#FF99CC\"><tr align=\"center\" bgcolor=\"#333333\">\n\t\t<td width=\"10\"><strong>&nbsp;</strong></td>\n\t\t<td width=\"200\"><font style=\"color: #FFFFFF;\"><strong>ÃÒ¡ÒÃ</strong></font></td>\n\t\t<td width=\"10\"><strong>&nbsp;&nbsp;<A HREF=\"#\" onclick=\"document.getElementById('list1').innerHTML='';\"><font style=\"color: #FFFF99;\">»Ô´</font></A></strong></td>\n\t\t</tr>";
        //$i=1;
        while ($se = Mysql_fetch_assoc($result34)) {
            echo "<tr>\n\t\t<td valign=\"top\" width=\"10\"></td>\n\t\t<td width=\"200\"><A HREF=\"javascript:void(0);\" Onclick=\"document.getElementById('other').value = '" . $se['other'] . "';document.getElementById('list1').innerHTML ='';\">" . $se['other'] . "</A></td>\n\t\t<td width=\"10\">&nbsp;</td></tr>";
        }
        echo "</TABLE></Div>";
    }
    exit;
}
//************************** áÊ´§ÃÒ¡Òà lab  ********************************************************
if (isset($_GET["action"]) && $_GET["action"] == "addtolist") {
    $sql = "Select detail, yprice, nprice From labcare where code = '" . $_GET["code"] . "' limit 1; ";
    list($detail, $yprice, $nprice) = Mysql_fetch_row(Mysql_Query($sql));
開發者ID:robocon,項目名稱:shs,代碼行數:31,代碼來源:dt_appoint.php

示例10: date

        $commar = ", ";
    }
    $_SESSION["dt_drugstk"] .= "</TD>\n\t</TR>";
}
$_SESSION["dt_drugstk"] .= "</TABLE>";
$sql = "Select detail_all From xray_doctor where date like '" . (date("Y") + 543) . date("-m-d") . "%' AND hn = '" . $_SESSION["hn_now"] . "' AND doctor = '" . $_SESSION["dt_doctor"] . "' Order by date DESC limit 1";
$result = Mysql_Query($sql);
if (Mysql_num_rows($result) > 0) {
    $_SESSION["dt_drugstk"] .= "\n\t<TR>\n\t\t<TD colspan=\"3\"><font style=\"font-family:'MS Sans Serif'; font-size:10px\"> <B>X-Ray</B> :";
    $arr = mysql_fetch_assoc($result);
    $_SESSION["dt_drugstk"] .= "<BR>" . nl2br($arr["detail_all"]);
    $_SESSION["dt_drugstk"] .= "</TD>\n\t</TR>";
}
$_SESSION["dt_drugstk"] .= "</TABLE>";
if ($insert1 == true && $count > 0) {
    $result2 = Mysql_Query($add) or die(Mysql_error());
}
//echo "<!-- ".$add." -->";
if ($insert1 == true && $result2 == true) {
    $_SESSION["nRunno"] = "";
    $_SESSION["list_drugcode"] = array();
    $_SESSION["list_drugamount"] = array();
    $_SESSION["list_drugslip"] = array();
    $_SESSION["list_drug_inject_amount"] = array();
    $_SESSION["list_drug_inject_unit"] = array();
    $_SESSION["list_drug_inject_amount2"] = array();
    $_SESSION["list_drug_inject_unit2"] = array();
    $_SESSION["list_drug_inject_time"] = array();
    $_SESSION["list_drug_inject_slip"] = array();
    $_SESSION["list_drug_inject_type"] = array();
    $_SESSION["list_drug_inject_etc"] = array();
開發者ID:robocon,項目名稱:shs,代碼行數:31,代碼來源:dt_drug_add.php

示例11: GlassTemplate

<?php

$TmplModul = new GlassTemplate("templates/{$CONF['vzhled']}/modul.html");
$TmplNastaveni = new GlassTemplate("templates/{$CONF['vzhled']}/podobne_produkty.html");
//Hlavička
$TmplModul->prirad("hlavicka.ikona", "templates/{$CONF['vzhled']}/images/podobne_produkty.png");
$TmplModul->prirad("hlavicka.nadpis", "Podobné produkty");
$TmplModul->prirad("hlavicka.popis", "Modul, který umožní přidávat k produktům podobné produkty.");
//Editace nastavení
if ($_POST["akce"] == 'podobne-produkty') {
    Mysql_query("UPDATE {$CONF['sqlPrefix']}nastaveni \n                 SET podobne_produkty_active='{$_POST['podobne_produkty_active']}' \n                 WHERE id=1") or die(Mysql_error());
}
//Zobrazení aktuálních informací
$radek = mysql_fetch_assoc(Mysql_query("SELECT * FROM {$CONF['sqlPrefix']}nastaveni"));
foreach ($radek as $key => $value) {
    $TmplNastaveni->prirad($key, $value);
}
$TmplModul->prirad("obsah", $TmplNastaveni->getHtml());
echo $TmplModul->getHtml();
開發者ID:GE3,項目名稱:GE3,代碼行數:19,代碼來源:podobne_produkty.php

示例12: header

    header("Location :/buynsell/index.php?exp=1");
    exit;
}
?>

<?php 
include "db.php";
include "dnb.html";
if (isset($_POST['feedback'])) {
    $connection = mysqli_connect($WEBHOST, $USER, $PASSWORD, $DATABASE);
    if (!$connection) {
        die("Could not connect to the Database " . Mysql_error());
    }
    $result = mysqli_query($connection, "INSERT INTO feedback(ufriendly,bugs,improvements,user_id) VALUE('{$_POST['ufriendly']}','{$_POST['bugs']}','{$_POST['improvements']}','{$_SESSION['user_id']}')");
    if (!$result) {
        die("mysql query over the database error has occured " . Mysql_error());
    }
    echo "<br /><br /><div class='alert alert-success'>Thank you for your valuable feedback! We will surely look into it ASAP. Mother Promise!</span>";
}
?>
<html>
	<body>
        <div class='container col-xs-10 col-xs-offset-1'>
		<br /><br />
		
            <div class='col-xs-10 col-xs-offset-1'>
                <div class='jumbotron'><h4>Hi,</h4><h3><small> We at WebOps are really enthusiastic to listen to your suggestions to make this site better. And we would be really happy if you could take some time off to give us your feedback below</small><br></h3></div>
			<form method = POST action = feedback.php>

				<p>1. Do you find this page user friendly?</p>
				<input type = "radio" name = "ufriendly" value = "yes"> Yes</input>
開發者ID:tirupatihemanth,項目名稱:buynsell,代碼行數:31,代碼來源:feedback.php


注:本文中的Mysql_error函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。