Wygląd strony:
index.php
<?php
// zmienna potrzebna do prawidlowego wczytania includowanych plikow
$add_site = true;
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<meta http-equiv="Content-type" content="text/html; charset=iso-8859-2" />
<meta http-equiv="" />
<meta name="Author" content="" />
<head>
<title>Szablon</title>
</head>
<body>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="100%" colspan="3"><?php include "include/naglowek.php"; ?></td>
</tr>
<tr>
<td width="15%" valign="top"><?php include "include/menu_lewe.php"; ?></td>
<td width="70%" valign="top">
<?php
// zmienna $go przekazana metoda GET
$go = $_GET['go'];
// sprawdzamy czy zmienna $go nie jest pusta
// sprawdzamy czy plik o danej nazwie istnieje
if(is_file("page/$go.html")) include "page/$go.html"; // jezeli plik nie istnieje wyswietla się komunikat
else echo "<br />Nie ma takiej strony :-("; }
// jezeli zmienna $go jest pusta wyswietla się strona glowna
else include "page/start.html";
?>
</td>
<td width="15%" valign="top"><?php include "include/menu_prawe.php"; ?></td>
</tr>
<tr>
<td width="100%" colspan="3"><?php include "include/stopka.php"; ?></td>
</tr>
</table>
</body>
</html>
menu_prawe.php
<div align="center">
<?php
include "main.php";
?>
</div>
main.php
<?
/**
* Main.php
*
* This is an example of the main page of a website. Here
* users will be able to login. However, like on most sites
* the login form doesn't just have to be on the main page,
* but re-appear on subsequent pages, depending on whether
* the user has logged in or not.
*
* Written by: Jpmaster77 a.k.a. The Grandmaster of C++ (GMC)
* Last Updated: August 26, 2004
*/
include("include/session.php");
?>
<html>
<body>
<table>
<tr><td>
<?
/**
* User has already logged in, so display relavent links, including
* a link to the admin center if the user is an administrator.
*/
if($session->logged_in){
echo "Witaj <b>$session->username</b>, jesteś zalogowany w serwisie. <br><br>" ."[<a href=\"userinfo.php?user=$session->username\">Moje konto</a>] <br>"
."[<a href=\"index.php?go=useredit.php\">Edytuj konto</a>] <br>";
if($session->isAdmin()){
echo "[<a href=\"admin/admin.php\">Panel admina</a>] <br>"; }
echo "[<a href=\"process.php\">Wyloguj</a>]<br>"; }
else{
?>
<h1>Login</h1>
<?
/**
* User not logged in, display the login form.
* If user has already tried to login, but errors were
* found, display the total number of errors.
* If errors occurred, they will be displayed.
*/
if($form->num_errors > 0){
echo "<font size=\"2\" color=\"#ff0000\">".$form->num_errors." error(s) found</font>"; }
?>
<form action="process.php" method="POST">
<table align="left" border="0" cellspacing="0" cellpadding="3">
<tr><td>Login:</td><td><input type="text" name="user" maxlength="30" value="
<? echo $form->value("user"); ?>"></td><td>
<? echo $form->error("user"); ?></td></tr>
<tr><td>Hasło:</td><td><input type="password" name="pass" maxlength="30" value="
<? echo $form->value("pass"); ?>"></td><td>
<? echo $form->error("pass"); ?></td></tr>
<tr><td colspan="2" align="left"><input type="checkbox" name="remember"
<? if($form->value("remember") != ""){ echo "checked"; } ?>>
<font size="2">Zapamiętaj mnie
<input type="hidden" name="sublogin" value="1">
<input type="submit" value="Login"></td></tr>
<tr><td colspan="2" align="left"><br><font size="2">[<a href="forgotpass.php">Zapomniałeś hasło?</a>]</font></td><td align="right"></td></tr>
<tr><td colspan="2" align="left"><br>Nie zarejestrowany? <a href="register.php">Zarejestruj się!</a></td></tr>
</table>
</form>
<?
}
/**
* Just a little page footer, tells how many registered members
* there are, how many users currently logged in and viewing site,
* and how many guests viewing site. Active users are displayed,
* with link to their user information.
*/
echo "</td></tr><tr><td align=\"center\"><br><br>"; echo "<b>Zarejestrowanych ".$database->getNumMembers()." użytkowników<br>"; echo "Aktualnie $database->num_active_users użytkowników i "; echo "$database->num_active_guests gości online.<br><br>";
include("include/view_active.php");
?>
</td></tr>
</table>
</body>
</html>
I tu moje pytanie jak zrobić by po wciśnięciu "Moje konto" strona odtworzyła się w tym okienku w którym jest includowane "menu_prawe", a nie na całej stronie
Nikt nie potrafi czy po prostu zadałem głupie pytanie?
Powód edycji: [nospor]: