php-general Digest 29 Jul 2009 18:40:02 - Issue 6256
Topics (messages 295995 through 296014):
Re: GeoIP Character Encoding
295995 by: Nisse Engström
295997 by: Nisse Engström
Re: Broken IF behavior? (Changing the branch changes the evaluation)
295996 by: Peter
Can something please show me to install Roadsend Compiler on Fedora 10.
Thank you,
J.K
On Tue, 28 Jul 2009 18:10:33 -0400, APseudoUtopia wrote:
'Portugal, 09, Vila Real De Santo António'
'Norway, 08, Ålesund'
'Portugal, 04, Vila Nova De Famalicão'
(Note the ó, Å, and ã).
I'm using PostgreSQL as my database. The database's encoding is UTF8,
and the locale is C.
When I
Matt Neimeyer wrote:
It's exactly what I would expect... The content of the row... But in
any case, what does changing the content of the { } branch have to do
with how the IF() itself is evaluated?
array(4) {
[0]=
string(8) CustName
[config]=
string(8) CustName
[1]=
On Tue, 28 Jul 2009 18:10:33 -0400, APseudoUtopia wrote:
I'm using the PECL GeoIP module on php 5.2.10. When I look up an IP
address, the geoip_record_by_name() function is giving me a string
that contains special characters, such as the following:
The PECL GeoIP page links to
tedd wrote:
Hi gang:
I have a client who is looking for a Message Board for Subscribers to
be installed on his site -- one with a good admin. Any recommendations?
Thanks,
tedd
If your request is for a forum type, then SMF is super
http://www.simplemachines.org
If the need is for a
On Jul 29, 2009, at 8:44 AM, Al wrote:
tedd wrote:
Hi gang:
I have a client who is looking for a Message Board for
Subscribers to be installed on his site -- one with a good admin.
Any recommendations?
Thanks,
tedd
If your request is for a forum type, then SMF is super
I had a tiny syntax error keeping it from working in the form of a cap letter.
On 7/28/09 3:51 PM, Miller, Terion tmil...@springfi.gannett.com wrote:
On 7/28/09 3:48 PM, Bastien Koert phps...@gmail.com wrote:
On Tue, Jul 28, 2009 at 4:02 PM, Miller,
Teriontmil...@springfi.gannett.com
Javed Khan wrote:
Can something please show me to install Roadsend Compiler on Fedora 10.
Thank you,
J.K
Why don't you look at Roadsend for the question.
http://code.roadsend.com/pcc/wiki/BuildInstructions
The PHP mailing list is not a support group for Roadsend.
If you need
Ok in my output to Quark I need to have $P printed to the page like this:
@$p2118 S. Campbell Ave
So in my php which is going to be grabbing this info and formatting it for
the Quarkisn't echoing that $p all I get is the @
I have tried several things:
$p = $p
$p = print($p)
$p = echo $p
Ok in my output to Quark I need to have $P printed to the page like this:
@$p2118 S. Campbell Ave
So in my php which is going to be grabbing this info and formatting it for
the Quarkisn't echoing that $p all I get is the @
I have tried several things:
$p = $p
$p = print($p)
$p = echo $p
On Wed, 2009-07-29 at 11:36 -0400, Miller, Terion wrote:
Ok in my output to Quark I need to have $P printed to the page like this:
@$p2118 S. Campbell Ave
So in my php which is going to be grabbing this info and formatting it for
the Quarkisn't echoing that $p all I get is the @
I
Yep just figured that out too..the escaping thing..
Thanks
On 7/29/09 10:45 AM, Ashley Sheridan a...@ashleysheridan.co.uk wrote:
On Wed, 2009-07-29 at 11:36 -0400, Miller, Terion wrote:
Ok in my output to Quark I need to have $P printed to the page like this:
@$p2118 S. Campbell Ave
So
$Ret = mysql_fetch_array($result); if(!$Ret) { } else { return $Ret; }
I'm assuming that you are calling my_fetch_array() in a loop of some
sort and so at some point there are no more records in the result.
Oh... Um... Yeah... Well... headdesk
So... Checking the docs... Returns an array of
-Original Message-
From: Miller, Terion [mailto:tmil...@springfi.gannett.com]
Sent: 29 July 2009 16:36
Ok in my output to Quark I need to have $P printed to the page like
this:
@$p2118 S. Campbell Ave
So in my php which is going to be grabbing this info and formatting
it for
-Original Message-
From: Matt Neimeyer [mailto:m...@neimeyer.org]
Sent: 29 July 2009 16:47
$Ret = mysql_fetch_array($result); if(!$Ret) { } else { return
$Ret; }
I'm assuming that you are calling my_fetch_array() in a loop of
some
sort and so at some point there are no more
Ford, Mike wrote:
-Original Message-
From: Matt Neimeyer [mailto:m...@neimeyer.org]
Sent: 29 July 2009 16:47
$Ret = mysql_fetch_array($result); if(!$Ret) { } else { return
$Ret; }
I'm assuming that you are calling my_fetch_array() in a loop of
some
sort and so at some point there
I'm trying to figure out how to test if a string matches *exactly*
another string, using a regexp pattern. The manual says that ereg() is
deprecated (in favour of what?) and preg_match() is giving me trouble.
The problem is that I'm passing the end-of-line delimiter ($) but it
seems to be
On 7/29/09 1:34 PM, Ashley Sheridan a...@ashleysheridan.co.uk wrote:
On Wed, 2009-07-29 at 11:29 -0700, Miller, Terion wrote:
I am trying to get rid of empty whitespace lines, I can't us chop() because
as I read it it will remove all whitespacesright?
Right now my db is outputting with
[snip/]
Have you thought of just using a regular str_replace() on your code? You
can ask it to replace newlines and carriage returns with nothing and see
if that fixes you problem?
Thanks
Ash
www.ashleysheridan.co.uk
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
From: Miller, Terion
/* snip */
Before anyone can tell you how to fix it, you need to find out what is
causing that white space. is it empty lines, vertical tabs, thousands of
spaces, ...? Once you find that out, it is pretty easy to decide how to
get rid of them. Can you save the output to a
Jim Lucas wrote:
I expected 'no match' but get 'match'.
[8]
cut/paste your code and it works for me.
Works for me as well. I get 'no match' from PHP 5.1.2, 5.2.6, and 5.2.8. What
version do you have?
If I might suggest a couple of simplifications that would make it easier to
Hey,
I've been asked to write a simple couple of public pages that
would let an Asterisk customer modify their account
configuration, but the client has no idea how Asterisk stores
its data, apparently not in MySQL.
Anyone know of any resources for accessing Asterisk from PHP?
If anyone
Ben Dunlap wrote:
Jim Lucas wrote:
I expected 'no match' but get 'match'.
[8]
cut/paste your code and it works for me.
Works for me as well. I get 'no match' from PHP 5.1.2, 5.2.6, and 5.2.8. What
version do you have?
PHP 5.2.5 with Suhosin-Patch 0.9.6.2 (cli) (built: Mar 11 2008
Miller, Terion wrote:
I am trying to get rid of empty whitespace lines, I can't us chop() because
as I read it it will remove all whitespacesright?
Right now my db is outputting with extra lines, I have stripped tags I know
it isn't that causing it to look like this
On 7/29/09 1:45 PM, Ashley Sheridan a...@ashleysheridan.co.uk wrote:
[snip/]
Have you thought of just using a regular str_replace() on your code? You
can ask it to replace newlines and carriage returns with nothing and see
if that fixes you problem?
Thanks
Ash
www.ashleysheridan.co.uk
Yep
On 7/29/09 2:19 PM, Jim Lucas li...@cmsws.com wrote:
$clean = preg_replace('|\s+|', ' ', $input);
Hi Jim,
The extra whitespace lines are in the data store, coming from it I'm going to
try your method but is there a way to not have mySQL store it with so many
lines (this is data being screen
Miller, Terion wrote:
On 7/29/09 2:19 PM, Jim Lucas li...@cmsws.com wrote:
$clean = preg_replace('|\s+|', ' ', $input);
Hi Jim,
The extra whitespace lines are in the data store, coming from it I'm going to
try your method but is there a way to not have mySQL store it with so many
Skip Evans wrote:
Hey,
I've been asked to write a simple couple of public pages that
would let an Asterisk customer modify their account
configuration, but the client has no idea how Asterisk stores
its data, apparently not in MySQL.
Depends on which data we're talking about. Asterisk is
On Wed, Jul 29, 2009 at 4:20 PM, Miller,
Teriontmil...@springfi.gannett.com wrote:
On 7/29/09 1:45 PM, Ashley Sheridan a...@ashleysheridan.co.uk wrote:
[snip/]
Have you thought of just using a regular str_replace() on your code? You
can ask it to replace newlines and carriage returns with
On 7/29/09 3:05 PM, Jonathan Tapicer tapi...@gmail.com wrote:
On Wed, Jul 29, 2009 at 4:20 PM, Miller,
Teriontmil...@springfi.gannett.com wrote:
On 7/29/09 1:45 PM, Ashley Sheridan a...@ashleysheridan.co.uk wrote:
[snip/]
Have you thought of just using a regular str_replace() on your
Miller, Terion wrote:
On 7/29/09 3:05 PM, Jonathan Tapicer tapi...@gmail.com wrote:
On Wed, Jul 29, 2009 at 4:20 PM, Miller,
Teriontmil...@springfi.gannett.com wrote:
On 7/29/09 1:45 PM, Ashley Sheridan a...@ashleysheridan.co.uk wrote:
[snip/]
Have you thought of just using a
I use convert to create thumbnail images. However, we have several
PDFs that convert doesn't seem to like. Even though it produced error
messages it still creates the thumbnail which doesn't display an
image. Is there an easy way for me to identify those bad image files
somehow in PHP
On 7/29/09 3:16 PM, Jim Lucas li...@cmsws.com wrote:
Miller, Terion wrote:
On 7/29/09 3:05 PM, Jonathan Tapicer tapi...@gmail.com wrote:
On Wed, Jul 29, 2009 at 4:20 PM, Miller,
Teriontmil...@springfi.gannett.com wrote:
On 7/29/09 1:45 PM, Ashley Sheridan a...@ashleysheridan.co.uk
Hello,
Is it possible to force a string to expand variable names after the
string has been set and before the variable's been defined without
having to do a string replace or preg_replace?
for example,
?php
$str = some string and some \$var plus other stuff;
echo $str.br /;
$var = Variable
Yep I forgot about escaping the $
On 7/29/09 10:51 AM, Ford, Mike m.f...@leedsmet.ac.uk wrote:
-Original Message-
From: Miller, Terion [mailto:tmil...@springfi.gannett.com]
Sent: 29 July 2009 16:36
Ok in my output to Quark I need to have $P printed to the page like
this:
I've been searching php.net for a function to do this:
if page_url('browse.php') {
$default = A;
}
$letter = isset($_GET['letter'])? $_GET['letter'] :$default ;
else
{
$letter = isset($_GET['letter'])?
Use eval, like this:
eval('$str_expanded = ' . str_replace('', '\\', $str) . ';');
The str_replace is used because you could have a inside $str and it
would break the string, if you are sure the $str has no inside you
can omit it.
Jonathan
On Wed, Jul 29, 2009 at 5:43 PM, Daniel
Consider the following:
$finfo = finfo_open( FILEINFO_MIME, '/usr/share/file/magic' );
if( $finfo )
{
$mimeType = finfo_file( $finfo, '/path/to/my/excel.xls' );
finfo_close($finfo);
}
echo $mimeType;
When I run the above, it echoes out
I've been searching php.net for a function to do this:
if page_url('browse.php') {
The $_SERVER global array has this sort of information. The 'PHP_SELF' key
might be what you want:
http://us.php.net/manual/en/reserved.variables.server.php
But where is the code that needs to know? I'm
Ben Dunlap wrote [TWICE]:
The $_SERVER global array has this sort of information. The 'PHP_SELF' key
[8]
Ben
Very sorry for the double-post. Reply-all in Thunderbird News seems a little
overzealous by default.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
Per Jessen wrote:
Depends on which data we're talking about. Asterisk is very flexible.
For example, the first screen they want people to be able to
change data on is:
call waiting,do not disturb
and then it looks like numbers (forwarding?)
unconditional,unavailable,busy
I'm trying to
Jonathan Tapicer wrote:
Use eval, like this:
eval('$str_expanded = ' . str_replace('', '\\', $str) . ';');
The str_replace is used because you could have a inside $str and it
would break the string, if you are sure the $str has no inside you
can omit it.
Jonathan
On Wed, Jul 29,
On Wed, Jul 29, 2009 at 6:47 PM, Daniel Kolbokolb0...@umn.edu wrote:
Jonathan Tapicer wrote:
Use eval, like this:
eval('$str_expanded = ' . str_replace('', '\\', $str) . ';');
The str_replace is used because you could have a inside $str and it
would break the string, if you are sure the
On Wed, 29 Jul 2009 13:42:23 -0400, p...@logi.ca (b) wrote:
I'm trying to figure out how to test if a string matches *exactly*
another string, using a regexp pattern.
If this is REALLY what you want to do, what is wrong with strcmp?
--
PHP General Mailing List (http://www.php.net/)
To
Jim Lucas wrote:
Ben Dunlap wrote:
Jim Lucas wrote:
I expected 'no match' but get 'match'.
[8]
cut/paste your code and it works for me.
Works for me as well. I get 'no match' from PHP 5.1.2, 5.2.6, and 5.2.8. What
version do you have?
PHP 5.2.5 with Suhosin-Patch 0.9.6.2 (cli) (built:
On 07/29/2009 02:07 PM, Jim Lucas wrote:
b wrote:
I'm trying to figure out how to test if a string matches *exactly*
another string, using a regexp pattern. The manual says that ereg() is
deprecated (in favour of what?) and preg_match() is giving me trouble.
The problem is that I'm passing the
On 07/29/2009 03:03 PM, Ben Dunlap wrote:
Jim Lucas wrote:
I expected 'no match' but get 'match'.
[8]
cut/paste your code and it works for me.
Works for me as well. I get 'no match' from PHP 5.1.2, 5.2.6, and 5.2.8. What
version do you have?
5.2.9
If I might suggest a couple of
On 07/29/2009 07:48 PM, Daniel Kolbo wrote:
code works (no match) for me too on php 5.2.6 build date May 2 2008
18:01:20 with dumbdows NT.
preg_match fails but for a reason other than what I think you may be
expecting. It fails b/c of the first forwards slash in $url. The regex
engine
On Wed, Jul 29, 2009 at 05:15:38PM -0400, Christoph Boget wrote:
Consider the following:
$finfo = finfo_open( FILEINFO_MIME, '/usr/share/file/magic' );
if( $finfo )
{
$mimeType = finfo_file( $finfo, '/path/to/my/excel.xls' );
b wrote:
On 07/29/2009 07:48 PM, Daniel Kolbo wrote:
code works (no match) for me too on php 5.2.6 build date May 2 2008
18:01:20 with dumbdows NT.
preg_match fails but for a reason other than what I think you may be
expecting. It fails b/c of the first forwards slash in $url. The regex
On 07/29/2009 11:18 PM, Daniel Kolbo wrote:
b wrote:
On 07/29/2009 07:48 PM, Daniel Kolbo wrote:
code works (no match) for me too on php 5.2.6 build date May 2 2008
18:01:20 with dumbdows NT.
preg_match fails but for a reason other than what I think you may be
expecting. It fails b/c of the
52 matches
Mail list logo