From: "Stephan Trajkoff" <stephan@itp.bg>
To: parisc-linux@lists.parisc-linux.org
Subject: [parisc-linux] Not working PHP, security hole
Date: Thu, 11 Jul 2002 22:49:15 +0300 [thread overview]
Message-ID: <20020711194810.2007D485F@dsl2.external.hp.com> (raw)
Please admins of parisc-linux to fix their problem
<?
$_db_host=3D"localhost";
#$_db_host=3D"puffin.external.hp.com";
$_db_user=3D"parisc";
$_db_password=3D"parisc";
$_db_database=3D"hw";
$_db_connection=3D"_db_unconnected";
$_db_result=3D"";
$_db_row=3D"";
Function connectDatabase(){
global $_db_host;
global $_db_user;
global $_db_password;
global $_db_connection;
if($_db_connection=3D=3D"_db_unconnected"){
$_db_connection=3Dmysql_connect
($_db_host,$_db_user,$_db_password);
}
}
Function queryDatabase($query){
global $_db_database;
global $_db_result;
$_db_result =3D mysql_db_query($_db_database,$query);
return $_db_result;
}
Function nextRow($result =3D "_db_unset"){
global $_db_result;
global $_db_row;
if($result=3D=3D"_db_unset"){
$_db_row =3D mysql_fetch_object($_db_result);
}
elseif(is_integer($result)){
$_db_row =3D mysql_fetch_object($result);
}
else {
return "";
}
return $_db_row;
}
Function numRows($result =3D "_db_unset"){
global $_db_result;
if($result=3D=3D"_db_unset"){
return mysql_num_rows($_db_result);
}
elseif(is_integer($result)){
return mysql_num_rows($result);
}
return "";
}
Function disconnectDatabase(){
global $_db_result;
global $_db_connection;
mysql_free_result($_db_result);
mysql_close($_db_connection);
}
Function insertId(){
return mysql_insert_id();
}
Function escapeString($instring){
return AddSlashes($instring);
}
?>
use apachetoolbox to compile apache php mysql
www.apachetoolbox.com
-------------------------------------------------------------------
-->> Add WEB ACCESS to your POP email accounts with
-->> FREE Perl CGI scripts! Download today! http://www.adjeweb.com
-------------------------------------------------------------------
next reply other threads:[~2002-07-11 19:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-07-11 19:49 Stephan Trajkoff [this message]
2002-07-11 20:18 ` [parisc-linux] Not working PHP, security hole Matt Taggart
2002-07-11 20:24 ` Randolph Chung
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020711194810.2007D485F@dsl2.external.hp.com \
--to=stephan@itp.bg \
--cc=parisc-linux@lists.parisc-linux.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox