예제 #1
0
<?php

include "../init.php";
$page = page_order($page, "13");
include "../config.php";
if (!isset($lang) || empty($lang) || !file_exists("../lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "../lang/" . "{$lang}" . ".php";
include "../common.php";
if ($HTTP_POST_VARS['name']) {
    $database = Connect();
    $var = $HTTP_POST_VARS;
    foreach ($var as $key => $val) {
        if (!$val) {
            $var[$key] = "NULL";
        }
    }
    print "<html>\n";
    print "  <head>\n";
    print "    <META HTTP-EQUIV=Expires CONTENT=\"" . date("D, j M Y G:i:s") . " GMT\">\n";
    print "  </head>\n";
    print "  <body>\n";
    print " <center><h1>" . $end . "</h1>";
    $sql = "INSERT INTO " . $db_prefix . "director VALUES (null,'" . $var['name'] . "'," . $var['country'] . "," . $var['year'] . ");";
    mysql_query($sql);
    $result = mysql_query("SELECT id FROM " . $db_prefix . "director WHERE name='" . $var['name'] . "';");
    $id = mysql_fetch_array($result);
    mysql_free_result($result);
    if ($result) {
        print $correct . " (" . $var['name'] . " -> " . $id[0] . ")\n";
예제 #2
0
파일: index.php 프로젝트: dpecos/phpfilm
<?php

/*
 *	PHPFilm
 *
 *	Copyright (C) 2002 Daniel Pecos Martínez
 *
 *	Licensed under GPL
 */
include "init.php";
$page = page_order($page, "00");
include "config.php";
if (!isset($lang) || empty($lang) || !file_exists("lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "lang/" . "{$lang}" . ".php";
include "common.php";
print_header();
print "  <body bgcolor=\"" . $bgcolor . "\">\n";
print "    <center>\n";
print "      <h1><font color=\"" . $title_color . "\">" . $webtitle . "</font></h1>\n";
print "      <h4><font color=\"" . $title_color . "\">[ <a href=\"index_detailed.php\">{$detailed}</a> | <a href=\"admin\">{$admin}</a> ]\n</font></h4>\n";
$query = "SELECT * FROM " . $db_prefix . "film ORDER BY title;";
show_index($query);
print "      <br><br>\n";
print "      <small><a href=\"http://netpecos.org/projects/phpfilm/\" target=\"_new\"><font color=\"" . $title_color . "\">PHP Film " . $version . "</font></a></small>\n";
/*print "      <p>\n";
print "        <a href=\"http://validator.w3.org/check/referer\"><img border=\"0\"\n";
print "          src=\"http://www.w3.org/Icons/valid-html401\"\n";
print "          alt=\"Valid HTML 4.01!\" height=\"31\" width=\"88\"></a>\n";
print "      </p>\n";*/
예제 #3
0
<?php

/*
 *	PHPFilm
 *
 *	Copyright (C) 2002 Daniel Pecos Martínez
 *
 *	Licensed under GPL
 */
include "init.php";
$page = page_order($page, "03");
include "config.php";
if (!isset($lang) || empty($lang) || !file_exists("lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "lang/" . "{$lang}" . ".php";
include "common.php";
$database = Connect();
$var = $HTTP_POST_VARS;
$result = mysql_query("SELECT name, country, year FROM " . $db_prefix . "actor WHERE id='" . $var['actor_id'] . "';");
$arr = mysql_fetch_array($result);
print "<html><head>\n";
print "<title>" . $webtitle . "</title>\n";
print "<META NAME=\"Title\" CONTENT=\"" . $webtitle . "\">\n";
print "<META http-equiv=\"Content-Style-Type\" content=\"text/css\">\n";
print "<LINK type=\"text/css\" rel=\"stylesheet\" href=\"style.css\">\n";
print "</head>\n";
print "<body bgcolor=\"{$bgcolor}\"><center>\n";
print "<h1><font color=\"" . $title_color . "\">" . $t_view_actor . "</font></h1><br>\n";
print "<table width=\"40%\" border=0 cellspacing=0 cellpadding=1 ><tr><td>\n";
print "<table width=\"100%\" border=0 cellspacing=1 cellpadding=5>\n";
예제 #4
0
파일: index.php 프로젝트: dpecos/phpfilm
<?php

include "../init.php";
$page = page_order($page, "99");
include "../config.php";
if (!isset($lang) || empty($lang) || !file_exists("../lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "../lang/" . "{$lang}" . ".php";
print "<html>\n";
print "  <head>\n";
print "    <META HTTP-EQUIV=Expires CONTENT=\"" . date("D, j M Y G:i:s") . " GMT\">\n";
print "  </head>\n";
print "  <body>\n";
print "    <center><h1>" . $webtitle . "</h1></center>\n";
print "    <br><br><center><small><a href=\"http://netpecos.org/projects/phpfilm/\" target=\"_new\">PHP Film " . $version . "</a></small></center>\n";
print "    <ul>\n";
print "      <li><a href=\"add_film.php\">" . $add . "</a>/<a href=\"del_film.php\">" . $del . "</a>/<a href=\"edit_film.php\">" . $edit . "</a> " . $film . "</li>\n";
print "      <li><a href=\"add_genre.php\">" . $add . "</a>/<a href=\"del_genre.php\">" . $del . "</a>/<a href=\"edit_genre.php\">" . $edit . "</a> " . $genre . "</li>\n";
print "      <li><a href=\"add_actor.php\">" . $add . "</a>/<a href=\"del_actor.php\">" . $del . "</a>/<a href=\"edit_actor.php\">" . $edit . "</a> " . $actor . "</li>\n";
print "      <li><a href=\"add_director.php\">" . $add . "</a>/<a href=\"del_director.php\">" . $del . "</a>/<a href=\"edit_director.php\">" . $edit . "</a> " . $director . "</li>\n";
print "      <li><a href=\"add_country.php\">" . $add . "</a>/<a href=\"del_country.php\">" . $del . "</a>/<a href=\"edit_country.php\">" . $edit . "</a> " . $country . "</li>\n";
print "      <br><br>";
print "      <li><a href=\"password.php\">" . $passwd_admin . "</a>\n";
print "      <li><a href=\"people.php\">" . $loan_admin . "</a>\n";
print "    </ul>\n";
print "    <center>\n";
switch (back_to($page)) {
    case "00":
        print "    <br><br><a href=\"../index.php\">{$simple}</a><br>\n";
        break;
예제 #5
0
<?php

include "../init.php";
$page = page_order($page, "11");
include "../config.php";
if (!isset($lang) || empty($lang) || !file_exists("../lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "../lang/" . "{$lang}" . ".php";
include "../common.php";
if ($HTTP_POST_VARS['name']) {
    $database = Connect();
    $var = $HTTP_POST_VARS;
    foreach ($var as $key => $val) {
        if (!$val) {
            $var[$key] = "NULL";
        }
    }
    print " <center><h1>" . $end . "</h1>";
    $sql = "INSERT INTO " . $db_prefix . "actor VALUES (null,'" . $var['name'] . "'," . $var['country'] . "," . $var['year'] . ");";
    mysql_query($sql);
    $result = mysql_query("SELECT id FROM " . $db_prefix . "actor WHERE name='" . $var['name'] . "';");
    $id = mysql_fetch_array($result);
    mysql_free_result($result);
    if ($result) {
        print $correct . " (" . $var['name'] . " -> " . $id[0] . ")\n";
    }
    if ($HTTP_POST_VARS['id']) {
        mysql_query("INSERT INTO " . $db_prefix . "actor_film VALUES (null," . $HTTP_POST_VARS['id'] . "," . $id[0] . ");");
        print "<form action=\"edit_film.php\" method=\"post\">\n";
        print "<input type=\"hidden\" name=\"id\" value=\"" . $HTTP_POST_VARS['id'] . "\">\n";
예제 #6
0
<?php

/*
 *	PHPFilm
 *
 *	Copyright (C) 2002 Daniel Pecos Martínez
 *
 *	Licensed under GPL
 */
include "init.php";
$page = page_order($page, "02");
include "config.php";
if (!isset($lang) || empty($lang) || !file_exists("lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "lang/" . "{$lang}" . ".php";
include "common.php";
if ($HTTP_POST_VARS['id']) {
    $database = connect();
    $var = $HTTP_POST_VARS;
    $query = "SELECT * FROM " . $db_prefix . "film WHERE id=" . $var['id'] . ";";
    $result = mysql_query($query);
    $tmp = mysql_fetch_assoc($result);
    foreach ($tmp as $key => $val) {
        if (!$val) {
            $tmp[$key] = "&nbsp;";
        }
    }
    if ($tmp["country"] == "&nbsp;") {
        $tmp["country"] = "";
    }
예제 #7
0
<?php

/*
 *	PHPFilm
 *
 *	Copyright (C) 2002 Daniel Pecos Martínez
 *
 *	Licensed under GPL
 */
include "init.php";
$page = page_order($page, "04");
include "config.php";
if (!isset($lang) || empty($lang) || !file_exists("lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "lang/" . "{$lang}" . ".php";
include "common.php";
$database = Connect();
$var = $HTTP_POST_VARS;
$result = mysql_query("SELECT name, country, year FROM " . $db_prefix . "director WHERE id='" . $var['director_id'] . "';");
$arr = mysql_fetch_array($result);
print "<html><head>\n";
print "<title>" . $webtitle . "</title>\n";
print "<META NAME=\"Title\" CONTENT=\"" . $webtitle . "\">\n";
print "<META http-equiv=\"Content-Style-Type\" content=\"text/css\">\n";
print "<LINK type=\"text/css\" rel=\"stylesheet\" href=\"style.css\">\n";
print "</head>\n";
print "<body bgcolor=\"{$bgcolor}\"><center>\n";
print "<h1><font color=\"" . $title_color . "\">" . $t_view_director . "</font></h1><br>\n";
print "<table width=\"40%\" border=0 cellspacing=0 cellpadding=1 ><tr><td>\n";
print "<table width=\"100%\" border=0 cellspacing=1 cellpadding=5>\n";
예제 #8
0
<?php

include "../init.php";
$page = page_order($page, "34");
include "../config.php";
if (!isset($lang) || empty($lang) || !file_exists("../lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "../lang/" . "{$lang}" . ".php";
include "../common.php";
$database = Connect();
if ($HTTP_POST_VARS['add_director']) {
    $var = $HTTP_POST_VARS;
    $result = mysql_query("INSERT INTO " . $db_prefix . "director_film VALUES (null," . $var['id'] . "," . $var['add_director'] . ");");
}
if ($HTTP_POST_VARS['add_actor']) {
    $var = $HTTP_POST_VARS;
    $result = mysql_query("INSERT INTO " . $db_prefix . "actor_film VALUES (null," . $var['id'] . "," . $var['add_actor'] . ");");
}
if ($HTTP_POST_VARS['del_director']) {
    $result = mysql_query("DELETE FROM " . $db_prefix . "director_film WHERE id='" . $HTTP_POST_VARS['del_director'] . "';");
}
if ($HTTP_POST_VARS['del_actor']) {
    $result = mysql_query("DELETE FROM " . $db_prefix . "actor_film WHERE id='" . $HTTP_POST_VARS['del_actor'] . "';");
}
if ($HTTP_POST_VARS['add_argument']) {
    $var = $HTTP_POST_VARS;
    $result = mysql_query("DELETE FROM " . $db_prefix . "argument WHERE film_id=" . $var['id'] . ";");
    if ($var['add_argument'] != "") {
        $result = mysql_query("INSERT INTO " . $db_prefix . "argument VALUES (null," . $var['id'] . ",'" . $var['add_argument'] . "');");
    }
예제 #9
0
<?php

/*
 *	PHPFilm
 *
 *	Copyright (C) 2002 Daniel Pecos Martínez
 *
 *	Licensed under GPL
 */
include "init.php";
$page = page_order($page, "01");
include "config.php";
if (!isset($lang) || empty($lang) || !file_exists("lang/" . "{$lang}" . ".php")) {
    $lang = "language_en";
}
include "lang/" . "{$lang}" . ".php";
include "common.php";
print_header();
print "  <body bgcolor=\"" . $bgcolor . "\"><center>\n";
print "<h1><font color=\"" . $title_color . "\">" . $webtitle . "</font></h1>\n";
print "<h4><font color=\"" . $title_color . "\">[ <a href=\"index.php\">{$simple}</a> | <a href=\"admin\">{$admin}</a> ]\n</font></h4>";
$query = "SELECT * FROM " . $db_prefix . "film ORDER BY title;";
show_index_detailed($query);
print "<br><br><small><a href=\"http://netpecos.org/projects/phpfilm/\" target=\"_new\"><font color=\"" . $title_color . "\">PHP Film " . $version . "</font></a></small>\n";
print "</center></body></html>\n";