When it comes to 3rd party lenses they have to be considered on an model by model basis.
In fact the same is true for camera maker lenses. For instance Nikon makes the $170 -
Nikon 70-300mm f/4-5.6G AF Nikkor SLR Camera Lens but it won't auto focus on a D5100 because the lens does not have a focus motor in it. Also the lens has low quality optics, and no VR, both that have more to do with it's price than the lack of an inexpensive auto focus motor.
Nikon also makes the $590 -
Nikon 70-300mm f/4.5-5.6G ED IF AF-S VR Nikkor Zoom Lens for Nikon Digital SLR Cameras that is one of Nikon's best lens values, because it has way better optics, VR, and build quality.
Which brings up something you may not be aware of.
The Nikon D5100 is part of Nikon's lower tier of compact entry-level DSLR cameras. To make cameras in that tier compact Nikon does not include an auto focus motor/auto focus screw drive mechanism. Consequently you would mostly be interested in buying lenses that have an auto focus motor in them. AF-S lenses from Nikon, HSM lenses from Sigma, etc.
The Nikon D7000 you were referred to is in the Nikon's upper tier of entry-level DSLR cameras, and
does have an auto focus motor/auto focus screw drive mechanism. so the D7000 can auto focus older AF Nikon lenses and 3rd party Nikon mount lenses that have a slot for the auto focus screw-drive mechanism.