For those perl fans out there, preg_match_all adds the g (global) flag to the
expression. So this:
preg_match('/foo/', $str, $match);
would be like
$str =~ /foo/;
preg_match_all('/foo/', $str, $match);
like
$str =~ /foo/g;
- Russ
p.s. - anyone coming from Perl to PHP can get a little hung
Rainer Bendig Aka Ny wrote:
I want to build an array containing two arrays $navm[] and $navs[],
$navs[] should go to $navm[items].
- -sourcecode:start8--
$resultm = $db-query(SELECT * FROM .$p._cats WHERE ms='m' \
ORDER BY sortorder ASC);
On Wednesday 24 November 2004 20:31, Mark Benson wrote:
From the above code,
Actually the above code would result in a parse error. There are no
where-loops in PHP but there are while-loops. This is not being pedantic. If
you're going to post code, make sure it's verbatim by using copy and
The real problem you're having is the statement says while there are
results in this query, grab them - once you reach the end of the first
while loop, there are no more results, so the second one is skipped
right over - it's condition *never* evaluates true.
If the query isn't changing, and
On Wednesday 24 November 2004 20:31, Mark Benson wrote:
From the above code,
Actually the above code would result in a parse error. There are no
where-loops in PHP but there are while-loops. This is not being pedantic. If
you're going to post code, make sure it's verbatim by using copy and
On Wednesday, November 24, 2004, at 02:40PM, Norland, Martin [EMAIL
PROTECTED] wrote:
The real problem you're having is the statement says while there are
results in this query, grab them - once you reach the end of the first
while loop, there are no more results, so the second one is skipped
-Original Message-
From: Mark Benson [mailto:[EMAIL PROTECTED]
The real problem you're having is the statement says while there are
results in this query, grab them - once you reach the end of the first
while loop, there are no more results, so the second one is skipped
right over -
On Wednesday 24 November 2004 23:02, Mark Benson wrote:
You want people to focus on your real problem and not on
the mistakes you made in transcribing your actual code into your post.
I actually write (rather badly it would seem!) theoretical examples
Please don't construct theoretical
Hi,
I'm sure this is a common question, so please forgive if it's been posted
before.
I have a select statement that selects records from a table:
select * from $table where host='$somename'
I then propagate a table with the returned data. My goal is to only display 30
records per page, with
Basic example: (handwritten in email client, syntax errors may exist)
if (!isset($pagenum) || $pagenum 0) { $pagenum = 0; }
$range = 30;
$start = $range*$pagenum;
$end = $start + $range;
$limit = limit $start, $end;
$query = select * from $table where host='$somename'$limit;
Then just pass the
Off the top of my head, doesn't LIMIT accept two paramters?
Can't you do:
LIMIT 30,2
That'd give you page 2 of a 30+ record result set, right?
Using that, you can pass a page # when you click next page so previous
page ends up being current page - 1 (and if that is less than 1, then
it equals
Correct - LIMIT 30,2 would show 2 records starting with the thirtieth.
thirty-first.
Sheesh, I should get outta here too - ^airhead^
- Martin Norland, Database / Web Developer, International Outreach x3257
The opinion(s) contained within this email do not necessarily represent
those of St.
I am curious about doing something simular to this... does anyone have an idea
On Wed, 24 Nov 2004 00:43:32 -0500, list 123. list wrote:
Using mySQL 4.0, I would like to know how I can code a query that will change
the value of Participants.Active from Y to N is for three or more CONSECUTIVE
On Thu, 25 Nov 2004 01:36, Mark Benson wrote:
On Wednesday, November 24, 2004, at 02:40PM, Norland, Martin
[EMAIL PROTECTED] wrote:
The real problem you're having is the statement says while there are
results in this query, grab them - once you reach the end of the first
while loop, there
On Friday 19 November 2004 07:53, Doug Finch wrote:
I have an idea that I wanted to throw out there. I have a cable ISP
plant that I am trying to help with a project. They are using Cisco
7114 UBRs to connect their cable modems with their Internet backbone -
this device assigns it a dhcp
15 matches
Mail list logo