If you have total control over application A which contains the bridge code,
the easiest is to change it to use a different global variable, $dbA. This
must not be doable or you wouldn't have asked.
If you have control over the bridge code, and it alone calls A and B, then
you could swap the $db v
Short of refactoring ApplicationB, can you set it up as a SOAP/REST service
that AppA calls?
On Tue, Oct 5, 2010 at 5:02 PM, Brian Smither wrote:
>
> >Just to clarify, both packages are instantiating and calling their
> >respective classes from the $db var, which is in the global scope.
> >Is t
>Just to clarify, both packages are instantiating and calling their
>respective classes from the $db var, which is in the global scope.
>Is this correct?
I would say yes to the way you are asking. Take the following two applications.
The four respective statements are in each their respective sc
As I can see, it´d be too much faster to decide by yourself than reading all
theese answers and understanding their differences and taking people´s time
for nothing.
--
João Cândido de Souza Neto
"saeed ahmed" escreveu na mensagem
news:aanlktikh6g5ilsz3hkxatg=h1wzobgoko7byngo0p...@mail.g
On Tue, Oct 5, 2010 at 3:58 PM, Steve Staples wrote:
> On Tue, 2010-10-05 at 20:53 +0100, Ashley Sheridan wrote:
> > On Tue, 2010-10-05 at 15:46 -0400, Steve Staples wrote:
> >
> > > On Tue, 2010-10-05 at 20:35 +0100, Ashley Sheridan wrote:
> > > > On Tue, 2010-10-05 at 15:28 -0400, chris h wrote
On Tue, 2010-10-05 at 15:58 -0400, Steve Staples wrote:
> On Tue, 2010-10-05 at 20:53 +0100, Ashley Sheridan wrote:
> > On Tue, 2010-10-05 at 15:46 -0400, Steve Staples wrote:
> >
> > > On Tue, 2010-10-05 at 20:35 +0100, Ashley Sheridan wrote:
> > > > On Tue, 2010-10-05 at 15:28 -0400, chris h wr
Just to clarify, both packages are instantiating and calling their
respective database classes from the $db var, which is in the global scope.
Is this correct?
This is why I hate the global scope, I hate it, I hate it!
On Tue, Oct 5, 2010 at 3:47 PM, Brian Smither wrote:
> I am running into a v
On Tue, 2010-10-05 at 20:53 +0100, Ashley Sheridan wrote:
> On Tue, 2010-10-05 at 15:46 -0400, Steve Staples wrote:
>
> > On Tue, 2010-10-05 at 20:35 +0100, Ashley Sheridan wrote:
> > > On Tue, 2010-10-05 at 15:28 -0400, chris h wrote:
> > >
> > > > Benchmark and find out! :)
> > > >
> > > > Wha
On Oct 5, 2010, at 3:23 PM, saeed ahmed wrote:
> $a = 'hey';
> $b = 'done';
>
> $c = $a.$b;
> $c = "$a$b";
>
> which one is faster for echo $c.
Depends upon the platform its running on.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Tue, Oct 5, 2010 at 3:53 PM, Ashley Sheridan
wrote:
> On Tue, 2010-10-05 at 15:46 -0400, Steve Staples wrote:
>
> > On Tue, 2010-10-05 at 20:35 +0100, Ashley Sheridan wrote:
> > > On Tue, 2010-10-05 at 15:28 -0400, chris h wrote:
> > >
> > > > Benchmark and find out! :)
> > > >
> > > > What ar
On Tue, 2010-10-05 at 15:46 -0400, Steve Staples wrote:
> On Tue, 2010-10-05 at 20:35 +0100, Ashley Sheridan wrote:
> > On Tue, 2010-10-05 at 15:28 -0400, chris h wrote:
> >
> > > Benchmark and find out! :)
> > >
> > > What are you using this for? Unless you are doing something crazy it
> > > pr
I am running into a variable collision. The project I'm developing is NOT
guaranteed to be operating on PHP5. Any solution I find should (hopefully) be
able to run on PHP4 (yes, I know PHP4 is deprecated).
I am building a bridge between two third-party applications. Both instantiate
their respe
On Tue, 2010-10-05 at 20:35 +0100, Ashley Sheridan wrote:
> On Tue, 2010-10-05 at 15:28 -0400, chris h wrote:
>
> > Benchmark and find out! :)
> >
> > What are you using this for? Unless you are doing something crazy it
> > probably doesn't matter, and you should pick whichever you feel looks nic
Saeed here's a quick (and dirty) test I ran:
$tests = 100;
$start = microtime(true);
for ($i=0; $i<$tests; $i++) {
$a = md5( rand() );
$b = md5( rand() );
$c = $a.$b;
}
var_dump( "By concat op:\t". (microtime(true) - $start) );
$start = microtime(true);
for ($i=0; $i<$tests; $i++)
On Tue, 2010-10-05 at 15:28 -0400, chris h wrote:
> Benchmark and find out! :)
>
> What are you using this for? Unless you are doing something crazy it
> probably doesn't matter, and you should pick whichever you feel looks nicer
> / is easier to code in / etc.
>
> Chris H.
>
> On Tue, Oct 5, 2
Benchmark and find out! :)
What are you using this for? Unless you are doing something crazy it
probably doesn't matter, and you should pick whichever you feel looks nicer
/ is easier to code in / etc.
Chris H.
On Tue, Oct 5, 2010 at 3:23 PM, saeed ahmed wrote:
> $a = 'hey';
> $b = 'done';
>
>
$a = 'hey';
$b = 'done';
$c = $a.$b;
$c = "$a$b";
which one is faster for echo $c.
On Tue, 2010-10-05 at 14:32 -0400, tedd wrote:
> At 1:56 PM -0400 10/5/10, tedd wrote:
> >At 12:54 PM +0100 10/5/10, Col Day wrote:
> >>Hi Shreyas,
> >>
> >>Ok, as far as I can tell the script should show "This is an HTML
> >>line" reflecting that I am seeing the HTML part of the script
> >>follo
At 1:56 PM -0400 10/5/10, tedd wrote:
At 12:54 PM +0100 10/5/10, Col Day wrote:
Hi Shreyas,
Ok, as far as I can tell the script should show "This is an HTML
line" reflecting that I am seeing the HTML part of the script
followed by "This is a PHP line" to show that PHP is installed and
workin
At 12:54 PM +0100 10/5/10, Col Day wrote:
Hi Shreyas,
Ok, as far as I can tell the script should show "This is an HTML
line" reflecting that I am seeing the HTML part of the script
followed by "This is a PHP line" to show that PHP is installed and
working fine.
Col:
Do this:
1. Create a f
On Tue, Oct 5, 2010 at 8:41 AM, Matt Palermo wrote:
> I'm assuming there is no way to make a global alias. Can anyone
> confirm/deny this?
>
I reread the documentation on namespaces, and from what I can tell this is
no way to do it. Each file maintains its own active namespace *at compile
time*
I'm assuming there is no way to make a global alias. Can anyone
confirm/deny this?
""Matt Palermo"" wrote in message
news:5e7b8989448b45dbbeeb6fb89b3f3...@rachet...
Is it possible to create a global namespace alias in PHP or does the alias
have to be defined in EVERY file that I use? H
On Tue, Oct 5, 2010 at 6:56 AM, Richard Quadling wrote:
> The issue _WAS_ the firewall.
>
> All sorted.
>
> Thank you.
>
>
Glad he got it working.
Adam
--
Nephtali: PHP web framework that functions beautifully
http://nephtaliproject.com
--
Ngô Xuân Huy
> -Original Message-
> From: Col Day [mailto:colind...@aol.com]
> Sent: 05 October 2010 12:55
> To: php-general@lists.php.net
> Subject: Re: [PHP] Re: Continuance of the struggle (trying to
> understand)
>
> Hi Shreyas,
>
> Ok, as far as I can tell the script should show "This is an HTM
Hello,
remember that for windows, you must also copy the library (libmysql.dll) to
window's system32 directory in addition to un-commenting the
extension=php_mysql.dll line in php.ini. Also, just in case, ensure that
php.ini also has the proper extension directory set, typically c:\php\ext
b
"If I paste the script into a web page"
What do you mean by "paste the script into a web page"? Can you tell us
exactly what you are doing when you do that?
Chris.
On Tue, Oct 5, 2010 at 7:54 AM, Col Day wrote:
> Hi Shreyas,
>
> Ok, as far as I can tell the script should show "This is an H
On Tue, 2010-10-05 at 14:02 +0100, Jason wrote:
> >-Original Message-
> >From: Steve Staples [mailto:sstap...@mnsi.net]
> >Sent: 05 October 2010 13:55
> >To: php-general
> >Subject: Re: Fw: [PHP] Connecting to MySql with PHP
> >
> >On Tue, 2010-10-05 at 13:35 +0100, sueandant wrote:
> >> -
>-Original Message-
>From: Steve Staples [mailto:sstap...@mnsi.net]
>Sent: 05 October 2010 13:55
>To: php-general
>Subject: Re: Fw: [PHP] Connecting to MySql with PHP
>
>On Tue, 2010-10-05 at 13:35 +0100, sueandant wrote:
>> - Original Message -
>> From: sueandant
>> To: a...@ash
On Tue, 2010-10-05 at 13:35 +0100, sueandant wrote:
> - Original Message -
> From: sueandant
> To: a...@ashleysheridan.co.uk
> Sent: Monday, October 04, 2010 10:29 PM
> Subject: Re: [PHP] Connecting to MySql with PHP
>
>
> Thanks Ash
>
> Where do I find the PHP mysql module? I have
- Original Message -
From: sueandant
To: a...@ashleysheridan.co.uk
Sent: Monday, October 04, 2010 10:29 PM
Subject: Re: [PHP] Connecting to MySql with PHP
Thanks Ash
Where do I find the PHP mysql module? I have uncommented both the extensions
php-mysql.dll and php-mysqli.dll; do I
Sueandant :
Reading more carefully your email, and search for this error in the net.
Y find this page
http://coreygilmore.com/blog/2009/11/20/fix-php-5-3-hang-on-windows/
Try this
Alejandro M.S.
-Mensagem original-
De: Alejandro Michelin Salomon [mailto:amichel...@hotmail.com]
Enviada
Col:
If i am reading this correctly, then i think you're looking at this all
wrong.
If you're working within some kind of page, stored outside of the
http://localhost served by apache, like say the .php file is on the
desktop... then yeah, you're not going to get the PHP information
displayed.
(
Sueandant :
Goto your my.ini file
In my case located in C:\Arquivos de programas\MySQL\MySQL Server 5.1
Search is this configuration option is enabled => skip-networking
And comment to enabled listen on a TCP/IP port. Default port 3306
Or
Put => enable-named-pipe to enable named pipes
Alejandr
LOL!
This is WITH xammp!!
"Gary" wrote in message
news:i8f26m$j4...@dough.gmane.org...
Col Day wrote:
""Col Day"" wrote in message
news:23.81.45586.2820b...@pb1.pair.com...
PHP Test
This is an HTML line
This is a PHP line";
phpinfo();
?>
Thanks Gary!
Nice to know I'm not the only one who has struggled with the Basics.
Hopefully I can get my brain around it sometime soon.
Cheers
Col.
"Gary" wrote in message
news:i8f1r9$j4...@dough.gmane.org...
Col Day wrote:
Yes I did install apache then php, however I tried to follow the
Hi Shreyas,
Ok, as far as I can tell the script should show "This is an HTML line"
reflecting that I am seeing the HTML part of the script followed by "This is
a PHP line" to show that PHP is installed and working fine.
If I view the script directly in IE by going to http://localhost/phptest.
On 5 October 2010 09:07, Gary wrote:
> Does such a thing exist in php? My searches have lead nowhere.
>
> What I am looking for is a function which you would pass two parts of a
> path to (which might be a directory and a filename, say) and it would
> return a string containing the parameters sepa
On 5 October 2010 09:07, Gary wrote:
> Does such a thing exist in php? My searches have lead nowhere.
>
> What I am looking for is a function which you would pass two parts of a
> path to (which might be a directory and a filename, say) and it would
> return a string containing the parameters sepa
Col,
Can you let us know what exactly you see when you say
http://localhost:/phptest.php
?
Regards,
Shreyas
On Tue, Oct 5, 2010 at 4:20 PM, Col Day wrote:
>
> ""Col Day"" wrote in message
> news:23.81.45586.2820b...@pb1.pair.com...
>
> Hi all,
>>
>> After my escapades with the real basics a
The issue _WAS_ the firewall.
All sorted.
Thank you.
--
Richard Quadling
Twitter : EE : Zend
@RQuadling : e-e.com/M_248814.html : bit.ly/9O8vFY
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
""Col Day"" wrote in message
news:23.81.45586.2820b...@pb1.pair.com...
Hi all,
After my escapades with the real basics and realizing my laptop wasn't
logged on as Administrator, I now am trying to work out why this script
works sometimes but not others.
PHP Test
This
Hi all,
After my escapades with the real basics and realizing my laptop wasn't
logged on as Administrator, I now am trying to work out why this script
works sometimes but not others.
PHP Test
This is an HTML line
This is a PHP line";
phpinfo();
?>
If
(I filed bug #52782 about a month ago, but have not received any reply.
I am posting here to try and get some feedback on it.)
We have custom XML document and element classes that extend the original
DOMDocument and DOMElement classes for convenience. There is a class
that uses an instance of
44 matches
Mail list logo