1+ cos(theta)/Cos(theta) = tan^2(theta)/sec(theta)-1

I am having trouble understanding how this is verified by the previous answer. I am sorry I just want to understand this because I didn't see a tan^2 anywhere :/. Step by step how did you verify the above identity? Please?

recall your basic identities: sec^2 - 1 = tan^2

This follow from

sin^2 + cos^2 = 1
sin^2/cos^2 + 1 = 1/cos^2
tan^2 + 1 = sec^2