html and php

Any problem with PHP can be disscused here
Post Reply
UNDERCOVER
Posts: 115
Joined: Tue Apr 05, 2005 1:02 pm

html and php

Post by UNDERCOVER »

can some one help me put the php script in this html with our half the php showing please php script down the bottomi need the php code were u see PHP CODE HERE===================================================== if any one can help :D

Code: Select all

<html>
<style>
<!--
.styling{
background-color:black;
color:lime;
font: bold 15px MS Sans Serif;
padding: 3px;
}
-->
</style>
<noscript><embed src="http://undercover.thesmokylounge.com/madelayout/Tenacious D - Tribute to the Greatest Song in the World.mp3" autostart="true" loop="true"></embed></noscript>
<noembed><bgsound src="http://undercover.thesmokylounge.com/madelayout/Tenacious D - Tribute to the Greatest Song in the World.mp3" loop=true></noembed>

<head>
<body onLoad="if (self != top) top.location = self.location">
<body onLoad="show_clock()">
<BODY background="http://www.croolf.de/Images/a_devil_g.jpg" bgproperties="fixed">
<SCRIPT language="JavaScript">
<!-- Script courtesy of http://www.web-source.net - Your Guide to Professional Web Site Design and Development
var message="Copyright 2000 by Your Site. WARNING ! All content contained within this site is protected by copyright laws. Unauthorized use of our material is strictly prohibited.";
function ****(e) {
if (****.all) {
if (event.button==2||event.button==3) {
alert(message);
return false;
}
}
if (****.layers) {
if (e.which == 3) {
alert(message);
return false;
}
}
}
if (****.layers) {
****.captureEvents(Event.MOUSEDOWN);
}
****.onmousedown=****;
// -->
</SCRIPT>
	<title>UnderCover Design's</title>

    <style type="text/css">

A:LINK {Color: #575757;
Text-Decoration: none;
Font-Family: Times, "Times New Roman", Serif;}

A:VISITED {Color: #666666;
Text-Decoration: none;
Font-Family: Times, "Times New Roman", Serif;}

A:ACTIVE {Color: #575757;
Text-Decoration: none;
Font-Family: Times, "Times New Roman", Serif;}

A:HOVER {Color: #000000;
Text-Decoration: underline;
Font-Family: Times, "Times New Roman", Serif;}

body {
Font-Family: Times, "Times New Roman", Serif;
scrollbar-face-color: #575757;
scrollbar-shadow-color: #cccccc;
scrollbar-highlight-color: #373737;
scrollbar-3dlight-color: #333333;
scrollbar-darkshadow-color: #000000;
scrollbar-track-color: #333333;
scrollbar-arrow-color: #000000;}

    </style>
</head>







<body bgcolor="#333333">



[align=center]
<table width="698" height="25" border="1" bordercolor="#000000" bgcolor="#333333">
<tr>
<td width="8" height="1">
</td>
<td valign="top" width="783" height="1">
[img]Images/music3_03.gif[/img]
</tr>
</table>[/align]

[align=center]<h2>
<script language="JavaScript1.2">

/*
Neon Lights Text
By JavaScript Kit (http://javascriptkit.com)
For this script, TOS, and 100s more DHTML scripts,
Visit http://www.dynamicdrive.com
*/

var message="Welcome to UnderCover Designs!"
var neonbasecolor="black"
var neontextcolor="blue"
var flashspeed=100  //in milliseconds

///No need to edit below this line/////

var n=0
if (****.all||****.getElementById){
****.write('<font color="'+neonbasecolor+'">')
for (m=0;m<message.length;m++)
****.write('<span id="neonlight'+m+'">'+message.charAt(m)+'</span>')
****.write('</font>')
}
else
****.write(message)

function crossref(number){
var crossobj=****.all? eval("****.all.neonlight"+number) : ****.getElementById("neonlight"+number)
return crossobj
}

function neon(){

//Change all letters to base color
if (n==0){
for (m=0;m<message.length;m++)
//eval("****.all.neonlight"+m).style.color=neonbasecolor
crossref(m).style.color=neonbasecolor
}

//cycle through and change individual letters to neon color
crossref(n).style.color=neontextcolor

if (n<message.length-1)
n++
else{
n=0
clearInterval(flashing)
setTimeout("beginneon()",1500)
return
}
}

function beginneon(){
if (****.all||****.getElementById)
flashing=setInterval("neon()",flashspeed)
}
beginneon()


</script>
</h2>[/align]
<table height="479">
<TD WIDTH=100 HEIGHT=475 align="center">
       		[img]Images/music3_10.gif[/img]</TD>
  <td height="475"><table width="698" height="488" border="1" bordercolor="#000000" bgcolor="#333333">
<tr>
  </p>
  

</p>
  [align=center]

</p>[/align]
  

</p>
 <hr color="#575757">
    

[b]
     [/b][url=index.html][b]Home</font>[/b][/url]
    [url=staff.html][b]Staff</font>[/b][/url]
    [url=aboutus.html][b]Game's</font>[/b][/url]
    [url=Partners.html][b]Link</font>[/b][/url]
    [url=download.html][b]Link</font>[/b][/url]
    [url=music.html][b]Link</font>[/b][/url]
    [url=contactus.html][b]Link</font>[/b][/url]</p>
  </form>
</td>
<td width="680" align="right" valign="top" height="3"><font color="#575757">
PHP CODE HERE=====================================================
</tr>
<tr>
  <td width="821" height="20">
  [img]Images/music3_01.gif[/img]
  </td>
</tr>
<tr>
           <td width="821" height="95"><marquee
onmouseover="this.stop();"
onmouseout="this.start();"
top="0" left="0"
scrollamount="6"
>

<FONT STYLE="FONT-SIZE=9px; FONT-FAMILY=Tahoma;">
[b]<a style="font-family:Verdana; font-size:10; background-color:#575757; color:#FFFFFF; border:1px solid #000000; border-style: solid; border-top-color: #FFFFFF; border-left-color: #FFFFFF; border-bottom-color: #000000; border-right-color: #000000;">[b]
[B]<FONT COlOR=lightblue>[ </FONT>[/B] <U><FONT COlOR=red>14/07/2005</FONT></U> - <FONT COlOR=blue>Site Was Started.</FONT> [B] <FONT COlOR=lightblue>[ </FONT>[/B]


[B]<FONT COlOR=lightblue>[</FONT> [/B] <U><FONT COlOR=red>27/03/2005</FONT></U> - <FONT COlOR=blue>Go Away Inless I Said U Can Come</FONT> [B]<FONT COlOR=lightblue>[ </FONT>[/B]


[B]<FONT COlOR=lightblue>[ </FONT>[/B] <U><FONT COlOR=red>24/03/2005</FONT></U> - <FONT COlOR=blue>Go Away Inless I Said U Can Come</FONT> [B] <FONT COlOR=lightblue>[ </FONT>[/B]


</FONT>

</marquee>

<a  class="tah12" style="font-family:Verdana; font-size:10; background-color:#575757; color:#FFFFFF; border:1px solid #000000; border-style: solid; border-top-color: #FFFFFF; border-left-color: #FFFFFF; border-bottom-color: #000000; border-right-color: #000000;">[b]Welcome to UnderCover Designs. This page is for a list of Staff



<a  class="tah12" style="font-family:Verdana; font-size:10; background-color:#575757; color:#FFFFFF; border:1px solid #000000; border-style: solid; border-top-color: #FFFFFF; border-left-color: #FFFFFF; border-bottom-color: #000000; border-right-color: #000000;">[b]list of Staff: UnderCover is Demon_slayers Boy Friend  So Dont Mess With Her



<a  class="tah12" style="font-family:Verdana; font-size:10; background-color:#575757; color:#FFFFFF; border:1px solid #000000; border-style: solid; border-top-color: #FFFFFF; border-left-color: #FFFFFF; border-bottom-color: #000000; border-right-color: #000000;">[b]list of Staff: UnderCoverAdmin is Soldier0todd's  Boy Friend  So Dont Mess With Her


<a  class="tah12" style="font-family:Verdana; font-size:10; background-color:#575757; color:#FFFFFF; border:1px solid #000000; border-style: solid; border-top-color: #FFFFFF; border-left-color: #FFFFFF; border-bottom-color: #000000; border-right-color: #000000;">[b]list of Staff Was Added By Soldier0todd

</script>
	  <font color="white" >
</font>
	  <font color="white" >
</font></td>
</tr>
<tr valign="top">
<td width="821" height="346">
[img]Images/music3_01.gif[/img]

  


 [list=i]
<font color=red><LI><a style="font-family:Verdana; font-size:10; background-color:#575757; color:#FFFFFF; border:1px solid #000000; border-style: solid; border-top-color: #FFFFFF; border-left-color: #FFFFFF; border-bottom-color: #000000; border-right-color: #000000;">[b]User Name: UnderCover ****: Male                   Email: [email]undercover2@undercover.thesmokylounge.com[/email] Staff Pos: Owner/Editor
[img]http://www.croolf.de/Images/a_devil_g.jpg[/img]
<LI>User Name: demon_slayer(popuri) ****: Female    Email: [email]demon_slayer@undercover.thesmokylounge.com[/email] Staff Pos: Co-owner/gfx
[img]http://i4.photobucket.com/albums/y118/witch_craft_user/tieger1dragon2.bmp[/img]
<LI>User Name: soldier0todd ****: Female Email [email]soldier0todd@undercover.thesmokylounge.com[/email] Staff Pos: What-Ever She Likes
[img]http://www.thebigcats.com/news/2003_1208_white_tiger_cubs1.jpg[/img]
<LI>User Name: UnderCoverAdmin ****: male Email [email]UnderCoverAdmin@undercover.thesmokylounge.com[/email] Staff Pos: What-Ever he Likes
[img]http://www.halloween-mask.com/Marz/vampire_demon_RC-66032mrz.jpg[/img]
[/list]


[img]flash%20projects/Business%20template/images/spacer.gif[/img]
  

  </p>
  


  

  [img]Images/music3_01.gif[/img]
  </p>
  

</p>
  [align=center]

</p>[/align]
  

</p>
 <hr color="#575757">
    

[b]
  </form>
</td>


<td width="51" align="left" valign="top" height="346"><h6></h5>
      <font color="#575757">
</table>
[align=center]
[/align]<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
 [align=center]<font color=red>Copyright&copy 2005</font>[url=""]<font color=red>UnderCover Design's[/align]</color></H2>[/url][/align]
  </table>
</body>



<?php

include 'config.php';

ob_start();
echo "[align=center]<font size\"2\" face=\"Tahoma\"> Network-13 Login System 2.0</font>[/align]
";
echo "<font face=\"Arial\">Login to the members area.
</font>
";
echo "<form action=\"./login.php\" method=\"POST\">";
echo "<font face=\"Arial\">Name: </font> 
<input type=\"text\" name=\"username\" size=\"20\">
";
echo "<font face=\"Arial\">Pass: </font> 
<input type=\"password\" name=\"password\" size=\"20\">
";
echo "<input type=\"submit\" value=\"Login!\">";
echo "</form>";
echo "
<font face=\"Times New Roman\">• </font><font face=\"Arial\">Dont have an account? Register <a href=\"register.php\">here!</a>";
echo "
• Forgot your username & password? **** <a href=\"reset.php\">here!</a>";
echo "
• Reset your password? **** <a href=\"passwordreset.php?step=1\">here!</a></font>";

$connection = @mysql_connect($hostname, $user, $pass)
or die(mysql_error());
$dbs = @mysql_select_db($database, $connection) or
die(mysql_error());

$sql = "SELECT * FROM $userstable WHERE username = '$_POST[username]' AND password = '$_POST[password]'";
$result = @mysql_query($sql,$connection) or die(mysql_error());
$num = @mysql_num_rows($result);

if ($num != 0) {
$cookie_name = "auth";
$cookie_value = "fook!$_POST[username]";
$cookie_expire = "0";
$cookie_domain = $domain;

setcookie($cookie_name, $cookie_value, $cookie_expire, "/", $cookie_domain, 0);
header ("Location: http://" . $domain  . $directory . "index.php");

ob_end_flush();

exit;
}
?>


UNDERCOVER
Posts: 115
Joined: Tue Apr 05, 2005 1:02 pm

Post by UNDERCOVER »

or can some one make it show when u login it shows the login tools were that login code is were i want it plz:D
jnjwebdev
Posts: 26
Joined: Mon Jul 25, 2005 4:38 pm
Contact:

Post by jnjwebdev »

take the exit out of the php. Exit stops the parsing of the ENTIRE file not just the php
Lixas
Posts: 750
Joined: Wed Feb 16, 2005 4:21 pm

Post by Lixas »

or you can like this:
create a form with action="login_check.php" and in than logincheck.php you can check username and password, and if everything is ok, redirect wih

Code: Select all

header("location: other_page.php")
and before that register cookie and sesion and if bad redirect user to other page that shows "wrong login name and or password"
Image
jnjwebdev
Posts: 26
Joined: Mon Jul 25, 2005 4:38 pm
Contact:

Post by jnjwebdev »

ifelse statements with sessions can allow you to create on the fly without redirecting, which reduces the number of files as well as execution time for the page
Lixas
Posts: 750
Joined: Wed Feb 16, 2005 4:21 pm

Post by Lixas »

yes, such option is available to, but i wrote simpliest way to deal with member system
Image
jnjwebdev
Posts: 26
Joined: Mon Jul 25, 2005 4:38 pm
Contact:

Post by jnjwebdev »

Yeah but sometime simple is messy and slower executing, better to learn properly so that changing coding style shouldn't have to happen later with larger applications
UNDERCOVER
Posts: 115
Joined: Tue Apr 05, 2005 1:02 pm

Post by UNDERCOVER »

nvm i justed used <? include ('w/e.php') ?>
toychoq
Posts: 108
Joined: Fri Apr 15, 2005 9:11 am

Post by toychoq »

just find line with word script
and copy it
Post Reply