Hi Guys and Gals,
I'm a graphic designer working on a website for a client, but since I've never done a website of this magnitude before, I'm needing some help with PHP - a language that I'm crash-coursing on, but I'm no where near where I need to be. I'm hoping that you'll be willing to help.
My client wants his users to pick one of three sections of the site as their home site - call them A, B and C. When they enter the site, they go to A automatically and choose one of the sections during registration. From that point on when they sign in, the template page will say something to the effect of "Welcome User to the C Network". I've created three different templates in three different folders but rather than tripling the number of pages, I've added a "php include" to the top of every page that will check the login information for the user in the database and add their template to the page.
I've started the script by stealing elements from a 'member search' script, but I lost track of my own logic; and I know it's nowhere near complete.
If this script doesn't help then please feel free to chuck it.
<?php
// Connect to database
include_once "../scripts/connect_to_mysql.php";
// DEFAULT QUERY STRING
$queryString = "WHERE email_activated='1' ORDER BY id ASC";
$sql = mysql_query("SELECT id, user_name, home_network, FROM uwnsignup $queryString");
$outputPage = '';
while($row = mysql_fetch_array($sql)){
$id = $row["id"];
$user_name = $row["user_name"];
$home_network = $row["home_network"];
$outputTemplate .= '
}
?>
Thanks in advance for even reading this post, and more so, for any help you're willing to give. I'm sure you'll have more questions about what I intend with this script, feel free to toss them at me.
Ron Gulette