-2

我恳请您帮助我找出我的应用程序不断刷新的代码中的原因。这不允许我导航到其他页面,我是 php 的学习者,我怀疑这可能是问题,帮助。会不会是php安排的问题?

这是 index.php 中的代码

            <script type="text/javascript">
$(document).ready(function() {
    $('#premium_b').click(function(e) {
        e.preventDefault();
        $('#tabs').tabs( "select" , 4 );
    });
    $('#tabs').bind('tabsselect', function(event, ui) {
        if (ui.index == 4 )
            $('#premium_b').css ('display', 'none');
        else
            $('#premium_b').css ('display', 'block');
    }); 
});
</script>
<div id="bloc_134" class="li_bloc"><ul class="menu"><li><a href="http://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_homepage&amp;tab=contact_form_homepage&amp;page_id=" title="contact_form_homepage" class="fbtab">Home</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_config&amp;tab=contact_form_config&amp;page_id=" title="contact_form_config" class="fbtab">Config</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_export&amp;tab=customize_css&amp;page_id=" title="contact_form_css" class="fbtab">Customize</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_export&amp;tab=contact_form_export&amp;page_id=" title="contact_form_export" class="fbtab">Export</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_premium&amp;tab=premium&amp;page_id=" title="contact_form_premium" class="fbtab">Premium</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_stats&amp;tab=contact_form_stats&amp;page_id=" title="contact_form_stats" class="fbtab">Statistics</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_doc&amp;tab=doc&amp;page_id=" title="contact_form_doc" class="fbtab">Doc</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_about&amp;tab=contact_form_about&amp;page_id=" title="contact_form_about" class="fbtab">About</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_other_app&amp;tab=contact_form_other_app&amp;page_id=" title="contact_form_other_app" class="fbtab">Other Apps</a>
            </li>
            <li><a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_faq&amp;tab=contact_form_faq&amp;page_id=" title="contact_form_faq" class="fbtab">FAQ</a>
            </li>
            </ul>
            <a href="https://apps.facebook.com/mtkenya-dev/index.php?p=contact_form_premium&amp;tab=premium&amp;page_id=" title="Upgrade to Premium to get white branding and help us improve your favourite apps! : Click her" id="premium_b">Upgrade to Premium to get white branding and help us improve your favourite apps! : Click her</a>
            <div class="clear"></div>
            </div>
                </div>
    <div id="alerts">
            </div>
    <div id="zone2" class="li_zone li_x1 li_y2">

<div id="contact_form_about"><div class="zone2"> 
            </div></div>


<div id="contact_form_config"><div class="zone2"><script type="text/javascript">
function refreshApp (url) {
    $.get(url, function(data) {
      $('*').html(data);
    });
}
$(document).ready(function() {
var options = { 
success: showResponse,
beforeSubmit: disableButton
}; 
$('#tab_info_form_0').ajaxForm(options);
});

function addToPage() {
var obj = {
  method: 'pagetab',
  redirect_uri: 'https://apps.facebook.com/mtkenya-dev/?page_id=#contact_form_config',
};

FB.ui(obj);
}
</script>
<script>top.location.href='https://www.facebook.com/dialog/oauth?client_id=461688580525581&redirect_uri=https%3A%2F%2Fapps.facebook.com%2Fmtkenya-dev%2F%3Ftab%3Dcontact_form_config&scope=email,manage_pages'</script></div>
            <div class="zone2"><script type="text/javascript">
$(document).ready(function() {
var options = { 
success: showResponse,
beforeSubmit: disableButton
}; 
$('#contact_form').ajaxForm(options);
$('#customize_css').ajaxForm(options);
});
</script>
<div id="bloc_133" class="li_bloc"><p>Page non trouv?e</p>
            </div>
            </div>
            </div>


<div id="contact_form_css"><div class="zone2"><script type="text/javascript">
function refreshApp (url) {
    $.get(url, function(data) {
      $('*').html(data);
    });
}
$(document).ready(function() {
var options = { 
success: showResponse,
beforeSubmit: disableButton
}; 
$('#tab_info_form_0').ajaxForm(options);
});

function addToPage() {
var obj = {
  method: 'pagetab',
  redirect_uri: 'https://apps.facebook.com/mtkenya-dev/?page_id=#contact_form_css',
};

FB.ui(obj);
}
</script>
<script>top.location.href='https://www.facebook.com/dialog/oauth?client_id=461688580525581&redirect_uri=https%3A%2F%2Fapps.facebook.com%2Fmtkenya-dev%2F%3Ftab%3Dcontact_form_css&scope=email,manage_pages'</script></div>

            </div>

            <div id="contact_form_doc"><div class="zone2"><script type="text/javascript">
$(function() {
    $("#bloc_223").tabs({
        ajaxOptions: {
            error: function( xhr, status, index, anchor ) {
                $( anchor.hash ).html(  "Couldn't load this tab. We'll try to fix this as soon as possible. ");
            }
        },
        cache: true
    });
});

</script>

            </div>
            </div>


<div id="contact_form_export"><div class="zone2"><script type="text/javascript">
function refreshApp (url) {
    $.get(url, function(data) {
      $('*').html(data);
    });
}
$(document).ready(function() {
var options = { 
success: showResponse,
beforeSubmit: disableButton
}; 
$('#tab_info_form_0').ajaxForm(options);
});

function addToPage() {
var obj = {
  method: 'pagetab',
  redirect_uri: 'https://apps.facebook.com/mtkenya-dev/?page_id=#contact_form_export',
};

FB.ui(obj);
}
</script>
<script>top.location.href='https://www.facebook.com/dialog/oauth?client_id=461688580525581&redirect_uri=https%3A%2F%2Fapps.facebook.com%2Fmtkenya-dev%2F%3Ftab%3Dcontact_form_export&scope=email,manage_pages'</script></div>


    <div id="footer" class="li_zone li_x1 li_y4">&nbsp;</div>
</div>

    </body>


</html>
4

1 回答 1

0

好吧,我看到了 3 次:

top.location.href=....

没有任何条件且不在函数调用中。那肯定会让你的页面跳动。

于 2012-07-03T22:23:00.350 回答