The CP-violating charge asymmetry in $B^{pm}rightarrow phi K^{pm}$ decays is measured in a sample of $pp$ collisions at 7 TeV centre-of-mass energy, corresponding to an integrated luminosity of 1.0 fb$^{-1}$ collected by the LHCb experiment. The result is $mathcal{A}_{CP}(B^{pm}rightarrow phi K^{pm}) = rm 0.022pm 0.021 pm 0.009$, where the first uncertainty is statistical and the second systematic. In addition, a search for the $B^{pm}rightarrow phi pi^{pm}$ decay mode is performed, using the $B^{pm}rightarrow phi K^{pm}$ decay rate for normalization. An upper limit on the branching fraction $mathcal{B}(B^{pm}rightarrow phi pi^{pm})< 1.5times 10^{-7}$ is set at 90% confidence level.