Same question as imjason, what's a long drive? Also, what's the budget per night, and does it have to be a hotel, or are you willing to rent a condo or semi-camp at all? What time of year (most places have much higher prices for the main tourist season).
Curry Village is inside the park and relatively cheap, if you're willing to stay in a fabric tent, and deal with shared bathrooms. They also have rooms, but I'm guessing those are outside your desired budget.
You can also rent condos & cabins inside Yosemite, but maybe 20 minutes away from the Valley, near the base of Glacier Point Road. Try HERE or HERE. I'd guess there are more of them in that particular development you can rent from other sources too, or are private homes that are rented out by individuals.
You can go further out and probably get cheaper prices of course, but maybe one of these will fit the bill.