My own personal idea, that I have been using for years, is a stretchable travel clothesline. It has hooks on each end so the line can go around a bar, or other suitable item, and then hook back onto itself. Because it is elastic, it can be stretched tight so when clothes are placed on it, it doesn't sag.
But sometimes it is impossible to find two hooks or bars solidly into a hotel wall, and close enough together, to use this clothesline. So in recent years I tied an old shoelace to one end of the line. That way I can tie the shoelace side first, then stretch the clothesline tight to attach to that hook or bar that was previously just out of reach.
Of course there is always the hotel room that has absolutely nothing that can be used. So I thought it was worth writing about an idea I recently read about...a tension curtain rod.
A tension curtain rod that can be opened to various lengths can be temporarily installed in the bathroom doorway or in the short hallway many rooms have as one enters the room. They are easy to pack, taking up very little room in a suitcase. And voila! Another place to hang clothes to dry.