In Drupal 7, there is a user login block. We can customize that block using the hook_form_FORM_ID_alter(). You can create a custom module or implement it directly in the theme template.php.
I have a custom form and i render the form using drupal_get_form() inside the .tpl.php. One day, i find that when the submission could not pass the validation, only the failed field was highlighted but without the error message. Then i find the following post suggesting that i should called the drupal_get_form() in the .module file or preprocess function instead of the .tpl.php. form_set_error Not displaying error after invalid form submission
So i put the drupal_get_form() call in the preprocess function and set the form in the $vars so it could be printed in the .tpl.php. But that still could not solve the problem. Finally i come up with a simple solution which is just adding the following line in the .tpl.php.
Sometimes we may even want edit the template file(.tpl.php) for specific content such as a content type node view. In Omega theme, there are different regions and by default they will use the following template files.
Context could help you to manage the layout. In the past, i would use the Page manager of Chaos Tool Suite and Panels to control the layout but now i have completely move to the Context module. You can decide which regions should be hidden.
Sometimes we may want to render a data without the theme page template. This is useful when we want to retrieve data through asynchronous call such as Ajax.