try using this, from php manual, clive
?php
echo filetype('/etc/passwd'); // file
echo filetype('/etc/');// dir
?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
# [EMAIL PROTECTED] / 2007-01-22 23:26:06 -0800:
On Jan 22, 2007, at 10:20 PM, Chris wrote:
$basedir = '/whatever';
for($i = 0; $i count($cont); $i++) {
$fullpath = $basedir . '/' . $cont[$i];
if (is_file($fullpath)) {
.
}
Ok, I hope I can get this to work. The code
I
# [EMAIL PROTECTED] / 2007-01-23 09:14:15 +:
readdir() returns only a basename, you need to be in
the directory you're traversing (opendir(.) or
opendir($dir); chdir($dir))
... or prefix the basenames with the path you used in the
opendir() call.
--
How many Vietnam vets does it take to
Brandon Bearden wrote:
What I WANT to see is something like this
DVD ID | TITLE | GENRE 1 | GENRE 2 | GENRE 3 | ACT |
QTY BCK |HLD | INC | OG USR | OUT DATE | OUT USR | IN DATE |
IN USR CY
GENRE: ACTION - 1 TITLES
20860023 | Movie name | ACTION | | | 1
On h, 2007-01-22 at 22:53 -0800, Jim Lucas wrote:
Don wrote:
I have a db field that contains zip codes separated by comas.
I am trying to get php to return all of the rows that contain a particular
zip code.
$query = SELECT * FROM info WHERE MATCH (partialZIP) AGAINST
On 1/23/07, Németh Zoltán [EMAIL PROTECTED] wrote:
On h, 2007-01-22 at 22:53 -0800, Jim Lucas wrote:
Don wrote:
I have a db field that contains zip codes separated by comas.
I am trying to get php to return all of the rows that contain a particular
zip code.
$query = SELECT *
On k, 2007-01-23 at 19:46 +1100, chris smith wrote:
On 1/23/07, Németh Zoltán [EMAIL PROTECTED] wrote:
On h, 2007-01-22 at 22:53 -0800, Jim Lucas wrote:
Don wrote:
I have a db field that contains zip codes separated by comas.
I am trying to get php to return all of the rows that
Németh Zoltán wrote:
On k, 2007-01-23 at 19:46 +1100, chris smith wrote:
On 1/23/07, Németh Zoltán [EMAIL PROTECTED] wrote:
On h, 2007-01-22 at 22:53 -0800, Jim Lucas wrote:
Don wrote:
I have a db field that contains zip codes separated by comas.
I am trying to get php to return all of the
On k, 2007-01-23 at 00:58 -0800, Jim Lucas wrote:
Németh Zoltán wrote:
On k, 2007-01-23 at 19:46 +1100, chris smith wrote:
On 1/23/07, Németh Zoltán [EMAIL PROTECTED] wrote:
On h, 2007-01-22 at 22:53 -0800, Jim Lucas wrote:
Don wrote:
I have a db field that contains zip codes separated
On 1/23/07, Jim Lucas [EMAIL PROTECTED] wrote:
Németh Zoltán wrote:
On k, 2007-01-23 at 19:46 +1100, chris smith wrote:
On 1/23/07, Németh Zoltán [EMAIL PROTECTED] wrote:
On h, 2007-01-22 at 22:53 -0800, Jim Lucas wrote:
Don wrote:
I have a db field that contains zip codes separated by
Jochem Maas wrote:
rewrite 'section/addfriend/will' -
'index.php?cmd=section/addfriendusername=will'
rewrite 'section/addfriend/templates/js/jquery.js' -
'index.php?cmd=section/addfriendusername=templates/js/jquery.js'
and what's the bet that this second rewritten url is the bogey man here.
-Original Message-
From: Aaron Axelsen [mailto:[EMAIL PROTECTED]
Sent: 23 January 2007 06:12
To: php-general@lists.php.net
Subject: [PHP] using return in include files
I'm trying to figure out what the desired behavior is of using the
return function to bail out of an include page.
I
2007/1/22, Beauford [EMAIL PROTECTED]:
... much blah blah blah ...
I've probably read 100 pages on this, and no matter what I try it doesn't
work. Including all of what you suggested above - is my PHP possessed?
if(preg_match(/[EMAIL PROTECTED]()*;:_.'/\\ ]+$/, $string)) { gives me
this
# [EMAIL PROTECTED] / 2007-01-23 09:52:17 -0300:
2007/1/22, Beauford [EMAIL PROTECTED]:
PS: Will we be risking going the perl way if we ask that PHP supported
regular expressions natively (I mean: without having to provide them as
strings)?
Yes. I don't know about other people's objections
I need to create some webservices for our web app and am really torn as to
which route to go...SOAP, XML_RPC, etc.? I like the looks of REST but many
of our partners that will be using our services use cold fusion and I think
that has build in SOAP support.
Which protocol would you use?
At 1/23/2007 04:52 AM, Martin Alterisio wrote:
if (preg_match('/[EMAIL PROTECTED]()*;:_.'\\/ ]+$/', $string))
Close but no cigar. Because you're using apostrophe to quote the
expression, PHP interprets the apostrophe inside the character class
as ending the quoted expressions and
if (preg_match('/[EMAIL PROTECTED]()*;:_.'\\/ ]+$/', $string))
Use single quotes and double back-slashes. PHP strings also
have escape sequences that use the back-slash as escape
character, that's why you have to double them. And single
quotes to avoid the $ character interpreted
Roman,
On 23/1/2007, Roman Neuhauser [EMAIL PROTECTED] wrote:
KEYLIST := keylist.txt
DEPS := $(wildcard *.txt)
FILES := *.txt
$(KEYLIST): $(DEPS)
grep ^keywords $(FILES) $@
Why is it so roundabout about $(DEPS)/$(FILES)? The target *actuall*
depends on different files than those declared
I am using this to connect remotely but I get a no database selected error.
The table is contacts but there is not a parameter for database name
according to the documentation. How do I delect my database when conencting
this way?
$link = mysql_connect('.org:3306', 'my_username',
mysql_select_db
[snip]
I am using this to connect remotely but I get a no database selected
error.
The table is contacts but there is not a parameter for database name
according to the documentation. How do I delect my database when
conencting
this way?
[/snip]
You need to escape that forward slash in the character class:
preg_match(/[EMAIL PROTECTED]()*;:_.'\/
Also, you've got only two backslashes in your char class. PHP is
reducing this to a single backslash before the space character. I
think you intend this to be two
This may be more of a mysql issue, but I am using php for my app so here
goes...
I have a fee field in the database, and when users post events they can
specify entrance fee in £. In some, not all, of the fields I am getting, for
example, £7 rather than £. Is this an encoding issue?
Many
if (preg_match('/[EMAIL PROTECTED]()*;:_.'\\/ ]+$/', $string))
Here is my rendition of what I think you are looking for.
$str = 'tab()/space( )/[EMAIL PROTECTED]*();:...';
if ( preg_match('|[EMAIL PROTECTED]*();:_. /\t-]+$|', $str) ) {
echo 'success';
} else {
Beauford wrote:
You need to escape that forward slash in the character class:
preg_match(/[EMAIL PROTECTED]()*;:_.'\/
Also, you've got only two backslashes in your char class. PHP is
reducing this to a single backslash before the space character. I
think you intend this to be
At 1/23/2007 09:50 AM, Beauford wrote:
preg_match(/[EMAIL PROTECTED]()*;:_.'\/ ]+$/, $string)
On top of this, every time a ' is entered it gets preceded by \. If I just
check for the characters like below that doesn't happen. Totally confused.
if(preg_match(/^[-A-Za-z0-9_.' ]+$/,
Gerry D escreveu:
I need PHP to find out if a jpeg file uses progressive encoding. None
of the standard exif or image functions seem to be able to tell me
that. (please correct me if I'm wrong)
Can anybody help me?
TIA
Gerry
http://www.jpeg.org/
--
zerof
http://www.educar.pro.br/
Apache -
Howdy ladies and gents:
For the past 9 or so years, with one email account or another, I have
been subscribed to the PHP General Mailing List. Well, life an work
have succeeded in taking up all of my time, and the only thing I've been
able to do with this list over the past year or so is
Hi everyone,
Hopefully you all can help! I¹m at a loss as to what to do next. I¹m
running PHP 5.1.2 with Apache 2.0.55 on RedHat ES4 and I keep getting the
following PHP error when trying to upload a larger file. I have
AllowOverride turned on in the httpd.conf file so my .htaccess file
Hi everyone,
Hopefully you all can help! I¹m at a loss as to what to do next. I¹m
running PHP 5.1.2 with Apache 2.0.55 on RedHat ES4 and I keep getting the
following PHP error when trying to upload a larger file. I have
AllowOverride turned on in the httpd.conf file so my .htaccess file
I'm working with my host to resolve why I am getting these error
messages, but in the meantime, I am getting this message on the website:
Warning: mysql_connect(): Too many connections in /path/number/user/
code/connect.php on line 10
Sorry: Could not connect to database. Please contact the
@, or ask your hoster to disable display_errors
t
The questions is, since I don't have error reporting turned on, why am
I getting an error message that includes the complete path to my
connect script something I would like to not be telling the
general public? Is there a way to
Best wishes John! We'll hold the fort and keep fighting the good fight in your
absence. :)
Good luck to ya!
-TG
= = = Original message = = =
Howdy ladies and gents:
For the past 9 or so years, with one email account or another, I have
been subscribed to the PHP General Mailing List.
[snip]
...damned sappy stuff...
[/snip]
Later gator, we're going to miss your pseudo-Cajun self!
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Who's John Nichel?
;)
FYI, for the noobs, the John and Jason referenced in the email are John
Holmes and Jason Wong.
Cheers,
Rob.
On Tue, 2007-01-23 at 14:45 -0500, John Nichel wrote:
Howdy ladies and gents:
For the past 9 or so years, with one email account or another, I have
been
At 5:55 PM + 1/23/07, Dave Goodchild wrote:
This may be more of a mysql issue, but I am using php for my app so here
goes...
I have a fee field in the database, and when users post events they can
specify entrance fee in £. In some, not all, of the fields I am getting, for
example, £7
At 2:45 PM -0500 1/23/07, John Nichel wrote:
Howdy ladies and gents:
For the past 9 or so years, with one email account or another, I
have been subscribed to the PHP General Mailing List. Well, life an
work have succeeded in taking up all of my time, and the only thing
I've been able to
Just installed apache and am looking at an error
Warning: session_start() [function.session-start]:
open(C:\DOCUME~1\Ross\LOCALS~1\Temp\php\upload\sess_ob822kp9sqlndjvu089r845e50,
O_RDWR) failed: No such file or directory (2) in
C:\Apache\Apache2\htdocs\ssn\editor.php on line 4
Should I set
On Tuesday 23 January 2007 11:55 am, Dave Goodchild wrote:
This may be more of a mysql issue, but I am using php for my app so here
goes...
I have a fee field in the database, and when users post events they can
specify entrance fee in £. In some, not all, of the fields I am getting,
for
Pintér Tibor wrote:
@, or ask your hoster to disable display_errors
That can be done in the script ;)
ini_set('display_errors', false);
--
Postgresql php tutorials
http://www.designmagick.com/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
Ross wrote:
Just installed apache and am looking at an error
Warning: session_start() [function.session-start]:
open(C:\DOCUME~1\Ross\LOCALS~1\Temp\php\upload\sess_ob822kp9sqlndjvu089r845e50,
O_RDWR) failed: No such file or directory (2) in
C:\Apache\Apache2\htdocs\ssn\editor.php on line 4
Chris írta:
Pintér Tibor wrote:
@, or ask your hoster to disable display_errors
That can be done in the script ;)
ini_set('display_errors', false);
Sure it can, but its a lame host that enables displaying of errors by
default, thats why I advised to ask them to disable it globally :)
On Jan 22, 2007, at 11:18 PM, clive wrote:
everything without an extension is a directory
You will notice that the only directory detected
by this code is templates. There are no files
detected by this code. Does this have something
to do with stat cache? I want to make one array
with
You don't need to escape the apostrophe if the pattern isn't
quoted with apostrophes in PHP or delimited by apostrophes in
the PREG pattern. But generally there's no harm in escaping
characters unnecessarily; it just makes for messier code.
Here is a simple test of the regexp I
Hey all,
I have a requirement to take a large amount of
text, a story submitted to a competition, and
split into displayable chunks of 600 words each.
I'd like some feedback on the best way to this.
Thanks!
Skip
--
Skip Evans
Big Sky Penguin, LLC
61 W Broadway
Butte, Montana 59701
John Nichel wrote:
I'm just popping in now to let y'all know that I'm off to join
people like John and Jason in the world of, what ever happened
to him.
Thanks for your contributions over the years, John.
Chris
--
Chris Shiflett
http://shiflett.org/
--
PHP General Mailing List
At 1/23/2007 05:52 PM, Skip Evans wrote:
I have a requirement to take a large amount of text, a story
submitted to a competition, and split into displayable chunks of 600
words each.
You can explode a text into an array of words, slice off a
600-element array, and implode the result back
[snip]
I have a requirement to take a large amount of
text, a story submitted to a competition, and
split into displayable chunks of 600 words each.
I'd like some feedback on the best way to this.
[/snip]
There are many ways to skin this cat Skip but you can start with the
basics of using
So many old faces leaving... Feels odd
Respectfully,
Ligaya Turmelle
Systems Analyst
Guamcell Communications
Phone: (671)689-2377
-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 24, 2007 5:45 AM
To: PHP Mailing Lists
Subject: [PHP] OT - Leaving
I have been using the below function successfully. Hope it works for you.
-- Anas
// textwrap 1.1 Brian Moon [EMAIL PROTECTED]
// This code is part of the Phorum project http://phorum.org
// $String The string to be wrapped.
// $breaksAt How many characters each line should be.
//
Dear All,
I m new in this Forum. I m making a project in which i need to show user a
Browse Folder Dialog Box, In which he can select a folder and after this i
will do some manipulation on that folder's content. So the problem is that i
could not found any sample on Web , how to show Folder
On Tue, January 23, 2007 7:59 am, blackwater dev wrote:
I need to create some webservices for our web app and am really torn
as to
which route to go...SOAP, XML_RPC, etc.? I like the looks of REST but
many
of our partners that will be using our services use cold fusion and I
think
that has
On Tue, January 23, 2007 12:03 am, jekillen wrote:
Hello php developers:
I am having a problem with the following code:
OS: FreeBSD v6.0
Apache 1.3.34
php 5.1.2
- $cont is an array produced from opening and reading a
directory:
for($i = 0; $i count($cont); $i++)
{
print
On Mon, January 22, 2007 10:11 pm, Aaron Axelsen wrote:
I'm trying to figure out what the desired behavior is of using the
return function to bail out of an include page.
I did some testing, and this is what I concluded.
First, I created the following file:
?php
if
On Mon, January 22, 2007 9:46 pm, Gerry D wrote:
I need PHP to find out if a jpeg file uses progressive encoding. None
of the standard exif or image functions seem to be able to tell me
that. (please correct me if I'm wrong)
I don't know of any function, and the ever-populare
On Mon, January 22, 2007 5:45 pm, [EMAIL PROTECTED] wrote:
Here's a simple makefile I want PHP's exec to execute make on:
KEYLIST := keylist.txt
DEPS := $(wildcard *.txt)
FILES := *.txt
$(KEYLIST): $(DEPS)
grep ^keywords $(FILES) $@
now when I use make from command line, it works as
On Tue, January 23, 2007 1:48 pm, Jay Paulson wrote:
php_value memory_limit 40M
php_value post_max_size 30M
php_value upload_max_filesize 30M
php_value display_errors On
php_value max_execution_time 300
php_value max_input_time 300
I *think* PHP (used to?) take the MINIMUM of the php.ini
On Mon, January 22, 2007 9:17 am, Marcelo Ferrufino Murillo wrote:
Hi guys, I´m beginner in php, so I need some help. I have to make a
script to send SMS to moviles phones, can you give some ideas how to
make it please... Thank you
Another option is to partner with a gateway such as mQube to
On Sat, January 20, 2007 6:54 pm, Vinicius C Silva wrote:
hi everyone!
i'd like to ask something maybe commonly asked here. what is the most
powerful php editor?
vi on a Crey.
:-)
--
Some people have a gift link here.
Know what I want?
I want you to buy a CD from some starving artist.
Thanks all.
**
As far as I know is_dir and is_file require a full path , ...
This did the trick. I kind of assumed that the path info would be
understood by is_file() and is_dir().
But explicitly adding the path info solved the problem.
Now I have a beautiful array with 38 items just as I
On k, 2007-01-23 at 00:58 -0800, Jim Lucas wrote:
Németh Zoltán wrote:
On k, 2007-01-23 at 19:46 +1100, chris smith wrote:
On 1/23/07, Németh Zoltán [EMAIL PROTECTED] wrote:
On h, 2007-01-22 at 22:53 -0800, Jim Lucas wrote:
Don wrote:
I have a db field that contains zip codes separated
I appreciate all the input. I would definitely like to use a separate table
for the zips, but I cannot figure out how make the form that stores them
user friendly each entry can have any number of zips - from many to just
a few.
Also, the site is in development, so there is no existing
Aslam Bari wrote:
Dear All,
I m new in this Forum. I m making a project in which i need to show user a
Browse Folder Dialog Box, In which he can select a folder and after this i
will do some manipulation on that folder's content. So the problem is that i
could not found any sample on Web , how to
On Wednesday 24 January 2007 07:32, Travis Doherty wrote:
Aslam Bari wrote:
Dear All,
I m new in this Forum. I m making a project in which i need to show user a
Browse Folder Dialog Box, In which he can select a folder and after this i
will do some manipulation on that folder's content. So
Anas Mughal wrote:
I have been using the below function successfully. Hope it works for you.
-- Anas
// textwrap 1.1 Brian Moon [EMAIL PROTECTED]
// This code is part of the Phorum project http://phorum.org
// $String The string to be wrapped.
// $breaksAt How many characters each
Børge Holen wrote:
On Wednesday 24 January 2007 07:32, Travis Doherty wrote:
Aslam Bari wrote:
Dear All,
I m new in this Forum. I m making a project in which i need to show user a
Browse Folder Dialog Box, In which he can select a folder and after this i
will do some manipulation on
Hello,
Just a minute. I know the php script will run on server. Suppose i m working
on server machine and i need to make a project for myself. The machine is
only one and same. Also there are a lot of file and directory methods
available in PHP, Whats that? Actually i want to show the files of
I appreciate all the input. I would definitely like to use a separate
table
for the zips, but I cannot figure out how make the form that stores them
user friendly each entry can have any number of zips - from many to
just
a few.
Also, the site is in development, so there is no
Aslam Bari wrote:
Hello,
Just a minute. I know the php script will run on server. Suppose i m working
on server machine and i need to make a project for myself. The machine is
only one and same. Also there are a lot of file and directory methods
available in PHP, Whats that? Actually i want to
At 1/23/2007 05:52 PM, Skip Evans wrote:
I have a requirement to take a large amount of text, a story
submitted to a competition, and split into displayable chunks of 600
words each.
At 1/23/2007 07:20 PM, Anas Mughal wrote:
// textwrap 1.1 Brian Moon [EMAIL PROTECTED]
// This code is part
70 matches
Mail list logo