This site requires JavaScript, please enable it in your browser!
Greenfoot back
divinity
divinity wrote ...

2018/4/30

Trying to create a welcome page for when member login it

divinity divinity

2018/4/30

#
hi there am trying to create a welcome page for when a member register/login but i dont quite know where the error is. i know there is an error there somewhere but as usual, finding my errors in one of my major fault. I am doing it in php the opening tag in php is red as it supposed to be but the closing tag is black which is not supposed to be among other codes in the form I put it in a html form but it is saved as a php. the closing tag of the body and html element are black in color which i dont think it should be. it should be blue but somewhere in the codes is an error, can someone explain to me why it is like that. trying looking through the codes but cant find it, i even past it thru a php validator. here is the codes that I have tried. <?php session_start(); if(isset($_SESSION)) { header('Location:login.php'); } ?> <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11.dtd"> <html xmlns="http:www.w3.org/1999/xhtml"xml:lang="en" lang="en"> <head> <title> Welcome - <?php echo <$_SESSION; ?></title> </head> <body> <?php <h2> Welcome!!!</h2> <option value="realname"><?php echo $_SESSION. ' ' .$_SESSION?></option> ?> </body> </html>
danpost danpost

2018/4/30

#
Looks like you have an extra angle bracket, <, before the dollar sign, $, in the head section.
You need to login to post a reply.