Go Back   Novahq.net Forum > Computers > Web design and Programming
FAQ Community Calendar Today's Posts Search

Web design and Programming Discuss website creation and other programming topics.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-03-2004, 11:52 AM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

I think so but correct me...Test for php lol :)

<html><head><title>Welcome to DFWARSNETWORK!</title>
</head>
<body>

<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" id="AutoNumber1" height="568">
<tr>
<td width="100%" height="74">
<p align="center"><font size="7">DFWARSNETWORK</font></td>
</tr>
<tr>
<td width="100%" height="19">
<p align="center">|&nbsp; Forums&nbsp; |&nbsp; Map DB&nbsp; |&nbsp; File DB&nbsp;
|&nbsp; Squad Base&nbsp; |&nbsp; Links&nbsp; |&nbsp; About Us&nbsp; |&nbsp;
</td>
</tr>
<tr>
<td width="100%" height="473" valign="top">
<?php
$host = "localhost"
$username = "example"
$password = "example"
$db = mysql_connect("$host","$username","$password");
$result = mysql_query (select * FROM News);
mysql_select_db (newsdb,$db);
while ($myrow = $mysql_fetch_row ($result)) {
printf ("<tr><td>Title: %s :: Written by %s</td><td><p>&nbsp;</p>News story: %s");
$myrow[1], $myrow[2], $myrow[3]
}else{
Print ("No news at this time! Check back when you can!");
?>
<form method="post" action="searchresults.php">
Search: <input type="text" name="T1" size="20" style="font-size: 8pt; border-style: solid; border-width: 1"><input type="submit" value="Search" name="B1" style="font-size: 8pt; border-style: solid; border-width: 1"></p>

</td>
</tr>
</table>

</body>
</html>
Would this work to show news stories on like a front page?
Reply With Quote
  #2  
Old 08-03-2004, 12:06 PM
the þrox™ is offline the þrox™
Registered User

Join Date: Aug 2003
Posts: 3,739

Send a message via ICQ to the þrox™ Send a message via AIM to the þrox™
do you test these's codings before or do you just come here and ask if they are correct?
__________________



----------------------------------------
[Presents: ++]

Sigs Made: [29]
Reply With Quote
  #3  
Old 08-03-2004, 01:41 PM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

I can't test it
Reply With Quote
  #4  
Old 08-03-2004, 01:41 PM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

so i ask
Reply With Quote
  #5  
Old 08-03-2004, 01:50 PM
prey is offline prey
Registered User

Join Date: Mar 2004
Posts: 119

Send a message via ICQ to prey
find a way to test.

put ["php"] // code here ["/php"] (without the quotes) tags around your code.

and cut all the html. even better post the part that's producing the problem. so it's nice and simple.

right now i dont want to help you cause i dont feel like looking at unhighlighted code with html in it
__________________
http://addf.net
http://som.addf.net
http://snmservers.com
http://snmfuturedomination.com
-------------------------------------
but there it's a different movie
she stares into the screen
and fantasies enter her
harder than all those who will get to know her
Reply With Quote
  #6  
Old 08-03-2004, 04:17 PM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

PHP Code:
<?php
$host 
"localhost"
$username "example"
$password "example"
$db mysql_connect("$host","$username","$password");
$result mysql_query (select FROM News);
mysql_select_db (newsdb,$db);
while (
$myrow $mysql_fetch_row ($result)) {
printf ("<tr><td>Title: %s :: Written by %s</td><td><p> </p>News story: %s");
$myrow[1], $myrow[2], $myrow[3]
}else{
Print (
"No news at this time! Check back when you can!"); 
?>
Reply With Quote
  #7  
Old 08-03-2004, 04:18 PM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

Is there a certain color that means that's it's wrong?
Reply With Quote
  #8  
Old 08-03-2004, 04:20 PM
Steve is offline Steve
Steve's Avatar
Administrator

Join Date: Sep 2001
Location: 2077
Posts: 21,552

Send a message via ICQ to Steve
nope, it just makes it easier to look at me thinks
Reply With Quote
  #9  
Old 08-03-2004, 04:36 PM
SilentTrigger is offline SilentTrigger
-1PARA-

Join Date: Sep 2002
Location: Sweden
Posts: 3,972

As steve says, its there to make it pretty

You could set up a server on you computer to test these scripts
__________________
-1PARA-AlexKall

My photography website



Reply With Quote
  #10  
Old 08-03-2004, 04:47 PM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

how do you do that?
Reply With Quote
  #11  
Old 08-03-2004, 05:49 PM
prey is offline prey
Registered User

Join Date: Mar 2004
Posts: 119

Send a message via ICQ to prey
you querying a database before selecting one

you need to switch those two lines like this
PHP Code:
mysql_select_db (newsdb,$db); 
$result mysql_query (select FROM News); 
__________________
http://addf.net
http://som.addf.net
http://snmservers.com
http://snmfuturedomination.com
-------------------------------------
but there it's a different movie
she stares into the screen
and fantasies enter her
harder than all those who will get to know her
Reply With Quote
  #12  
Old 08-03-2004, 05:57 PM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

k
Reply With Quote
  #13  
Old 08-03-2004, 10:33 PM
IcIshoot is offline IcIshoot

Join Date: Mar 2004
Location: Farmington Hills, MI
Posts: 1,473

Send a message via AIM to IcIshoot Send a message via MSN to IcIshoot Send a message via Yahoo to IcIshoot
Quote:
Originally posted by -Elite-
I can't test it
hey, if you need a server to test it on and are able to use ftp, I can give you some space, plus a mysql database.

Just let me know

:-)

IcI
Reply With Quote
  #14  
Old 08-03-2004, 11:02 PM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

Quote:
Originally posted by icishoot
hey, if you need a server to test it on and are able to use ftp, I can give you some space, plus a mysql database.

Just let me know

:-)

IcI
Thanks man, but sadly enuff can't use ftp. But when i buy web hosting for my soon to be resource site lol i'll do all the testing there. I could learn faster if i was able to do testing.
Reply With Quote
  #15  
Old 08-03-2004, 11:28 PM
IcIshoot is offline IcIshoot

Join Date: Mar 2004
Location: Farmington Hills, MI
Posts: 1,473

Send a message via AIM to IcIshoot Send a message via MSN to IcIshoot Send a message via Yahoo to IcIshoot
I have a php program that I use for the people I host and it has a web based ftp. You don't need to use an ftp client (although it would be easier).

Any ways, just thought I would offer.

IcI
Reply With Quote
  #16  
Old 08-04-2004, 12:25 AM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

Sure if u have a web baseed thing that doesn't require ftp.
Reply With Quote
  #17  
Old 08-04-2004, 06:07 AM
Scott is offline Scott
Scott's Avatar
AKA. Panther

Join Date: Sep 2001
Location: Minneapolis, MN
Posts: 10,922

Easyphp.org
__________________

04' Dodge SRT-4, Mopar Stage 3, 406whp/436wtq
Reply With Quote
  #18  
Old 08-04-2004, 09:43 AM
JonM is offline JonM
Registered User

Join Date: Jun 2004
Posts: 2,156

thanks
Reply With Quote
  #19  
Old 08-04-2004, 05:03 PM
SilentTrigger is offline SilentTrigger
-1PARA-

Join Date: Sep 2002
Location: Sweden
Posts: 3,972

Quote:
Originally posted by -Elite-
how do you do that?
You install a program put the script in a folder and browse it, cant be easyer then that
__________________
-1PARA-AlexKall

My photography website



Reply With Quote
  #20  
Old 08-04-2004, 06:33 PM
prey is offline prey
Registered User

Join Date: Mar 2004
Posts: 119

Send a message via ICQ to prey
search google for windows apache php/mysql installation
__________________
http://addf.net
http://som.addf.net
http://snmservers.com
http://snmfuturedomination.com
-------------------------------------
but there it's a different movie
she stares into the screen
and fantasies enter her
harder than all those who will get to know her
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
TEST TEST TEST!!!!! MY SIG IS P.I.M.P. lol ShArP Sigs and Graphics 1 10-15-2007 08:36 PM
For BB/Mike a test story lol:)!!!! BADDOG General Chat 3 08-07-2005 06:35 AM
index.php?act=test&cat=5 Guest phphq.Net Forums 0 02-02-2005 04:46 PM
TEST (LOL NEW SIG AGAIN BUT ALOT OF TIME INTO IT) GFpBOND Sigs and Graphics 1 07-19-2002 03:51 PM
Anouther test LOL Blade Sigs and Graphics 0 07-17-2002 09:57 AM


All times are GMT -5. The time now is 08:40 AM.




Powered by vBulletin®