簡體   English   中英

AddThis插件在模式窗口中不起作用

[英]AddThis plugin doesn't work in modal window

我的任務是創建包含內容(有關游戲的一些詳細信息)的模式窗口,該窗口將在單擊行時打開(在“搜索”頁面上:1行-1個游戲)。 我嘗試從aspx頁面獲取的內容。 因為此頁面是從附加了所有腳本的母版頁繼承的(當我打開此模式時,所有腳本都被再次加載,這破壞了頁面的布局),我僅為此模態窗口創建了第二個母版頁,其中僅包含必需的文件,腳本等。

問題:一切都很好,只有一件事:在Page Searcg.aspx和模態窗口中,我使用addThis插件 在搜索頁面上,所有內容均已初始化,但是當我打開模式時-addThis插件未加載所需的圖標等。

我如何使用插件:

                    <!-- AddThis Button BEGIN -->
                    <div class="addthis_toolbox addthis_default_style">
                        <a class="addthis_button_facebook"></a>
                        <a class="addthis_button_email"></a>
                        <a class="addthis_button_twitter"></a>
                        <a class="addthis_button_print"></a>
                        <a class="addthis_button_compact"></a>
                        <script type="text/javascript">var addthis_config = { "data_track_clickback": true };</script>
                        <script type="text/javascript" src="http://s7.addthis.com/js/250/addthis_widget.js#username=username"></script>
                    </div>
                    <!-- AddThis Button END -->

如果要在模式窗口中動態加載按鈕,則需要調用addthis.init()和/或addthis.toolbox()來渲染div。 這是來自AddThis網站的更多信息:

http://support.addthis.com/customer/portal/articles/1293805-using-addthis-asynchronouslyly

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM