index.php里面的所有页面好还是坏?

时间:2016-01-24 07:37:44

标签: jquery navigation

我只想问这是不是好https://jsfiddle.net/grzyp7wL/

制作这样的导航菜单,将它们全部放在同一页面中还是像index.php contact.php about.php等分割一样好吗

提前致谢:)

您还可以在此处查看代码:

function toolbar_section()

if(isset($_GET['action']))
{
    if($_GET['action'] == 'news')
    {
    //news page
}
else if($_GET['action'] == 'about')
    {
    //about page
}

function content_section()

<style>
    .selecthidden {display:none;}
    .selectactive {display:block !important;}
</style>

<script>
    $(document).ready(function(){
    $('select#studioselect option').each(function(){
            $(this).addClass(selectactive);
            $.not(this).removeClass(selectactive);
    });
    });
</script>

<select id="studioselect">
  <option value="select studio">Select Studio</option>
  <option value="neutral bay">Neutral Bay</option>
  <option value="manly">Manly</option>
  <option value="bondi junction">Bondi Junction</option>
  <option value="bondi beach">Bondi Beach</option>
  <option value="south melbourne">South Melbourne</option>
  <option value="fitzroy">Fitzroy</option>
  <option value="north perth">North Perth</option>
  <option value="myaree">Myaree</option>
  <option value="wellington">Wellington</option>
</select>
<div style="margin-top:20px;">
<a id="button-neutralbay" class="qbutton selecthidden" href="#" >Neautral Bay</a>
<a id="button-manly" class="qbutton selecthidden" href="#" >Manly</a>
<a id="button-bondijunction" class="qbutton selecthidden" href="#" >Bondi Junction</a>
<a id="button-bondibeach" class="qbutton selecthidden" href="#" >Bondi Beach</a>
<a id="button-southmelbourne" class="qbutton selecthidden" href="#" >South Melbourne</a>
<a id="button-fitzroy" class="qbutton selecthidden" href="#" >Fitzroy</a>
<a id="button-northperth" class="qbutton selecthidden" href="#" >North Perth</a>
<a id="button-myaree" class="qbutton selecthidden" href="#" >Myaree</a>
<a id="button-wellington" class="qbutton selecthidden" href="#" >Wellington</a>
</div>

0 个答案:

没有答案