i have installed php and mysql my php file is saved as php and when i run my php fie it shows me the code instead of UI and when i change the php file name to php.ini i get a database error stating mysql connection not made
You didn't install PhP correctly. Make sure yuou associated the executable to an extension, such as.php, and that your code is using that extension. Make sure you alloowed the extension you're using.
ya the php have been compiled correctly i tried it in Xampp and its working properly.there is no error no i get the code that you see starting from windows.onload on the browser
<?
/**
* the user end cache callback function will be used to
* modify the output a little
*
* return the modified output for current script
*/
function USER_ENDCACHE_CALLBACK($output)
{
$output .= <<<EOF
<script>
window.onload = newUploadSession();
</script>
EOF;
return $output;
}
define("IN_PAGE",'INDEX');
define("PAGE_TITLE",'SITENAME');
include "includes/inc.php";
$baseUrl='index.php?';
if($input[logout]==1)
{
$user->logout();
header("location:$baseWeb/index.php");
exit;
}
showUploadForm();
if($user->setting[show_featured_files])
{
$template->assign_var('show_featured_files',$user->setting[show_featured_files]);
#ListFiles('','RAND()',0,0,4,4);
ListFiles('','time',0,0,4,4);
#ListFiles('','totalrated',0,0,5,5);
}
$load_prototype=1;
$load_uploadjs=1;
require_once("header.php");
$template->set_filenames(array(
'body' => 'index.body.html')
);
$template->pparse('body');
include "footer.php";
?>
ammunair
3 Posts
cant work on mysql and php together
Feb 24, 2013 04:22 PM|LINK
i have installed php and mysql my php file is saved as php and when i run my php fie it shows me the code instead of UI and when i change the php file name to php.ini i get a database error stating mysql connection not made
jeff@zina.co...
3379 Posts
MVP
Moderator
Re: cant work on mysql and php together
Feb 25, 2013 02:39 PM|LINK
You didn't install PhP correctly. Make sure yuou associated the executable to an extension, such as.php, and that your code is using that extension. Make sure you alloowed the extension you're using.
Jeff
ammunair
3 Posts
Re: cant work on mysql and php together
Feb 25, 2013 02:45 PM|LINK
i have installed php53 via windows platform installer added the fact CGI in handler mapping changed the php.ini files but still not able to see UI
webhost.uk.n...
1 Post
Re: cant work on mysql and php together
Feb 28, 2013 11:27 AM|LINK
What is the exact error you get this time. Are you sure you have compile php correctly?
WebhostUK LTD
ammunair
3 Posts
Re: cant work on mysql and php together
Feb 28, 2013 11:36 AM|LINK
ya the php have been compiled correctly i tried it in Xampp and its working properly.there is no error no i get the code that you see starting from windows.onload on the browser
<? /** * the user end cache callback function will be used to * modify the output a little * * return the modified output for current script */ function USER_ENDCACHE_CALLBACK($output) { $output .= <<<EOF <script> window.onload = newUploadSession(); </script> EOF; return $output; } define("IN_PAGE",'INDEX'); define("PAGE_TITLE",'SITENAME'); include "includes/inc.php"; $baseUrl='index.php?'; if($input[logout]==1) { $user->logout(); header("location:$baseWeb/index.php"); exit; } showUploadForm(); if($user->setting[show_featured_files]) { $template->assign_var('show_featured_files',$user->setting[show_featured_files]); #ListFiles('','RAND()',0,0,4,4); ListFiles('','time',0,0,4,4); #ListFiles('','totalrated',0,0,5,5); } $load_prototype=1; $load_uploadjs=1; require_once("header.php"); $template->set_filenames(array( 'body' => 'index.body.html') ); $template->pparse('body'); include "footer.php"; ?>