you will proberbly have to put some de foam on the shampoo to stop the foaming and then try to get rid of the blue stain, it depends what the carpet is made from, try to have a look at the bottle of shampoo if possible I would try an oxy type cleaner but make sure you test the area first. You may find the colour goes as you rinse out all the soap. It does take quite a long time though depending on how much has been spilt you will have to tell the customer you may have to return a few times and a dirt spot may keep appearing until all the soap has been removed. Hope this helps.
Rob