ok here is the problem i am making a website. have a look at this place
http://charlie.it.uts.edu.au/~jnsahibz/
u will be asked for a password and user name
USERNAME = www
password = rosebud
ok now when u open the page u will see one link. press it and a table will open up in the same frame where the link was.
all i want is that instead of this table being displayed in the same frame it should be displayed into the frame where i have written
" This portion will contain the listing of the selected items and there details"
when u click on the link it invokes a PHP script on the server. that PHP script is supposed to fetch all the listings in the product table from a database.
and by default it returns every thing back to the same frame or to the same page from where the user clicked on the link.
the name of the page which loads into the desired frame is upper.html
so how the hell do i make the PHP script to deliver the damn thing to the upper.html instead of the main.html page.
my php script is like this
<html xmlns= "http://www.w3.org/1999/xhtml">
<head>
<title> Assignment # 1: Online Groccery Store </title>
</head>
<?php
//build the select query
$query = "select * from products";
// CONNECT TO MY SQL
if ( !($link = mysql_connect('charlie', 'potiro', 'wR3VAT4h')))
die( " Could not connect to database" );
//open products database
if ( !mysql_select_db( "poti", $link) )
die( " Could not open prodcuts database" );
//query products database
if ( !( $result = mysql_query( $query, $link)))
{ print ( "Could not execute query!
" );
die( mysql_error() );}
?>
<h3 style = "color:blue">Search Results</h3>
<table border = "1" cellpadding = "3" cellspacing = "2" style = "background-color: #ADD8E6">
<?php
//fetch each record in result set
for ( $counter = 0;$row = mysql_fetch_row( $result ); $counter++)
{
//build the table to display the items
print( "<tr>");
foreach ( $row as $key => $value )
print( "<td>$value</td>" );
print( "</tr>" );
}
mysql_close( $link );
?>
</table>
</body>
</html>