Two jailed after pleading guilty