PHP / Javascript:传递简单字符串,定义要包含的部分

My website is split into 4 divs: header, navigation, content, footer. There are 6 content sections: home, downloads, skills, practice, projects and about.

Inside navigation I have a menu that has linked button for each section.

Edit: I want to know how or what to use to pass data from one php file to another without using a form.

Using jQuery you can do this:

HTML:

<ul class="nav">
<li><a href="javascript:void(0);" name="section-filename-here">Item</a></li>
<li><a href="javascript:void(0);" name="section-filename-here">Item</a></li>
<li><a href="javascript:void(0);" name="section-filename-here">Item</a></li>
<li><a href="javascript:void(0);" name="section-filename-here">Item</a></li>
<li><a href="javascript:void(0);" name="section-filename-here">Item</a></li>
<li><a href="javascript:void(0);" name="section-filename-here">Item</a></li>
</ul>

<div id="content"></div>

Where you see name="section-filename-here", only input the name of the file without the .php extension as this can be added in the jQuery as in the example below

Javascript (jQuery/aJax):

$('ul.nav li a').click(function () {
    var thisSection = $(this).attr('name');
    $.ajax({
        url: "/path-to-sections/"+thisSection+".php",
        cache: false,
        success: function (data) {
            $('#content').html(data);
        },
        error: function () {
            // only put something here if you want to show an error
        }
    });
});