why want my truck go in to gear when i apply the brake on 2001 Mazda Tribute

what is causing my 01 mazda tribute not to go into gear when i apply the brake and start to put in it something simple to fix or will it cost alot.the problem just occured last night after i came in from work and went to pick my daughter up from work.never had this problem before now

Asked by for the 2001 Mazda Tribute
shift lock out solenoid or pwr to it. see if the fuse is good and if so ck your brk lights,poss bad brk light switch
thanks for your answer,but come to find out,it was the the gear shift cable had broke.thanks everyone for your time and answer to my question
Qualified Local Mazda Shops
Qualified Mazda Shops For This Repair
921 N Parker St
RepairPal Shop Scorecard
Technical Ability
Tools & Equipment
Customer Service
Customer Amenities
(714) 486-0367
1 more answer , 1 more comment
It could be the brake pedal position switch. It sends a signal saying the pedal is depressed allowing you to shift from park into gear.;_ylt=A0PDoS4geeVQE1UAkhmJzbkF;_ylu=X3oDMTBlMTQ4cGxyBHNlYwNzcgRzbGsDaW1n? It works with the shift interlock preventing shifting out of park without a foot on the brake pedal.
thanks for your responce to my question,come to find out it was the gear shift cable had broke