— The original complaint contained two connts, to which two more were added by amendment. For the purposes of this appeal, it is unnecessary to notice or treat more than one of the counts, as each count is subject to the same defect pointed out in this opinion and in the demurrer to each.
. Count three was as follows: “The. plaintiff claims of the defendant the further sum of one thousand dollars, damages. The plaintiff avers that on, to wit, October, 1907, and continuously for' some time thereafter in the year 1907, by and through the agents or contractors of the defendants, acting within the line and scope of their authority for the defendants began to fill or change a part of the old bed of Valley Creek, or fill in, or change the bed of a part of Valley Creek and preparing to make changes and plans to grade and construct the railroad for the defendants through or adjoining the following tract of lands: East half of the Southwest •quarter, Section 32, Township 18, Range 4 West, in Jefferson County, Alabama, near Bessemer, and the plaintiff avers that at said time the plaintiff had on said lands or a portion of the said lands, his crops for the year 1907, which consisted of- corn, cotton, peas, hay and other crops and which said crops were protected from stock and cattle by fencing, ditches or embankments, and which said means securely protected his said -crops from cattle and stock, and plaintiff avers that defendant’s said agents or contractors while acting within the line and scope of their authority for defendant in filling in said Valley Creek, or in filling in and changing a portion of said Valley Creek and in making plans as ■aforesaid for the grading, and construction of the said railroad, or in changing the said Valley Creek, defendant’s said agents or contractors so negligently destroyed the embankments, or fencing, or the ditches inclosing *104and securing the plaintiff’s said crops front cattle and stock and thereby and as a proximate consequence thereof the cattle and stock were turned in on plaintiff’s said crops, his corn was destroyed and damaged, his peas and hay destroyed and damaged, plaintiff was greatly inconvenienced and worried in keeping out the cattle and stock, vexed and lost rents on the lands for the year 1907, all to his damage as aforesaid.”
It will be observed that this count seeks to charge the defendant railroad companies for damages, the result of the negligent or wrongful acts of their “agent” or “contractors,” in the construction of the roadbed, in that by reason of such wrongful acts in the construction of the roadbed, grading, filling, etc., the ponds, ditches, or embankments, which enclosed plaintiff’s crops, were removed, and in consequence cattle and other live stock trespassed* upon and destroyed plaintiff’s crops, to his. damage, etc.
Each count attempts to fix liability on the railroad companies as principals, for the wrongful act of their’ “servant or contractor.”
While the master or principal may be liable for the acts of both his servants and his contractors, yet his liability for the acts of the two, depends upon entirely different conditions and state of facts. He is liable for any wrongful act of his agent or servant, committed within the line of the employment • and within the scope of the powers or duties of the servant or agent. The maxim, “qui facit per alium facit per se,” applies in this case. But the master, principal, or contractee, is not so liable for an injury, the result of negligence or wrongful act of the contractor, or the latter’s agents or servants, though the act complained of is collateral to the work to be done under the contract, unless the work to be done *105is a nuisance per se, or is of such kind or class that the doing of it, however carefully or skillfully performed, will probably result in damage, or is necessarily and intrinsically dangerous, or the law imposes a duty upon the master, principal, owner, or contractee, to keep the subject of the work in a safe condition. As to this class of liabilities a different rule prevails — the rule of “respondeat superior” applies. — Wood on Master & Servant (2nd Ed.), 609 et seq.; 16-Am. & Eng. Ency. Law, 192; Birmingham Co. v. McCary, 84 Ala. 469, 4 South. 630; Midland Co. v. Martin,. 100 Ala. 511, 14 South. 401; Drennen v. Smith, 115 Ala. 396, 22 South. 442; Chatt. Co. v. Behrman, 136 Ala. 510, 35 South. 132; Scarbrough’s Case, 94 Ala. 499; 10 South. 316; R. & D. R. R. Co. v. Chasteen, 88 Ala. 591, 7 South. 94.
The liability of the defendants being thus materially 'different in each of the two cases, the defenses, if any existed, being therefore necessarily different, the two actions should not thus be alleged in the same count in the alternative; and if it could be said that only one cause of action was alleged or attempted to be alleged thus in the altern ative,Alien the'count Avas not sufficient to show cause of action under both of the alternatives, and hence was bad on demurrer. — 3 Mayfield’s Dig., p. 754, § 75. '
Appellant says that his complaint does not allege that the act complained of was that of an “independent contractor,” but only that of a “contractor.” The answer to this is, that if there be any difference in the two terms, the pleadings will be construed most strongly against the pleader* — Lovell v. DeBardelben, 90 Ala. 13, 7 South. 756; Lacey’s Case, 4 Ala. 88. Each count of the complaint containing the averment that the wrong complained of was the act of defendants’ “agent or contractor,” and this averment being the basis of a recovery *106under any count — and the demurrer going to this ground —it follows that the demurrer was properly sustained to each count.
But if any one ground of the demurrer was properly sustained to any one count of the complaint, though improperly- sustained as to others, and the plaintiff declined and refused to plead further, by amending such count, or striking it out so as to leave his complaint good, and suffered judgment to be rendered against him for declining to plead further, this court, on appeal from that judgment, must sustain the trial court, though some of the counts are good and not subject to demurrer. — Greening v. Brown, Minor, 353; Montgomery Co. v. Dorman, 78 Ala. 189; Guilford v. Kendall, 42 Ala. 654.
The proper practice in such cases, as pointed out by this court long ago, is, if a party desires to avail himself of the error of the trial court in sustaining grounds of demurrer not properly assigned, he should first offer to amend so- as to make his complaint good, if any part be bad on demurrer assigned, and having done this, or if the court refuses to allow him to amend without doing so as to the grounds not well taken, then he could place himself in a position to have the action of the court re-, viewed on the assignments which were erroneously sustained. — Authorities supra.
It follows that the judgment of the lower court must be affirmed.
Affirmed.
Dowdell, C. J., and Simpson,and Denson, JJ., concur. •