Fasting is an excellent physical/spiritual discipline. It works with food, because we begin to learn to deny our bodily urges. It also works with fasting from other things to which our flesh is attached, internet, TV, etc.
My thought was, when reading the original post, was that there is an evil spiritual force at work. These kind of entrenched problems generally have a source in a previous exposure to a sinful pathway that has taken root into the soul. Pornography is the most common.
This is great advice. It sheds light on the constant struggle we have between the Spirit and the Flesh, and how the Spirit within us is the conquerer. We cannot win this battle by strength of the will, however much we desire it.
It sounds like you will need to avail yourself of some other opportunities for confession. I also recommend the sacrament of the sick, which many parishes offer on the first Friday of every month, or upon request. The sacrament forgives sins, and can help carry you to the next confession.
I can definitely appreciate this dynamic! I think there are times when substitution works better than surfing the urge. This is more difficult in the middle of the night! I have had to fill my day with activity and get myself very physically tired so I sleep through the hard times.