When a cause shall be determined, the clerk of the court, and the justice of the peace in cases had before him, shall tax the costs of the case and make out a bill thereof, specifying therein each section of the law, and each paragraph or subdivision of section, if any, by virtue of which each fee or item of costs therein is charged or taxed, and he shall file the same with the papers in the cause.