Is there any possible way to do this without JavaScript? (was without id)

Yes, I just read about that in your other thread. Well, if you want to stick to inline-styles only, then no, there’s no way to do this I’m afraid. :-\ I’d strongly suggest not to limit yourself by deliberately maintaining bad coding practices… also, what @PaulOB said of course.