Normally deleting a commit from a published branch is a bad idea, because it can cause problems for anyone else sharing that branch. But in this case, leaving your credit card number is probably worse.
If the commit containing the CC number is the HEAD of the branch, then you can amend the commit by editing that PHP file and then committing via:
git commit --amend
If the bad commit is not the HEAD of the branch, then you can try doing an interactive rebase via:
git rebase -i HEAD~10 # replace 10 with however far you need to go back
This will bring up a list of commits on your branch, oldest to newest. Find the commit containing the credit card, and change pick to edit for every commit from that point down the list. You need to remove that information from every commit since you first added it to the history.
Note that since you have rewritten the history of your branch, you will have to force push it to the remote using:
git push --force origin master