Projekt

Obecné

Profil

Stáhnout (1.9 KB) Statistiky
| Větev: | Tag: | Revize:
1
<!--
2
Editace Lukádem:
3
Vůbec na to nechci hrabat, ale potřebujem to propojit z pgsql na mysql.
4
Větší prasárnu jsem neviděl a ani se nechci vyjadřovat k tomu co teď udělám.
5
Tohle chce úplnej rework a na to já nemám....
6
-->
7

    
8
<HTML>
9
<HEAD>
10
    <META content=text/html;charset=utf-8 http-equiv=Content-Type>
11
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD W3 HTML//EN">
12
    <TITLE>List of OB signs in the scope of OB Graphemic Analyses Project</TITLE>
13
    <LINK REL=StyleSheet HREF="/utf/obtc1.css" TYPE="text/css" MEDIA="screen, print">
14
</HEAD>
15
<body>
16
<h3 align=center>Selected variants <BR>from<BR> the Old Babylonian Graphemic Analyses</H3>
17
<br>
18
<?php
19
require_once('dbconfig.php');
20

    
21
$conn = new mysqli(DB_HOST, DB_USER, DB_PASSWORD, DB_NAME);
22
$conn->set_charset("utf8");
23

    
24
if ($conn->connect_error) {
25
    die("Connection failed: " . $conn->connect_error);
26
}
27
echo "<BR>";
28
$chain = $_GET["borger"];
29

    
30
$query = "SELECT bcislo, images FROM images WHERE bcislo = $chain";
31
$result = $conn->query($query);
32

    
33
if ($result->num_rows > 0) {
34
    echo("Selected Borger's number: <b>$chain</b>&nbsp; <BR>\n$result->num_rows variant(s) found.<br>\n");
35
    echo("<BR>\n");
36
    for ($i = 0; $i < $result->num_rows; $i++) {
37
        list ($bcislo, $images) = mysqli_fetch_row($result);
38
        echo("<img src=\"png/$images\" WIDTH=40 HEIGHT=40 BORDER=1>");
39
    }
40
    echo("<BR><BR>");
41
} else {
42
    echo("Nothing found, try again.");
43
}
44

    
45
$query2 = "SELECT gnazev, lcteni, scteni, bcislo01 FROM graf01 WHERE bcislo01 = $chain";
46
$result = $conn->query($query2);
47

    
48
if($result->num_rows > 0){
49
    echo ("<BR>\n");
50
    for ($i=0; $i < $result->num_rows; $i++)
51
    {
52
        list ($gnazev, $lcteni, $scteni, $bcislo01) = mysqli_fetch_row($result);
53
        echo ("Sign name: &nbsp; $gnazev<BR>");
54
        echo ("Logographic values: &nbsp; $lcteni<BR>");
55
        echo ("Syllabic values: &nbsp;<i>$scteni</i><BR>");
56
    }
57
}
58

    
59
mysqli_close($conn);
60
?>
61
</table>
62
<br>
63
</BODY>
64
</HTML>
(83-83/135)