ddwyer
Members-
Content Count
9 -
Joined
-
Last visited
Everything posted by ddwyer
-
Hello all,I am a PHP n00b. I have read the Login page post, which is over my head. I was hoping someone could explain a concept to me more in layman's terms. This is what I hope to do - I want to go to my url (http://forums.xisto.com/no_longer_exists/) and have it automatically prompt for either a username and password, or just a password. After the correct credentials are supplied, go to the regular index.html. Any help you could give me is appreciated.Thanks.
-
Cool, that may work. Let me try to explain what I am trying to do a little better. I am trying to design a new Intranet page for my company. We offer tech support to different companies, and as you could imagine every company infrastructure is different. We have a lot of information on each client like what their server names are, how to connect to them, their document management system, etc. As it sits now, along the left hand side of my page is a toolbar. In this toolbar I have a link to every one of our clients (Approx 30 of them). When you click on a particular company, I want all of their data to come up. What I was thinking may be the best thing to do is create a new table for each client. Since these different companies have such unique information, trying to make one table in SQL that has room for ALL of EVERY client's information is challenging. We have a wide variety of information for each client so making one general template seems like a daunting task.So on to what I think may be the best option. With a separate table for each client, when you click on Client XYZ on the toolbar, the page can open table XYZ which has all of that companies info. It can then run some sort of a loop to keep outputting the next field of information for _THAT_ client until it has reached the end of the table. This way I can have very different info for each client and not have to make some sort of general template that can fit every client. What do you think? Any suggestions?Dennis
-
Ok here is my next project. I will have a tabe in db2 called 'clients'. On the left side of my page, there is a list of clients. When you click on that client, I want it to pull values from db2 (clients) and fill in the body of the page. Is there a way to do this, again, without seeming to leave index.php? Below is some sample data:ClientName: Client XYZ PasswordReset: No, we cannot reset this clients passwords.RemoteAccess: To remote access this client , go to xxx.yyy.zzz.bbb IP Address.So on and so forth. But heres the catch: There is a lot of client specific data that will not fit in other clients categories, so I Was thinking of having some values called CS1 (client-specific 1) through CS10. But, another proble I am thinking of is this: All the other values will have data that I KNOW whats in there, like ClientName. I know for sure that this field will contain the client name, so in the Header before this i can put "Client Name:" and then follow with the data. With the client-specific fields, I won't know what data is about to follow so I dont know how to format my page to read the data and name the field. I dont want to have a section called "CS1:", I'd rather have a way to read in the first word or two and have this be the name of the field (is possible).Any help would be appreciated. Sorry for the lengthy post. Dennis
-
Hmm.. i enter 201 and hit go, and a blank whit page loads. with no result I put in there getarea.php and put your code in that file. Is this correct? [br]<form id="headerSearch" action="./getarea.php" method="get">[/br] <div>[br] <input class="text" type="text" value="Area Code Search"[/br] onFocus="if (this.value == 'Area Code Search') this.value=''; else this.select();"[br] onBlur="if (this.value == '') this.value='Area Code Search';" />[/br] [br] <input type="submit" class="submit" value="Go!" />[/br] </div>[br] </form>[/br]
-
Ok I am using this. I have a database called db2, and a table in db2 called 'area'. This is an example of an entry in that table: acode=201 state=NJ details: blah blah all the cities, etc. zone: Eastern Below, when you said [br]('SELECT location FROM area WHERE area ....[/br] What do I put in location? Can I echo a table of all the above variables for the query? Can I make this a popup box with the table in that? [/br]<?php[br]// insert database connection here[/br]$db = mysql_connect("localhost", "root","");[br]mysql_select_db("db2",$db);[br][/br]if(isset($_POST['area']))[/br]{[br] $result = mysql_query('SELECT location FROM area WHERE area = \''.$_POST['area'].'\'');[/br] if(mysql_num_rows($result) > 0)[br] {[/br] $row = mysql_fetch_row($result);[br] echo 'The area code you submitted is in '.$row[0].'.';[/br] } else[br] echo 'No matches were found for the area code you submitted.';[/br]}[br]?>[/br]
-
I am making a page that has a text box to do an area code lookup. Can you give me some tips to make it work? I have a text box for the area code and then a Go! button. Here is the code for the text box/button: [br]<form id="headerSearch" action="./index.html" method="get">[/br]<div>[br]<input class="text" type="text" value="Area Code Search"[/br]onFocus="if (this.value == 'Area Code Search') this.value=''; else this.select();"[br]onBlur="if (this.value == '') this.value='Area Code Search';" />[/br]<input type="submit" class="submit" value="Go!" />[br]</div>[/br]</form>[br] How can I make this work with a PHP script? Thanks![/br]Dennis
-
Hello All,I am learning PHP. I have been reading several tutorials and such but what I am wondering is this: is there a site that recomends simple project programs to practice your coding? Or can someone recommend a few programs I could write to get better. Kind of like learning it in school - after you learn it, you get an assignment to go practice it. Thanks,Dennis