You are here: PHP Blank Page. « PHP Programming Language « IT news, forums, messages
PHP Blank Page.

Posted by techjohnny@gmail.com on 06/19/07 17:18

Ok,

I posted earlier about this, a blank php page. I've enabled logging
ALL in the php.ini, but nothing. If I change the name of the db in
the include file, I get an error message, so I guess this means it's
connecting to the mysql db. I've included the first couple lines of
code for this page:

index.php
<?php
session_start();
require_once('inc/db_config.inc.php');
$conn = db_connect();
$sqlsu = "SELECT * FROM subjects ORDER BY ID";
$ressu = mysql_query($sqlsu, $conn);
if (mysql_num_rows($ressu)) {
while ($qry = mysql_fetch_array($ressu)) {
$cat = stripSlashes($qry['cat']);
$resns = mysql_query("SELECT * FROM questions WHERE test LIKE '$cat'",
$conn);
$numcat = mysql_num_rows($resns);

inc/db_config.inc.php


function db_connect()
{
$result = @mysql_pconnect('localhost', 'root', 'password);
if (!$result)
return false;
if (!@mysql_select_db('quiz'))
return false;

return $result;
}
?>

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация