소스 검색

move fader.js to the loader function

Signed-off-by: Suki <[email protected]>
Suki 10 년 전
부모
커밋
77e190a711
2개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 0
      Sources/BoardIndex.php
  2. 0 1
      Themes/default/BoardIndex.template.php

+ 2 - 0
Sources/BoardIndex.php

@@ -130,6 +130,8 @@ function BoardIndex()
 
 	// Allow mods to add additional buttons here
 	call_integration_hook('integrate_mark_read_button');
+
+	loadJavascriptFile('fader.js', array('default_theme' => true, 'defer' => true), 'smf_scripts');
 }
 
 /**

+ 0 - 1
Themes/default/BoardIndex.template.php

@@ -38,7 +38,6 @@ function template_newsfader()
 					</ul>
 				</div>
 			</div>
-			<script src="', $settings['default_theme_url'], '/scripts/fader.js"></script>
 			<script><!-- // --><![CDATA[
 				// Create a news fader object.
 				var oNewsFader = new smc_NewsFader({