Jump to content

Help :(


dean7

Recommended Posts

Hi, Ive got a website that im coding but im trying to make it so when you login you can you username on the stats bar but im allways getting an error :( please help.

 

Stats.php

<? 
/* Include Files *********************/
session_start(); 
include("test.php");
include("index.php");
/*************************************/
?>
<style type="text/css">
<!--
.style3 {color: #0033FF}
.style4 {color: #FFFFFF}
body {
background-color: #333333;
}
a:link {
color: #0033FF;
text-decoration: none;
}
a:visited {
text-decoration: none;
color: #0033FF;
}
a:hover {
text-decoration: underline;
color: #0033FF;
}
a:active {
text-decoration: none;
color: #0033FF;
}
-->
</style>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
</head>

<body>
Username: (later) Logout

<? 
if($logged_in){
   echo 'Logged in as '.$_SESSION['username'].
}else{
   echo 'You need to log in! <a href="index.php">Login</a>';
};
?>

<script language=JavaScript>
<!--

//Disable right mouse click Script
//By Maximus ([email protected]) w/ mods by DynamicDrive
//For full source code, visit http://www.dynamicdrive.com

var message="Right click disabled thoughout the website! sorry.";

///////////////////////////////////
function clickIE4(){
if (event.button==2){
alert(message);
return false;
}
}

function clickNS4(e){
if (document.layers||document.getElementById&&!document.all){
if (e.which==2||e.which==3){
alert(message);
return false;
}
}
}

if (document.layers){
document.captureEvents(Event.MOUSEDOWN);
document.onmousedown=clickNS4;
}
else if (document.all&&!document.getElementById){
document.onmousedown=clickIE4;
}

document.oncontextmenu=new Function("alert(message);return false")

// --> 
</script>
</body>
</html>

 

Im not sure if i need to show you any other files, but if so please say :)

Link to comment
https://forums.phpfreaks.com/topic/151458-help/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.