Changed appId to accessKeyId

Change-Id: I441fbd079e5989a842603dccd25e9530a6b2fad9
Done some refactoring

Change-Id: I620743dfc5e7ff7f623664596b58378635ee4c25
CS fixes

Change-Id: I3dedaa59f1cfb244e14e2cbffdbde06be32bba3a
Fixed PHP constant using

Change-Id: I4773b871095fe6856fac90f23543af87ddf4e989
CS fixes

Change-Id: I0a1f750ce054604ddb0226dd8d62921865fdbec9
PHP 5.3 fix

Change-Id: I3f4eea6ac4e789c981990166525ee48a8316baa2
Trailing spaces fix

Change-Id: Ia3ae9ddb428b2dcc949ac63ad4b926ebebd764d6
Trailing spaces fix

Change-Id: Ie6f1bfa6613d60277443960c94c6390d65af085e