php-general Digest 23 Jul 2009 07:54:18 - Issue 6245
Topics (messages 295708 through 295731):
Re: Client Side PHP
295708 by: Lenin
295710 by: Eddie Drapkin
unsetting a referenced parameter in a function
295709 by: Tom Worster
295719 by: Shawn McKenzie
On Wed, 2009-07-22 at 23:49 -0400, Paul M Foster wrote:
On Wed, Jul 22, 2009 at 08:31:10PM -0700, Javed Khan wrote:
How to build an FF extension and how to install it. I'm using Fedora 10
operating system.
Can someone please provide me with the steps
Thanks
J.K
Let me substitute
João Cândido de Souza Neto wrote:
You made a mistake in your code:
?php the_title(); ?
must be:
?php echo the_title(); ?
Not necessarily: what if you have
function the_title()
{
echo Title;
}
for example...
In response to Sebastiano:
There would be not much point in using
Thanks, it's now much more clear. I thought that html parts outside
php tags were just dumped to output, no matter of if-else statements
and other conditions. I was *definitely* wrong
2009/7/23 Peter Ford p...@justcroft.com:
In response to Sebastiano:
There would be not much point in using
Hi,
It isn't really a programming question, but rather a structural.
Let's suppose I have a PHP page, which is built by other PHP files' includes.
Which is the better approach:
in a switch-like statement I include the required PHP files, which contain
all the functions, and the HTML code to
2009/7/23 Sándor Tamás (HostWare Kft.) sandorta...@hostware.hu
Hi,
It isn't really a programming question, but rather a structural.
Let's suppose I have a PHP page, which is built by other PHP files'
includes.
Which is the better approach:
in a switch-like statement I include the
-Original Message-
From: Dengxule [mailto:dengx...@gmail.com]
Sent: 23 July 2009 10:53
Hoping for the coming of the concept of PACKAGE. Seems that
NAMESPACE will
be introduced in PHP6.
Already present in 5.3, actually.
Cheers!
Mike
--
Mike Ford,
Electronic Information
-Original Message-
From: Paul M Foster [mailto:pa...@quillandmouse.com]
Sent: 23 July 2009 06:13
On Thu, Jul 23, 2009 at 11:57:51AM +0800, ?? wrote:
But I cannot help myself with the url pattern :
/somepath_to_mediawiki/index.php/pagetitle.
How can this kind of url be
Go to the ff site and read the docs
bastien
On Wednesday, July 22, 2009, Javed Khan iankha...@yahoo.com wrote:
How to build an FF extension and how to install it. I'm using Fedora 10
operating system.
Can someone please provide me with the steps
Thanks
J.K
--
Bastien
Cat, the other
Tom Worster wrote:
On 7/22/09 6:09 PM, Shawn McKenzie nos...@mckenzies.net wrote:
Tom Worster wrote:
though the manual is perfectly clear that this should be expected, i was a
bit surprised that the result of the following is 42
?php
function foo($a) {
$a = 42;
unset($a);
$a =
When I first started programming in PHP I used the second method you
mentioned. I had a single file I called utils.php and it contained
all the functions I could possibly need throughout my site.
Unfortunately, this file grew to be over 10,000 lines and most of the
time I only needed a
Well if the server your running on is linux based (and I haven't tried
this) you could try adding a nohup and background the task for example
rather than doing:
system('updatedb');
try
system('nohup updatedb ');
It should background the task and let it continue running even when the
php
Floyd Resler wrote:
When I first started programming in PHP I used the second method you
mentioned. I had a single file I called utils.php and it contained
all the functions I could possibly need throughout my site.
Unfortunately, this file grew to be over 10,000 lines and most of the
I think he is confusing the unset semantic.
Unset just destroy a variable, but not the content of it.
Take a look at the output of this simple script:
function avoid_global_scope()
{
$a = 'foo';
var_dump( get_defined_vars() );
$b = $a;
var_dump( get_defined_vars() );
unset( $a
'Tis true. I just find dealing with the smaller files much easier.
At the time I was using Komodo IDE and it would get very sluggish with
the larger files.
Take care,
Floyd
On Jul 23, 2009, at 9:34 AM, Robert Cummings wrote:
Floyd Resler wrote:
When I first started programming in PHP I
2009/7/23 Ashley Sheridan a...@ashleysheridan.co.uk
On Wed, 2009-07-22 at 23:49 -0400, Paul M Foster wrote:
On Wed, Jul 22, 2009 at 08:31:10PM -0700, Javed Khan wrote:
How to build an FF extension and how to install it. I'm using Fedora 10
operating system.
Can someone please
On Thu, 2009-07-23 at 14:39 +0100, Luke wrote:
2009/7/23 Ashley Sheridan a...@ashleysheridan.co.uk
On Wed, 2009-07-22 at 23:49 -0400, Paul M Foster wrote:
On Wed, Jul 22, 2009 at 08:31:10PM -0700, Javed Khan wrote:
How to build an FF extension and how to install it. I'm using Fedora
I keep getting this error while trying to use the field 'ID' to pass in a url..
And it's odd because the query is pulling everything BUT the ID which is the
first field...
code:
a href=view.php?ID=?php echo $_SESSION['fullRestaurantList']['ID']??php
echo
Ashley Sheridan wrote:
Wikipedia can hardly be accounted an official source of anything,
especially considering how it gets the content! If you want official,
then http://www.mozilla.com/en-US/firefox/releases/1.5.html is a good
link.
Wikipedia is the official source of Wikipedia information
On Thu, Jul 23, 2009 at 10:15 AM, Robert Cummingsrob...@interjinn.com wrote:
Ashley Sheridan wrote:
Wikipedia can hardly be accounted an official source of anything,
especially considering how it gets the content! If you want official,
then
Ashley Sheridan wrote:
On Thu, 2009-07-23 at 14:39 +0100, Luke wrote:
2009/7/23 Ashley Sheridan a...@ashleysheridan.co.uk
On Wed, 2009-07-22 at 23:49 -0400, Paul M Foster wrote:
On Wed, Jul 22, 2009 at 08:31:10PM -0700, Javed Khan wrote:
How to build an FF
Robert Cummings wrote:
Ashley Sheridan wrote:
Wikipedia can hardly be accounted an official source of anything,
especially considering how it gets the content! If you want official,
then http://www.mozilla.com/en-US/firefox/releases/1.5.html is a good
link.
Wikipedia is the official source
Miller, Terion wrote:
I keep getting this error while trying to use the field 'ID' to pass in a url..
And it's odd because the query is pulling everything BUT the ID which is the
first field...
code:
a href=view.php?ID=?php echo $_SESSION['fullRestaurantList']['ID']??php
echo
Miller, Terion wrote:
I keep getting this error while trying to use the field 'ID' to pass in a
url.. And it's odd because the query is pulling everything BUT the ID which
is the first field...
code:
a href=view.php?ID=?php echo
$_SESSION['fullRestaurantList']['ID']??php echo
On 7/23/09 9:24 AM, Kyle Smith kyle.sm...@inforonics.com wrote:
Miller, Terion wrote:
I keep getting this error while trying to use the field 'ID' to pass in a url..
And it's odd because the query is pulling everything BUT the ID which is the
first field...
code:
a href=view.php?ID=?php
On Thu, Jul 23, 2009 at 09:34:37AM -0400, Robert Cummings wrote:
snip
Not that I disagree with your methodology at this time, but you could
have just made that single big file, include all those little files and
still had a single load statement in each of your consumer source files.
With
Miller, Terion wrote:
On 7/23/09 9:24 AM, Kyle Smith kyle.sm...@inforonics.com wrote:
Miller, Terion wrote:
I keep getting this error while trying to use the field 'ID' to pass in a url..
And it's odd because the query is pulling everything BUT the ID which is the
first field...
code:
a
Paul M Foster wrote:
On Thu, Jul 23, 2009 at 09:34:37AM -0400, Robert Cummings wrote:
snip
Not that I disagree with your methodology at this time, but you could
have just made that single big file, include all those little files and
still had a single load statement in each of your consumer
Sorry, list, I did a reply instead of a reply-to-all. This is what I
sent to Miller, Terion
Miller, Terion wrote:
Thanks for the link Kyle!! Great thing there...(seriously I didn't know...I
learn something everyday)
Anyways the link to my script is: http://pastebin.ca/1504393
Your
On Thu, Jul 23, 2009 at 10:21 AM, Kyle Smithkyle.sm...@inforonics.com wrote:
Robert Cummings wrote:
Ashley Sheridan wrote:
Wikipedia can hardly be accounted an official source of anything,
especially considering how it gets the content! If you want official,
then
-Original Message-
From: Shawn McKenzie [mailto:nos...@mckenzies.net]
Sent: 23 July 2009 02:36 PM
To: php-general@lists.php.net
Subject: Re: [PHP] Re: unsetting a referenced parameter in a function
Tom Worster wrote:
On 7/22/09 6:09 PM, Shawn McKenzie nos...@mckenzies.net wrote:
Tom
Hey all,
we've got a repository here at work, with something like 55,000 files
in it. For the last few years, we've been naming $variables_like_this
and functions_the_same($way_too). And now we've decided to switch to
camelCasing everything and I've been tasked with somehow determining
if it's
Eddie Drapkin wrote:
Hey all,
we've got a repository here at work, with something like 55,000 files
in it. For the last few years, we've been naming $variables_like_this
and functions_the_same($way_too). And now we've decided to switch to
camelCasing everything and I've been tasked with
PHP Gurus,
I'm currently having a problem with PHP writing text to a PNG image on
one server.
I have various web sites hosted on various servers, and on most of them,
the script that generates the image is writing text properly. I have
ensured that the same fonts are available on all the
function toCamelCase( $string )
{
return str_replace( ' ' , '', ucwords( strtolower( strtr($string, '_',
' ') ) ));
}
echo toCamelCase( 'this_is_not_properly_written' );
You can use this simplest function to translate a string to camelCase.
The process could be...
1) parse by PHP
2)
In a project with this large number of files, is better if you let the way it
is, doing this now you can crash the project and lost much much time.
Yuri Yarlei.
Programmer PHP, CSS, Java, PostregreSQL;
Today PHP, tomorrow Java, after the world.
Kyou wa PHP, ashita wa Java, sono ato sekai desu.
Dave M G wrote:
PHP Gurus,
I'm currently having a problem with PHP writing text to a PNG image on
one server.
I have various web sites hosted on various servers, and on most of them,
the script that generates the image is writing text properly. I have
ensured that the same fonts are
2009/7/23 Dave M G mar...@autotelic.com:
Is there a way I can take the output of phpinfo() from both servers and do a
compare that will tell me what the differences are?
Just diff the HTML. WinMerge, Kompare, etc etc. Or probably built into
your favourite IDE.
--
PHP General Mailing List
Eddie Drapkin wrote:
Hey all,
we've got a repository here at work, with something like 55,000 files
in it. For the last few years, we've been naming $variables_like_this
and functions_the_same($way_too). And now we've decided to switch to
camelCasing everything and I've been tasked with
David, Robert,
Thank you for replying.
Just diff the HTML.
Unfortunately it is not that easy. Even if the same PHP modules are
present, if they are written into the page in a different place, they
show up as differences. The same goes for all the HTML tags and
everything else, so what I
From: Dave M G
Thank you for replying.
Just diff the HTML.
Unfortunately it is not that easy. Even if the same PHP modules are
present, if they are written into the page in a different place, they
show up as differences. The same goes for all the HTML tags and
everything else, so what
From: Dave M G
I'm currently having a problem with PHP writing text to a PNG image on
one server.
I have various web sites hosted on various servers, and on most of
them,
the script that generates the image is writing text properly. I have
ensured that the same fonts are available on
On Thu, Jul 23, 2009 at 1:50 PM, Greg Beaverg...@chiaraquartet.net wrote:
Eddie Drapkin wrote:
Hey all,
we've got a repository here at work, with something like 55,000 files
in it. For the last few years, we've been naming $variables_like_this
and functions_the_same($way_too). And now we've
You might even be able to convert EMPTY(X) to COALESCE(X, '') = ''.
MySQL seems to be pretty forgiving with its implicit type-casting.
Hmm... The new system I've written properly handles the datatype and
EMPTY... So this would be a hack to much around with regexs to replace
EMPTY in customer
On Thu, Jul 23, 2009 at 3:39 PM, Matt Neimeyerm...@neimeyer.org wrote:
You might even be able to convert EMPTY(X) to COALESCE(X, '') = ''.
MySQL seems to be pretty forgiving with its implicit type-casting.
Hmm... The new system I've written properly handles the datatype and
EMPTY... So this
Thanks
On 7/23/09 9:52 AM, Kyle Smith kyle.sm...@inforonics.com wrote:
Sorry, list, I did a reply instead of a reply-to-all. This is what I
sent to Miller, Terion
Miller, Terion wrote:
Thanks for the link Kyle!! Great thing there...(seriously I didn't know...I
learn something everyday)
2009/7/23 Eddie Drapkin oorza...@gmail.com:
Hey all,
we've got a repository here at work, with something like 55,000 files
in it. For the last few years, we've been naming $variables_like_this
and functions_the_same($way_too). And now we've decided to switch to
camelCasing everything and
I'm trying to profile a site on our development server to see why it
takes around 4 seconds to generate a pretty basic page. I installed
xdebug to use for the profiling, and now I'm really confused. Even
though it takes around 4 seconds to build the entire page, the profile
says that the total
Andrew Ballard wrote:
I'm trying to profile a site on our development server to see why it
takes around 4 seconds to generate a pretty basic page. I installed
xdebug to use for the profiling, and now I'm really confused. Even
though it takes around 4 seconds to build the entire page, the profile
Thank you for replying.
Just diff the HTML.
Unfortunately it is not that easy. Even if the same PHP modules are
present, if they are written into the page in a different place, they
show up as differences. The same goes for all the HTML tags and
everything else, so what I end up with is
Nope. Basically it connects to a database to load an ACL (which at
[...]
I thought xdebug was supposed to be a pretty good profiler. If it
calculating the time correctly, where are the other ~3.6 seconds
going?
One night I saw a script wait indefinitely for a response from a tanked
database,
Just an idea: try using the (microtime(true) - $start) approach in
portions of code to try isolate the portion that is taking more time.
Sometimes that helps me to find the function that is slowing
everything down.
Jonathan
On Thu, Jul 23, 2009 at 6:18 PM, Andrew Ballardaball...@gmail.com wrote:
On Fri, Jul 24, 2009 at 12:20 AM, Clancy clanc...@cybec.com.au wrote:
Does anyone know of an extension/utility that will enable PHP to write
backup files to a
CD/DVD?
Ideally I would like the CD to appear as 'just another drive'.
--
PHP General Mailing List (http://www.php.net/)
To
Does anyone know of an extension/utility that will enable PHP to write backup
files to a
CD/DVD?
Ideally I would like the CD to appear as 'just another drive'.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
That's what I was just about writting.
If you use linux -- you can shot calls to the system and watch it's
response!
Then all you have to do is to install a cd burning software which have an
ability to control it through the terminal!
Good luck mate!
On Fri, Jul 24, 2009 at 1:47 AM, Diogo
Ashley Sheridan a écrit :
But *how* does it offer more security? You've not actually mentioned
that!
Because you need database slice access to manage the session, and not
only file access in /tmp/ (where sessions belongs, by default). So now
the problem is : and what about the
Thanks a lot. As far as i know, both methods dealing with urls are
WEB-SERVER-TECH. While I was installing mediawiki, i did nothing with the
file httpd.conf, no changes made on mod_rewrite.
The mediawiki install script cannot do nothing to httpd.conf i think.
So i'm confused about how the
Sándor Tamás (HostWare Kft . ) a écrit :
It isn't really a programming question, but rather a structural.
It is part of our burden ;)
Which is the better approach:
They are no better approch, only bad ones. I'm using to organize my
code in module. Each module require the needed modules.
On Thu, Jul 23, 2009 at 10:28 PM, Dengxule dengx...@gmail.com wrote:
Thanks a lot. As far as i know, both methods dealing with urls are
WEB-SERVER-TECH. While I was installing mediawiki, i did nothing with the
file httpd.conf, no changes made on mod_rewrite.
The mediawiki install script
On Thu, Jul 23, 2009 at 5:32 PM, Ben Dunlapbdun...@agentintellect.com wrote:
I second Jonathan's suggestion; I would try calling microtime() before and
after your database query, and before and after anything else that isn't
strictly execution of the script.
Ben
I tried this where I could.
Hello everyone,
Lets say I have a file called form.php with the following form on it that
redirects to index.php when submitted. I would like to take the values of
the text fields in the form and put them into an array, then be able to
display the values in that array on index.php Does anyone
Jason Carson wrote:
Jason Carson wrote:
Hello everyone,
Lets say I have a file called form.php with the following form on it
that
redirects to index.php when submitted. I would like to take the values
of
the text fields in the form and put them into an array, then be able to
display the
Jason Carson wrote:
Jason Carson wrote:
Hello everyone,
Lets say I have a file called form.php with the following form on it
that
redirects to index.php when submitted. I would like to take the values
of
the text fields in the form and put them into an array, then be able
to
display
Did you correct the missing double quote in your sending form first?
Warren Vail
-Original Message-
From: Jason Carson [mailto:ja...@jasoncarson.ca]
Sent: Thursday, July 23, 2009 9:33 PM
To: php-general@lists.php.net
Subject: Re: [PHP] Re: A form and an array
Jason Carson wrote:
Yes
Did you correct the missing double quote in your sending form first?
Warren Vail
-Original Message-
From: Jason Carson [mailto:ja...@jasoncarson.ca]
Sent: Thursday, July 23, 2009 9:33 PM
To: php-general@lists.php.net
Subject: Re: [PHP] Re: A form and an array
Jason Carson
On Fri, Jul 24, 2009 at 10:28:52AM +0800, Dengxule wrote:
Thanks a lot. As far as i know, both methods dealing with urls are
WEB-SERVER-TECH. While I was installing mediawiki, i did nothing with the
file httpd.conf, no changes made on mod_rewrite.
The mediawiki install script cannot do
In php.ini turn the display_errors to on.
If any error,warn or notice shown,copy them and paste here.
So you can tell us what doesn't work.
good luck~
2009/7/24 Jason Carson ja...@jasoncarson.ca
Jason Carson wrote:
Jason Carson wrote:
Hello everyone,
Lets say I have a file called
I have it working now. I had a comma where a semicolon should have been.
Silly error on my part but thanks to everyone who tried to help me.
In php.ini turn the display_errors to on.
If any error,warn or notice shown,copy them and paste here.
So you can tell us what doesn't work.
good luck~
I think PATHINFO is probably what i'm looking for.
Paul mentioned the lookback feature, i think that is or about the same
thing.
MediaWiki-1.15.1 use the pattern of url for common pages like this :
some_path_to_mediawiki/index.php/something , and the 'something' supports
even non-english
69 matches
Mail list logo