Git: add vs push vs commit

git add adds your modified files to the queue to be committed later. Files are not committed git commit commits the files that have been added and creates a new revision with a log… If you do not add any files, git will not commit anything. You can combine both actions with git commit -a … Read more

Difference between array_push() and $array[] =

When you call a function in PHP (such as array_push()), there are overheads to the call, as PHP has to look up the function reference, find its position in memory and execute whatever code it defines. Using $arr[] = ‘some value’; does not require a function call, and implements the addition straight into the data … Read more

Git push doesnt do anything over HTTPS

Instead of using GIT_TRACE1, as suggested in comments, use (with a recent enough Git), GIT_TRACE2_EVENT set GIT_TRACE2_EVENT=1 git push # to cancel traces set GIT_TRACE2_EVENT= Check also the output of git remote -v to check: that origin2 does exist that it is an HTTPS URL

Ajax push system

You can achieve push within PHP but it won’t be the most efficient solution because to achieve push you need to maintain long running connections between your client and your server (HTTP or WebSocket connections). See: Long Polling/HTTP Streaming General Questions phpwebsocket php-websocket on github Ratchet how to implement comet in PHP – frequently linked … Read more