Re: [PHP-WIN] Best way to tell how many rows a query returns

2004-05-12 Thread Bobo Wieland
Do this query first to get a variable that holds the total number of rows matching your query count = mysql_result(mysql_query(SELECT COUNT(*) AS count FROM table WHERE condition, $link_id),"count"); I think this is the correct syntax... .bobo - Original Message - From: "Ross Honni

[PHP-WIN] Best way to tell how many rows a query returns

2004-05-12 Thread Ross Honniball
Hi folks, I'm using a mysql query with a LIMIT clause. The problem is I would like to know how many rows WOULD have matched had the limit clause not been in place. I realise that any solution is going to involve some over-head, but what's the most efficient way to find out? eg. SELECT * FROM

[PHP-WIN] Re:RE: [PHP-WIN] Photo gallery with description

2004-05-12 Thread Bobo Wieland
Doesn't anybody do their own thing anymore? This is so boring, uninspiring and depressing... Does any of the suggested gallery code do exactly what Lenny asked for? In my experience you always get a lot more then you want when using packages like this. And if you want to do something different with

Re: [PHP-WIN] Best way to tell how many rows a query returns

2004-05-12 Thread Svensson, B.A.T. (HKG)
> Say there are 200 records that match 'conditions', only 30 rows are > returned (of course). How do I find out the total number (200 in this case) > that matched the conditions? > > Any ideas? SELECT COUNT(*) -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http

[PHP-WIN] Photo gallery with description

2004-05-12 Thread Gryffyn, Trevor
I'm doing my own and plan to keep developing it. I feel the same way, those other scripts are really neat but they do WAY too much for what I want. The script that powers the link below is one file, no database setup (currently and I'm thinking about keeping it that way... Or making a PHP5 versio

[PHP-WIN] Problems Configuring.

2004-05-12 Thread Alejandro César Garrammone
Hi all, I've a problem configuring my php on a Windows XP OS. I do all the manual says...the Apache Server has service start and it seems it is working fine...but when the php try to connect to a mysql databases it's do nothing. Before the XP I have a W98 running perfectly with Apache, PHP and Mys

Re: [PHP-WIN] Photo gallery with description

2004-05-12 Thread Paul Menard
Trevor, So are you going to offer your gallery code for use by others? Just curious. I'm also working on my own version of gallery software. I am using Gallery (http://gallery.menalto.com/modules.php?op=modload&name=News&file=index) currently, but hate that it does not easily integrate into my s

[PHP-WIN] post TO sql routine

2004-05-12 Thread George Pitcher
Hi, Can anyone point me to a routine that will take the POST field and its value and parse it into a suitable sql query. For example: $_POST['title'] is the post var and the user has entered "*good boy +favour -witch". It should produce the following sql snippet ( to form part of the full SQL q

RE: [PHP-WIN] Photo gallery with description

2004-05-12 Thread Gryffyn, Trevor
> So are you going to offer your gallery code for use by > others? Just curious. I'm also working on > my own version of gallery software. I am using Gallery > (http://gallery.menalto.com/modules.php?op=modload&name=News&f > ile=index) currently, but hate that > it does not easily integrate into m

[PHP-WIN] Re: post TO sql routine

2004-05-12 Thread Jason Barnett
George, I haven't done this myself but you should be able to accomplish this with several preg_replace() statements. Just match from the wildcard characters you want to use and match until you find a whitespace character. http://www.php.net/preg_replace -- PHP Windows Mailing List (http://www

[PHP-WIN] Re: Problems Configuring.

2004-05-12 Thread Jason Barnett
Alejandro césar garrammone wrote: Hi all, I've a problem configuring my php on a Windows XP OS. I do all the manual says...the Apache Server has service start and it seems it is working fine...but when the php try to connect to a mysql databases it's do nothing. I'm glad to hear you read the manu

[PHP-WIN] re: photo gallery with description

2004-05-12 Thread Jonathan Pilborough
.fotopics.net Regards Jonathan Pilborough -- Please fill in my Business Questionnaire at http://www.businessq.tk -- Pupil at Haybridge High School http://www.haybridge.worcs.sch.uk - Yahoo! Messenger - Communicate instantly...

[PHP-WIN] Re: I a list of PHP 5 reserved words please!

2004-05-12 Thread Jason Barnett
Sonia, you will not have to rewrite all sections of code that use $this. However, when you try to *assign* to the variable $this then you run into problems (i.e. don't try to tell this object to change into another object). Just out of curiosity, why did you assign values directly to $this?

[PHP-WIN] Re: Windows vs. Unix - script incompatibilities?

2004-05-12 Thread Sonia Desbiens
Hi Nicki I should asked what trouble you were having, I did test the script and found many $variables are not defined. I also found that the script will not run if register_globals = Off If register_globals is 'on' it will work just fine. I am going to fix the script so that it will run with

Re: [PHP-WIN] Problems Configuring.

2004-05-12 Thread Alejandro César Garrammone
Hi Jason, the version of PHP I'm using is the 4.2.3. In the Service Manager Section of the XP the apache service is running with the description "Apache 1.3.27 with PHP 4.2.3 running" I do what you said an the phpinfo() gives me the following: System: Windows NT 5.1 build 2600 Build Date: Sep 6 2

Re: [PHP-WIN] Re: Windows vs. Unix - script incompatibilities?

2004-05-12 Thread Jordi Canals
Sonia Desbiens wrote: Hi Nicki I should asked what trouble you were having, I did test the script and found many $variables are not defined. I also found that the script will not run if register_globals = Off If register_globals is 'on' it will work just fine. I am going to fix the script so

[PHP-WIN] Re: Windows vs. Unix - script incompatibilities?

2004-05-12 Thread NSR Nicki
Sounds great, Sonia. Thanks so much! -- Nicki Sherer, Web Developer National Scouting Report Internet Department 128 Total Solutions Way Alabaster, AL 35007 Phone: 1-800-354-0072 FAX: 1-800-953-9006 "Sonia Desbiens" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi Nicki > > I s