You are here: Re: help with very simple php problem... « PHP Programming Language « IT news, forums, messages
Re: help with very simple php problem...

Posted by Shelly on 11/14/68 11:21

"max" <nospam@nospam.com> wrote in message
news:BO5Ce.1925$B6.51988@twister1.libero.it...
> Hi, I've just started learning some stuff about php and have been
> following a couple of tutorials. At the moment I'm stuck with this small
> piece of code which gives me an error "mysql_fetch_array():supplied
> argument is not a valid MySql result"
>
> <?php
> include 'config.php';
> include 'opendb.php';
>
> $query="SELECT cname, csubject, cmessage FROM contact";
> $result=mysql_query($query);
>
> while($row= mysql_fetch_array($result,MYSQL_ASSOC))
> {
> echo
> "Name :{$row['cname']} <br>" . "Subject : {$row['csubject']} <br>" .
> "Message : {$row['cmessage']} <br><br>";
> }
> include 'closedb.php';
> ?>
>
> This should just display the content of a table..
> Thanx for your help!

Could you please show the contents of opendb.php?

Shelly

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация