You are here: Re: how to lock a block of php codes « All PHP « IT news, forums, messages
Re: how to lock a block of php codes

Posted by kelvin on 10/25/06 01:12

bob.chatman@gmail.com wrote:
> are you talking about 2 users calling a page at the same time?

Exactly.

A little more information:
The php page is actually called by PayPal IPN.
It works just fine in most case.
But a few times PayPal will call this page twice at the same time.
And it causes bugs. Because the first time information hasn't been
insert into the database, the second call happens.
So I want to find a method to avoid this.

Thank you a lot,
Kelvin

>
> kelvin wrote:
> > Hi,
> >
> > How to avoid one php page be called by 2 at the same time?
> > How to lock a block of codes in php?
> >
> > something like
> >
> > mutex.Lock
> > //...............
> > One service one time
> > //................
> > mutex.Unlock
> >
> > Any way to do this?
> >
> > Thank you,
> > Kelvin

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация