I have HR-Attendance application developed in PHP/MYSQL having 150 users working remotely from different different locations, some times the internet is not available on remote area's, they don;t able to login and check the status of their salaries and many many features. This application requires to work offline on different different machines and update the online server, when its gets the internet connection. Please let me know how we can syncronize the local data with the online server and vice-versa.
That depends on the exact nature of the database design, but generally speaking you add all new data to the database when the internet becomes available to the offline computer, then have an application that updates the database either as new data is inserted (using triggers) or at specified times. The problem with doing the work offline is that if someone updates the database while someone is working on the same record offline, the data can become corrupt. You can design locks into the system, something like a source control system, so that if one person "checks out" a record, no one else can access it for changing, only for looking at. But that may bot solve your problem.