How to open a PDO file?

How to open this file .php file?

  • <?php /* * Include the necessary files */ include_once 'inc/functions.inc.php'; include_once 'inc/db.inc.php'; // Open a database connection $db = new PDO(DB_INFO, DB_USER, DB_PASS); // Determine if an entry ID was passed in the URL $id = (isset($_GET['id'])) ? (int) $_GET['id'] : NULL; // Load the entries $e = retrieveEntries($db, $id); // Get the fulldisp flag and remove it from the array $fulldisp = array_pop($e); // Sanitize the entry data $e = sanitizeData($e); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml... <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html;charset=utf-8" /> <link rel="stylesheet" href="/css/default.css" type="text/css" /> <title> Simple Blog </title> </head> <body> <h1> Simple Blog Application </h1> <div id="entries"> <?php // If the full display flag is set, show the entry if($fulldisp==1) { ?> <h2> <?php echo $e['title'] ?> </h2> <p> <?php echo $e['entry'] ?> </p> <p class="backlink"> <a href="./">Back to Latest Entries</a> </p> <?php } // End the if statement ?> <p class="backlink"> <a href="simple_blog/admin.php">Post a New Entry</a> </p> </div> <p class="backlink"> <a href="simple_blog/admin.php">Post a New Entry</a> </p> </div> </body> </html> I try to access this file on my computer via apache server installed... but I can't access/open this file ...everything is installed correctly , apache server, MySql, php on my computer.. Please help me as I am stuck here for a while a now! thanks in advance!

  • Answer:

    try require_once("'inc/functions.inc.php"); make sure the file is in the folder inc where you are working.

Aman Grover at Yahoo! Answers Visit the source

Was this solution helpful to you?

Other answers

try require_once("'inc/functions.inc.php"); make sure the file is in the folder inc where you are working.

Kelly

Install 'xampp' server. It is a package of 'Apache' 'Mysql', 'PHP' & 'Perl'........ open ur web browser and type "http://localhost/yourprogramname.php" Make sure you copied this program to htdocs folder in 'xampp'

Sid

download wamp , its super easy to use!!

Irish Dude

download wamp , its super easy to use!!

Irish Dude

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.