Missing sections, and undefined indices I'm migrating a drupal 7 site from one hosting provider to another.  I've hit some snags along the way.  The main one comes from page.tpl.php.

On the screen I see various messages such as:

Notice: Undefined index: highlighted in include() (line 126 of /public_html/cconn/modules/system/page.tpl.php).

Notice: Undefined index: sidebar_first in include() (line 138 of /public_html/cconn/modules/system/page.tpl.php).

Notice: Undefined index: sidebar_second in include() (line 144 of /public_html/cconn/modules/system/page.tpl.php).


In page.tpl.php the missing sections are defined as such:

&lt;div id="content" class="column"&gt;&lt;div class="section"&gt;
    &lt;?php if ($page['highlighted']): ?&gt;&lt;div id="highlighted"&gt;&lt;?php print render($page['highlighted']); ?&gt;&lt;/div&gt;&lt;?php endif; ?&gt;
    &lt;a id="main-content"&gt;&lt;/a&gt;


Does anyone have any thoughts on what's going on and how to remedy it?  The site itself does come up, but as mentioned with these large chunks missing.
It seems some of the variables are not defined properly. It is recommended to define variables properly to avoid some security vulnerabilities or bugs. Although PHP doesn't create any execution error.

To Solve this, you may choose any of below choices.

1.) Properly declare variables - Recommended 

$value = isset($_POST['value']) ? $_POST['value'] : '';


2.) Set custom error handler function

set_error_handler('myHandlerForMinorErrors', E_NOTICE | E_STRICT)

http://php.net/manual/en/function.set-error-handler.php


3.) Disable E_NOTICE from reporting - Fix

error_reporting( error_reporting() &amp; ~E_NOTICE ).