The contracts herein provided for may stipulate that the respective city, county, railroad company, street railway or other company, or parties interested, or any of them, shall pay a certain part or portion of the whole contract price or cost of the work, including damages; or may stipulate that each shall construct, or pay for the construction of, a certain part or portion of the work, and may otherwise provide for the payment of the damages. When any railroad company, street railway or other company, or other parties interested, agree to pay a certain part or portion of the cost of the entire work, they shall pay such part or portion into the proper city treasury; and upon said payment, the city treasurer shall be liable therefor, and he shall pay the same over to the contractor, as may be provided in the contract; but the amount to be paid by the respective county shall be paid directly to the contractor, as may be provided by the said contract. The said agreements may also provide for the maintenance of the said viaducts and bridges, after their erection. All contracts provided for by this act shall be binding upon the parties thereto, their lessees, successors, heirs and assigns.
53 P.S. § 2506