php-general Digest 30 Apr 2009 12:50:39 - Issue 6095
Topics (messages 292137 through 292148):
Re: file_get_contents doesn't work on one particular server
292137 by: Shawn McKenzie
DateInterval
292138 by: MIke Alaimo
292139 by: Raymond Irving
292141 by: MIke
'Twas brillig, and Raymond Irving at 30/04/09 03:32 did gyre and gimble:
Hello,
Every so often I have to be using the isset() function to check if a variable
exists. It would be useful to have something like an ifset() function
Instead of doing this
$v = isset($input) ? $input : $default;
2009/4/29 Matt Neimeyer m...@neimeyer.org:
On Wed, Apr 29, 2009 at 1:30 PM, Shawn McKenzie nos...@mckenzies.net wrote:
Philip Thompson wrote:
On Apr 29, 2009, at 11:42 AM, Matt Neimeyer wrote:
I have a function that currently takes a boolean value as a parameter.
But now I want to expand it
Hi all,
I have the following XML returned to us.
Response ResponseReference=REF_657-17000-305754723972091
ResponseDetails Language=en
SearchChargeConditionsResponse
ChargeConditions
ChargeCondition
Troy Oltmanns wrote:
I have the code below being used to rifle through a list of available
categories and create select options for them. The code is being used to
query the database and compare the product category to the current
iteration, if there's a match, then add selected code so the
Hi,
I am trying to add a prefix to all of the entries in a zip file using
the ZipArchive::renameIndex function which is corrupting the files
when I try to extract them. I was wondering if anyone else has used
this method successfully? Here is the code im using:
$client='TEST';
$zip = new
I have a script that is a result of data entered in a form
On the script (when I test without data entry), I am getting a warning that
Warning: Division by zero in .inc.php on line 15.
The warning is correct, however the viewer cannot access the second script
without entering the data that
It's always better to validate your inputs in any was possible, this
helps prevent exploits.
-Original Message-
From: Gary [mailto:gwp...@ptd.net]
Sent: Thursday, April 30, 2009 8:51 AM
To: php-general@lists.php.net
Subject: [PHP] Warning: Division by zero
I have a script that is a
I have a script that is a result of data entered in a form
On the script (when I test without data entry), I am getting a warning that
Warning: Division by zero in .inc.php on line 15.
The warning is correct, however the viewer cannot access the second script
without entering the data that
On Thu, Apr 30, 2009 at 3:33 AM, 9el le...@phpxperts.net wrote:
I just got a project to do on PHP of scraping the body items from
static sites or just html sites.
Could you experts please suggest me some quick resources?
I have to make an WP plugin with the data as well.
Any expert there
On Thu, Apr 30, 2009 at 5:02 AM, AngeloZanetti angelo...@gmail.com wrote:
Hi all,
I have the following XML returned to us.
Response ResponseReference=REF_657-17000-305754723972091
ResponseDetails Language=en
SearchChargeConditionsResponse
Thanks for your response.
The error I am getting is when I am defining a variable.
(line 15) $percent_difference=($assess_difference)/($assess_value);
Does this make a difference?
Thanks again for all your help.
Gary
Christoph Boget christoph.bo...@gmail.com wrote in message
The error I am getting is when I am defining a variable.
(line 15) $percent_difference=($assess_difference)/($assess_value);
Does this make a difference?
No, it doesn't make a difference. The simple fact is that
$assess_value is either undefined or has been set to 0 at some point.
For it's
On 4/29/09 6:52 PM, Reese howel...@inkworkswell.com wrote:
Tom Worster wrote:
On 4/28/09 4:05 PM, Reese howel...@inkworkswell.com wrote:
Granted, this isn't a PHP question but I'm curious, how does UTF-8 solve
this display issue?
if we're talking about web browsers, they are quite good
9el wrote:
On Thu, Apr 30, 2009 at 3:33 AM, 9el le...@phpxperts.net wrote:
I just got a project to do on PHP of scraping the body items from
static sites or just html sites.
Could you experts please suggest me some quick resources?
I have to make an WP plugin with the data as well.
Any
On Wed, Apr 29, 2009 at 22:32, Raymond Irving xwis...@yahoo.com wrote:
What do you think? Can they make it into 5.3?
Not when doing the ternary operator that you even displayed
yourself takes up less code and time than a core function would. It's
a good idea, but better handled on the
Hi all,
Since I can't do $this = new Class(); within my class (it gives an
error), I was looking for ways to get the same result by other means.
I am actually working on an ORM and trying to implement lazy loading.
$book = $orm-getBook('id'); // returns an Orm object
$book-load();
// $book
On Thu, 2009-04-30 at 11:06 +0200, Marcus Gnaß wrote:
Troy Oltmanns wrote:
I have the code below being used to rifle through a list of available
categories and create select options for them. The code is being used to
query the database and compare the product category to the current
is there a neat literal syntax for creating objects on the fly without
defining a type?
whenever i need to do it i do something like
$x = (object) array('a'=1, 'b'=3, ...);
which works but isn't very lovely. it's neater in, for example, javascript.
--
PHP General Mailing List
Tom Worster wrote:
why use SGML character entity references in a utf-8 file or stream? can't
you just put the character in the file?
Because, I thought, HTML files were basically just text files with
different file extensions, and that those other characters would not
store or display
It'd be a hassle to just remove a function from a language, I suppose...
On Thu, Apr 30, 2009 at 6:15 PM, Reese howel...@inkworkswell.com wrote:
Tom Worster wrote:
why use SGML character entity references in a utf-8 file or stream? can't
you just put the character in the file?
Because, I
Hello!
I'm taking part in the ISSO Seva Charity Walk 2009 on 19/07/2009 to raise money
for International Swaminarayan Satsang Organisation and I'd really appreciate
your support.
It's easy to sponsor me online by credit or debit card - just go to my
Justgiving page:
On 4/30/09 6:15 PM, Reese howel...@inkworkswell.com wrote:
Tom Worster wrote:
why use SGML character entity references in a utf-8 file or stream? can't
you just put the character in the file?
Because, I thought, HTML files were basically just text files with
different file extensions,
The consensus seems to be that the proposed ifset() and ifempty()
functions are more effort than they are worth. What I'd like to know
is, why empty() still exists when every time I turn around, the
mentors I turn to locally tell me not to use it, to use isset()
instead. Because empty() doesn't
re: Eclipse, PDT plugins for hosting, scaling and managing PHP apps.
Aptana has released a new suite of tools for PHP developers that extends the
popular
Eclipse PDT environment. The plugin for Eclipse, called Aptana Cloud
Connect, lets
you get all the benefits of scalable, on-demand PHP
Ah. This makes perfect sense. Good idea.
Mike
Raymond Irving wrote:
--- On Wed, 4/29/09, MIke Alaimo li...@reptiliannature.org wrote:
Raymond, have you tried using DateTime::modify? It
appears to work like strtotime.
also DateTime::format works like date. At least as
far as I can
Hi Colin and Daniel,
Thanks for the feedback.
I know that this functionality can be added to a framework or a stand alone
function but I'm assuming that we would not get the same performance:
Case 1
---
$c = isset($a) ? $a : '';
// total time = overhead of isset() + overhead of ?:
27 matches
Mail list logo