PHP - Moved: Rewriting Site.com/section.php?username=xyz To Site.com/xyz/section
This topic has been moved to mod_rewrite.
http://www.phpfreaks.com/forums/index.php?topic=318858.0 Similar TutorialsHello, I've just made a News system for a website i've been working on using, It has all been going fine-and-dandy. Until... My boss has asked me to add in a simple Login feature so people don't have to type there names in every form they fill-out when they use the website, My major problem is I can't get the news field to display the Login "Username" in the news, It's kind of a head-ache. (This is all for an intranet site). Sorry for the super long-ness in the post, just not sure where to look first to fix this problem :S. Please let me know if any other information is needed. Thanks! Login: Code: [Select] <?php include 'header.php'; ?> <form name="form1" method="post" action="checklogin.php"> <table id="formcss"> <tr> <td colspan="3"><strong>Member Login </strong></td> </tr> <tr> <td width="78">Username</td> <td width="6">:</td> <td width="294"><input name="myusername" type="text" id="myusername"></td> </tr> <tr> <td>Password</td> <td>:</td> <td><input name="mypassword" type="text" id="mypassword"></td> </tr> <tr> <td> </td> <td> </td> <td><input type="submit" name="Submit" value="Login"></td> </tr> </table> </td> </form> <?php include 'footer.php'; ?> check login Code: [Select] <?php include 'header.php'; ?> <?php $host="localhost"; // Host name $username="root"; // Mysql username $password=""; // Mysql password $db_name="test"; // Database name $tbl_name="admins"; // Table name // Connect to server and select databse. mysql_connect("$host", "$username", "$password")or die("cannot connect"); mysql_select_db("$db_name")or die("cannot select DB"); // username and password sent from form $myusername=$_POST['myusername']; $mypassword=$_POST['mypassword']; // To protect MySQL injection (more detail about MySQL injection) $myusername = stripslashes($myusername); $mypassword = stripslashes($mypassword); $myusername = mysql_real_escape_string($myusername); $mypassword = mysql_real_escape_string($mypassword); $sql="SELECT * FROM $tbl_name WHERE username='$myusername' and password='$mypassword'"; $result=mysql_query($sql); // Mysql_num_row is counting table row $count=mysql_num_rows($result); // If result matched $myusername and $mypassword, table row must be 1 row if($count==1){ // Register $myusername, $mypassword and redirect to file "login_success.php" session_register("myusername"); session_register("mypassword"); header("location:login_success.php"); } else { echo "Wrong Username or Password<p>"; echo "</p><a href=http://nrsdiskstation/login.php>Go Back</a>"; } ?> <?php include 'footer.php'; ?> News Code: [Select] <?php $host="localhost"; // Host name $username="root"; // Mysql username $password=""; // Mysql password $db_name="test"; // Database name $tbl_name="admin"; // Table name // Connect to server and select database. mysql_connect("$host", "$username", "$password")or die("cannot connect"); mysql_select_db("$db_name")or die("cannot select DB"); // get value of id that sent from address bar $id=$_GET['id']; "SELECT column_name1, column_name2 FROM table_name"; // Retrieve data from database $sql="SELECT * FROM $tbl_name WHERE id='$id'"; $result=mysql_query($sql); $rows=mysql_fetch_array($result); ?> <?php include 'header.php'; ?> <form name="form1" method="post" action="news_ac.php"> <table id="formcss" width="100%" border="0" cellspacing="1" cellpadding="3" align="center"> <tr> <td colspan="2" align="center"><strong>New News</strong></td> </tr> <tr> <td width="71">Title</td> <td width="301"><input name="title" type="text" id="title"></td> </tr> <tr> <td>News Type</td> <td> <select name="picture" id="picture"> <option value="">None</option> <option value="<img src=http://nrsdiskstation/Images/urgent.png align=right valign=top>">Attention</option> <option value="<img src=http://nrsdiskstation/Images/about.png align=right valign=top>">About</option> <option value="<img src=http://nrsdiskstation/Images/dots.png align=right valign=top>">Information</option> </select> </td> </tr> <tr> <td>News</td> <td> <textarea rows="4" cols="33" name="news"></textarea> </td> </tr> <input name="date" type="hidden" id="date" value="<?php echo date('g:i - d/m/Y'); ?>"> <input name="byuser" type="hidden" id="byuser" value="<? echo $rows['myusername']; ?>"> <tr> <td colspan="2" align="center"><input type="submit" name="Submit" value="Submit"></td> </tr> </table> </form> <?php include 'footer.php'; ?> News_Ac Code: [Select] <?php include 'header.php'; ?> <?php $host="localhost"; // Host name $username="root"; // Mysql username $password=""; // Mysql password $db_name="test"; // Database name $tbl_name="News"; // Table name // Connect to server and select database. mysql_connect("$host", "$username", "$password")or die("cannot connect"); mysql_select_db("$db_name")or die("cannot select DB"); // Get values from form $title=$_POST['title']; $news=$_POST['news']; $byuser=$_POST['byuser']; $picture=$_POST['picture']; $date=$_POST['date']; // Insert data into mysql $data_no=$_GET['id']; $sql="INSERT INTO $tbl_name(`title`, `news`, `byuser`, `picture`, `date`)VALUES('$title', '$news', '$byuser', '$picture', '$date')"; $result=mysql_query($sql); // if successfully insert data into database, displays message "Successful". if($result) { echo "Successful<BR><a href='index.php'>Back to Index</a>"; } else { echo "ERROR 1<br>"; echo "Query: {$sql}<br>\n"; echo "Error: " . mysql_error(); } ?> <?php include 'footer.php'; ?> News display: Code: [Select] <?php include 'header.php'; ?> <strong>Intranet System </strong> <a href="http://nrsdiskstation/news.php">(Post new news)</a><br> <?php $host="localhost"; // Host name $username="root"; // Mysql username $password=""; // Mysql password $db_name="test"; // Database name $tbl_name="News"; // Table name // Connect to server and select database. mysql_connect("$host", "$username", "$password")or die("cannot connect"); mysql_select_db("$db_name")or die("cannot select DB"); // Retrieve data from database $sql="SELECT * FROM $tbl_name"; $result=mysql_query($sql); // Start looping rows in mysql database. while($rows=mysql_fetch_array($result)){ ?> <table id="formcss" align="center"> <tr><Td> <strong><? echo $rows['title']; ?></strong> </td></tr> <tr><td> <? echo $rows['picture']; ?> <? echo $rows['news']; ?> </tr></td> <tr><td align="right"> <h6><? echo $rows['byuser']; ?> @ <? echo $rows['date']; ?><br><a href="news_update.php?id=<? echo $rows['id']; ?>">edit</a> last edited on: <? echo $rows['editdate']; ?></h6> </td></td> </table> <br><br><br> <? // close while loop } // close connection mysql_close(); ?> <?php include 'footer.php'; ?> Not sure where to start, and it may not be entirely PHP. I am helping a friend with a small social network (5,000 users). They want to add a feature where each user gets given their own email account in the format username@domain.com with domain.com being the domain of the social network. Is this too much? I've never thought of anything like this before. How would we create the email accounts? Can PHP do it? Would it be an API through the web host / email space provider? Hi php freaks I've been learning php, but what confuses me are the arrays. I have ini file, i want to get the data from file and add it to the database. Every section makes a new table and all they keys are added with their values. I figured out how to get the keys and how to see the values, but how can i get the name of the sections. Furthermore, how do i know what keys belong to what section. I am really grateful for person who helps me to realize how to be a good friend with those complicated arrays. Hey guys so I am making an App website and somehow need to make a developer section. So like developers can come and setup their app name,description etc. Then be able to program there own app and use like an API service to get the user username etc. So what would I need to let developers do a such thing like let them make an API key and all that is there some tutorial to make such service. (This will be an important feature to my website so please help, thanks)
Can i open a pdf within a page? e.g. within <td> or <table> of htmls so that it appears on a section of a page where someone can just read through and still able to browse the web page. I dont want the PDF downloading or taking the whole page or even opening a new window and filling it. Thanks in advance. Hi! I'd like to echo a text section from pageB.php to pageA.php Is it possible to mark it up somehow and tell the browser to echo the variable? I'm thinking something like this should work after some alteration: pageA: <?php echo pageb.php/variable; ?> pageB: <?php $variable = ***the content section I want to be displayed on pageA*** "; ?> I'd be very grateful if someone could help me out. (: Hi, first of all I am trying to do a section hidden from guests on a website. I have groups for each user (groups_admin, _mod, _member etc.)
I have it so ADMIN only view content at the moment, but not sure how to add GROUPS_MOD & GROUPS_MEMBER:
<?php echo $user_data['group_id'] == GROUPS_ADMIN ? 'content' : ''; ?>Secondly, where the content section is, I have HTML placed inside it which works fine, but it also has some PHP code. How would I get it so the php code works? This is what I have... <?php echo $user_data['group_id'] == GROUPS_ADMIN ? '<form method="post" action="<?php echo get_url(\'/products/\', $product[\'category_id\'], $product[\'product_id\'], $product[\'product_name\']); ?>?action=review">' : ''; ?>As you can see the form action line has a php url to generate the relevant link for a specific product. If anyone has any suggestions or can help in any way that would be much appreictaed. Cheers, Paul I think it would be interesting and useful to many to make a do and don't section or pinned post for most sections.
Editable by admins and mods to keep organized
Like the phpfreaks bible of coding, best practices.
A lot of members post some valuable information that gets lost old posts or too hard to search for.
Everyone repeating themselves on bad practices or deprecated code, turning on error reporting and such.
I don't even really know how to title it. I have this piece of code, i wrote. it works with wordpress api but honestly i don't think that matters much. what it does, is pick $ci number of categories, and then picks 2 posts from each category. it then assigns the image in/attached to that post to an array, to be used later. this all works fine, the problem is when it picks a post that doesn't have an image. right now, it can't tell that. writing in a bit to be able to tell whether there is an image or not should be easy. i'm thinking it can be as basic as file_exists or as complicated as parsing the post. the part i have the problem with - is how do i make it go back and pick another post/category when it comes up short? more than once? i want it to keep going back until it comes up with an image. i'd rather not expand the search any farther than necessary Code: [Select] <?php if ( false === ( $scroller = get_transient( $stransient ) ) ) { if (!is_array($scroller) || count($scroller)==0) { $args = array( 'type' => 'post', 'parent' => 18, 'exclude' => 63, 149, 278, 62 ); $companies = get_categories( $args ); while (count($companies) > $ci){unset($companies[array_rand($companies)]);} shuffle($companies);$truckco= array(); foreach ($companies as $company){ $argus = array('numberposts' => 2, 'orderby' => 'rand', 'post_type' => 'post', 'category' => $company->cat_ID ); $listings = get_posts($argus); foreach($listings as $tn=>$post) { $truckco[$company->slug]['truck_'. $tn]['image'] = get_the_image( array( 'image_scan' => true, 'format' => 'array', 'width' => '172', 'height' => '129' ) ); $truckco[$company->slug]['truck_'. $tn]['pid'] = $post->ID; } } ?> thank you I'm working on the following assignment and keep coming up with error messages.
"Warning: require(mysqli_connect_registrar.php): failed to open stream: No such file or directory in /home/students/r/b.richards/public_html/cis231/labs/sectionresults.php on line 3 I've included the code I have and any help would be appreciated. Thank you. Assignment Directions: Introduction This lab will demonstrate how to create a dynamic form that is created from database contents. And then that form will be used to pull results from the database, based on the user's selection.
STEP 1 - Create the Database Connection File In your labs directory, define a mysql_connect.php file for the registrar database (with the student | student credentials).
STEP 2 - Create the Form Define the form as sectionsearch.php. Create a dynamic form with a drop-down menu listing available courses by title. (Note: the courseID will be the value that is posted to the results page.)
Step 3 - Create the Results page Define the results page as sectionresults.php. Present the results of the query for sections (unless there are none—then show an appropriate message). If there are results, use an HTML table (dynamically-generated) to display available sections with the following information: Faculty last name Room number Class meeting day(s) Start time End time The information should be sorted by the faculty member's last name. Note: You will need to consult the structure of the database tables to determine which fields need to be drawn from which tables and how to join the appropriate tables needed for the query. Sectionsearch.php code:
<!doctype html>
<head> <body>
<form id="form1" name="form1" method="post" action="sectionresults.php">
<p>Courses
<p>
</form> mysql_connect.php code:
<!doctype html>
//Set database connection information
//Database connection
//Set the encoding sectionresults.php code:
<?php
$cat = "";
$q = "SELECT lastame, FROM faculty WHERE registrar = $cat ORDER BY lastname ASC"; Hello. Well I haven't any code for this, but its only a question. Do you think it would be possible for PHP, to make and image or draw one from just a blank JPG. Then placing text on the image. That is possible and quite simple. But do you think it is possible to say. Say if you have 3 different set of texts on the image. Click here for 1 Click here for 2 Click here for 3 And also for the script to link those text to different web addresses. But all still workable with a dynamic signature EG [ img ] [ / img ] Basically its a dynamic signature with links on it is what i am trying to say. Do you think its possible? Or am I thinking to big. hi i have got the following issues i am using the following code. Code: [Select] <?php //DB CONNECTION $ROWS = "id,firstname,lastname"; // explode at the comma and insert into an array $test = explode("," , $ROWS); //adds array test to the var sam $sam = array($test); // querys the database $new = mysql_query("SELECT * FROM {$DB_TABLE}"); // while loop to loop through selected fields while ($row = mysql_fetch_array($new)) { foreach ($sam[0] as $v) { echo $row[$v] . $DELIMITER . "<br />"; } } ?> i get the following results. 834(|) Steph(|) Thompson(|) 835(|) Lucy(|) kim(|) 836(|) Iwan(|) Will(|) 837(|) Sarah (|) Good(|) The problem i have is the br tag where do i put it because i need it to output like this. like it shows in the $ROWS variable above "$ROWS = "id,firstname,lastname";"; 834(|)Step(|)Thompson(|) 835(|)Lucy(|)kim(|) 836(|)Iwan(|)Will(|) 837(|)Sarah (|)Good(|) Where do i add the br tag??? Any Help PLease I would love to add a comment section to my music blogging site. Does anyone have some simple code that they would not mind sending me? or at least helping me with this situation? Hi, I have some queries that update some statistics in a table I have. I need these queries to run only after 15 seconds have passed however. This way if the user leaves before the 15 seconds, the queries won't run. I've tried using Sleep, however it seems to just stop all the code all together for the allotted time. There must be a way to do this. Hey everyone! Thanks for taking the time to help. I have two files..a membership area and a commenting section. I am fairly new at these subjects but I am a quick learner. First off, I need help figuring out why my "register.php" in the members area file isn't working properly, everything looks to be ok but maybe I have been working on this too long. Quite frankly I can't check and see if all of the other scripts are correct because I can't get past the "register.php". So if you all wouldn't mind helping me out on this part, I would greatly appreciate it Secondly, I have a commenting section and in the "demo.php", there is a warning that appears as follows: "Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given in C:\Program Files (x86)\EasyPHP-5.3.8.1\www\comments\demo.php on line 17 " If someone could tell me what is missing or help me figure out what to do in simple terms, I would greatly appreciate that as well. Thanks! Gene [attachment deleted by admin] Hi, I'm trying to invert a random section of an image. The only way I've thought of doing this in PHP, is to split the image up into sections using imagecopyresampled then negate one of the sections using the imagefilter IMG_FILTER_NEGATE. Then put them all back together using imagecopymerge. Now I have managed to get this working when negating the first section ($split_first), but whenever I try to negate any other section (e.g. $split_sec) nothing happens. Now I know my code doesn't randomly invert it, I'm just trying to get it to work for each section first then I'll try get that working. Below I have posted my code. Any help would be be appreciated, Thank you in advance! <?php $image=imagecreate(400, 100); $red = imagecolorallocate($image, 255, 0, 0); imagefill($image, 0, 0, $red); $split_first=imagecreate(100, 100); $split_sec=imagecreate(100, 100); $split_thir=imagecreate(100, 100); $split_four=imagecreate(100, 100); imagecopyresampled($split_first,$image,0,0,0, 0,100,100,100,100); imagecopyresampled($split_sec,$image,100,0,100,0,100,100,100,100); imagecopyresampled($split_thir,$image,200,0,200,0,100,100,100,100); imagecopyresampled($split_four,$image,300,0,300,0,100,100,100,100); imagefilter($split_sec, IMG_FILTER_NEGATE); imagecopymerge($image,$split_first,0,0,0,0,100,100,100); imagecopymerge($image,$split_sec,100,0,100,0,0,100,100); imagecopymerge($image,$split_thir,200,0,200,0,0,100,100); imagecopymerge($image,$split_thir,300,0,300,0,0,100,100); imagepng($image); imagedestroy($image); header('Content-Type: image/png'); echo $image; ?> Hello,
I am hoping to get some help with this. I want to apologize in advance as I am not a developer more of a systems admin guy. Okay guys, here is the deal. My boss has a website, which uses from my understanding Wordpress for design, but also uses PHP. Since, I am not too familiar with the general uses of PHP, I cannot explain why they are doing it that way. The website also uses MYSQL, which I would imagine works with PHP to gather data from some back end server.
The website has five tabs on the top right corner
about services resources contact us login
When you hover over these five tabs they expand and show more menus. The tab with the issue is the services tab. When you hover over it, it works as anticipated; it expands and shows our services. Upon getting on there, there are a bunch of services, which you can click on. When you first click, it works as anticipated. However, if you try to click on another service within that category, it simply does not load the page. Now if you decide to go into a different service it works, but once you try to click on another services within x category it just does not work.
I would really appreciate everyone's help on this. It would be nice to get this resolve.
I can provide you guys with the website and php scripts and codes if need be.
This is the website
http://beta.morrowco.com/
Thanks,
Jeff M
Commented in red is the code that doesn't produce anything. It is 3/4 of the way down the page.. Thanks for looking! Code: [Select] <?php error_reporting(E_ALL); ini_set("display_errors", 1); $host= ""; $db_name= ""; $db_user= ""; $db_password= ""; ob_start(); if(isset($_POST['newBidder'])) { $newBidder= isset($_POST['newBidder']) ? $_POST['newBidder'] : ''; $bidderId= $newBidder; mysql_connect("$host", "$db_user", "$db_password")or die("cannot connect to server"); mysql_select_db("$db_name")or die("cannot select DB"); $sql="SELECT * FROM bidders WHERE biddersId='$bidderId'"; $result=mysql_query($sql); // Mysql_num_row is counting table row $count=mysql_num_rows($result); // If result matched $myusername and $mypassword, table row must be 1 row if($count==0){ // Add $biddersId and redirect to anypage mysql_Query("INSERT INTO bidders (biddersId) VALUES ('$bidderId')"); header("Location: index.php"); exit(); } } //////////////////////////////////// if(isset($_POST['deleteBidder'])) { $deleteBidder= isset($_POST['deleteBidder']) ? $_POST['deleteBidder'] : ''; mysql_connect("$host", "$db_user", "$db_password")or die("cannot connect to server"); mysql_select_db("$db_name")or die("cannot select DB"); mysql_query("DELETE FROM bidders WHERE biddersId='$deleteBidder'"); header("Location: index.php"); exit(); } //////////////////////////////////// if (isset($_POST['itemDescription'], $_POST['itemPrice'], $_POST['winningBidder'], $_POST['itemQty'])) { $itemDescription= isset($_POST['itemDescription']) ? $_POST['itemDescription'] : ''; $itemPrice= isset($_POST['itemPrice']) ? $_POST['itemPrice'] : ''; $winningBidder= isset($_POST['winningBidder']) ? $_POST['winningBidder'] : ''; $itemQty= isset($_POST['itemQty']) ? $_POST['itemQty'] : ''; mysql_connect("$host", "$db_user", "$db_password")or die("cannot connect to server"); mysql_select_db("$db_name")or die("cannot select DB"); $sql="SELECT * FROM bidders WHERE biddersId='$winningBidder'"; $result=mysql_query($sql); $count=mysql_num_rows($result); // If result matched, table row must be 1 row if($count==0){ echo "That Bidder Number is NOT logged in, "; echo "would you like to set this bidder as active?"; echo " Enter 1 for NO or 2 for YES"; echo "<form action= \"process.php\" method= \"POST\">"; echo "<input type =\"text\" name= \"logUser\"/>"; echo "<input type= \"submit\" value = \"Submit\"/>"; exit(); } } $logUser= isset($_POST['logUser']) ? $_POST['logUser'] : ''; if ($logUser= '1') { header("Location: inprogress.php"); exit(); } if ($logUser= '2'){ // Add $biddersId and redirect to anypage mysql_connect("$host", "$db_user", "$db_password")or die("cannot connect to server"); mysql_select_db("$db_name")or die("cannot select DB"); mysql_Query("INSERT INTO bidders (biddersId) ////This won't add biddersid to database///////[ VALUES ('$winningBidder')"); mysql_query("INSERT INTO transactions /////This won't add details to the database either?///// VALUES('$itemDescription', '$itemPrice','$winningBidder', '$itemQty', '$totalPrice')") or die(mysql_error()); header("Location: inprogress.php"); exit(); } //////////////////////////////////////// echo "<font color= \"red\" face=\"calibri\" size=\"4\">That bidder is already logged, Please press your browsers back button and try again.</font>"; ob_end_flush(); ?> I have one database with 2 tables as follows bidders table ONLY has biddersId field; transactions has (in order) itemDescription, itemPrice, bidderId, itemQty, totalPrice everything else works, except updating the database with the above? Am I doing something wrong in MySql. I have all eroors on , but i get NONE when running the script? im taking my ojt. i posted on different linux forums but no one replied i have php code that displays reports. and i want to add html code for UI. but it does'nt appear. i cant install xampp or anything so is there another way to run my code? help pls. hope someone can help me out here, stuck on this page... This page shows the details of the listing they had just clicked on on the previous page. this part works If the person logged in is the person who is looking at the page, the email section does not show. this part works However, the part I cannot get to work, is when the logged in user types their email message and clicks send email. at this point the details of listing stop showing please SOMEONE HELP ME thanks in advance, i hope Code: [Select] <?php // Start the session require_once('startsession.php'); // Insert the page header $page_title = 'Listing Details'; require_once('header.php'); require_once('connectvars.php'); // Show the navigation menu require_once('navmenu.php'); if(isset($_POST['submit'])){ $dbc = mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD, DB_NAME); // Retrieve the user data from MySQL $query1 = 'SELECT email FROM ob_user WHERE username="' . $user_name . '"'; $data1 = mysqli_query($dbc, $query1); $row1 = mysqli_fetch_array($data1); $email = $row1['email']; $to = $email; $subject = 'OurBazzar response to' . $subject . ''; $body = $_POST['email']; $headers = 'From: caleb.jordan.flax@gmail.com'; if (mail($to, $subject, $body, $headers)) { echo("<p>Message sent!</p>"); } else { echo("<p>Message delivery failed...</p>"); } end(); } if (isset($_GET['listing_id']) && isset($_GET['subject']) && isset($_GET['description']) && isset($_GET['price']) && isset($_GET['date']) && isset($_GET['city']) && isset($_GET['state']) && isset($_GET['user_id']) && isset($_GET['category_id'])) { // Grab the score data from the GET $listing_id = $_GET['listing_id']; $title = $_GET['subject']; $description = $_GET['description']; $price = $_GET['price']; $date = $_GET['date']; $city = $_GET['city']; $state = $_GET['state']; $userid = $_GET['user_id']; $categoryid = $_GET['category_id']; } // Connect to the database $dbc = mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD, DB_NAME); // Retrieve the user data from MySQL $query = 'SELECT username FROM ob_user WHERE user_id="' . $userid . '"'; $data = mysqli_query($dbc, $query); $row = mysqli_fetch_array($data); $query1 = 'SELECT name FROM ob_category WHERE category_id="' . $categoryid . '"'; $data1 = mysqli_query($dbc, $query1); $row1 = mysqli_fetch_array($data1); $user_name = $row['username']; $category_name = $row1['name']; echo '<table>'; echo '<tr><td colspan="2"><strong>' . $title . '</strong></td></tr>'; echo '<tr><td>Created by: </td><td>' . $user_name . '</td></tr>'; echo '<tr><td>Date created: </td><td>' . $date . '</td></tr>'; echo '<tr><td>Location: </td><td>' . $city . ', ' . $state . '</td></tr>'; echo '<tr><td>Category: </td><td>' . $category_name . '</td></tr>'; echo '<tr><td>Description: </td><td>' . $description . '</td></tr>'; echo '</table>'; if ((isset($_SESSION['username'])) && ($_SESSION['username'] != $user_name)) { ?> <br /> <form method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>"> <fieldset> <legend>Send Email to <?php echo $user_name; ?></legend> <label for="email">Message: </label> <input type="text" name="email" /><br /> <input type="submit" value="Send Email" name="submit"> </fieldset> <?php } require_once('footer.php'); ?> |