Anna is right. It's a little old-fashioned to use 'but for' in place of 'if it weren't for', but it's still very common, especially in the north of England.
"I would take my coat off but for the wind."
"I would take my coat off if it weren't for the wind."
I would like to take my coat off, but I'm not going to, because it's windy.
"I'd travel around the world but for the cost."
"I'd travel around the world if it weren't for the cost."
I would like to travel around the world, but I won't, because of how much it would cost.