Generally I prefer to use both onions and garlic in their fresh state. But I have found that gently frying dried garlic and onion pieces 'till golden makes a lovely garnish for Indonesian fried rice (Nasi Goreng) (thanks to Charmaine Solomon and her "Complete Asian Cookbook" for that tip, and many others).