1/*---------------------------------------------- 2 JavaScript ( jQuery ) Template 3 4 jQuery1.7+ 5----------------------------------------------*/ 6 7/*---------------------------------------------- 8 ãµã¤ãå ã§ä½¿ç¨ããObjectã®ä½æ 9 defObj.param : 颿°éã§å ±éãã¦ä½¿ç¨ãããã©ã¡ã¼ã¿ã¼ 10 defObj.func : 颿° 11----------------------------------------------*/ 12var defObj = {}; 13defObj.param = {}; 14defObj.func = {}; 15 16defObj.param = { 17 18 /* 19 ä»å¾å¿ è¦ã«ãªããããããªããã®ã¯æ®ãã¦ããã¾ãã 20 å¿ è¦ã«ãªãã°ã³ã¡ã³ãã¢ã¦ããå¤ãä½¿ç¨ 21 */ 22 23 //import js 24 arrJs : [ 25 'jquery.linkbox.js', 26 //'jquery.smooth-scroll.js', 27 'jquery.megamenu.js', 28 'jquery.matchHeight-min.js' 29 ] 30}; 31 32/*---------------------------------------------- 33 ãã®ãã¡ã¤ã«ãèªã¿è¾¼ã¾ããã¿ã¤ãã³ã°ã§å®è¡ããã颿° 34----------------------------------------------*/ 35importJs ( defObj.param.arrJs ); 36 37/*---------------------------------------------- 38 颿°ä¸è¦§ 39------------------------------------------------ 40 1. åºæ¬çã«defObj.func Objectã«ã¡ã½ããã追å 41 2. ã¡ã½ããã¨ååã®é¢æ°ãä»£å ¥ 42 3. ã¡ã½ããéã§ã®ä½¿ç¨ãæ±ããããªã颿°ã¯ 43 ã¡ãã½ãå ã§é¢æ°å®ç¾© 44 4. defaultå¤ãè¨å®ããå ´åã¯ã$.extendãä½¿ç¨ 45----------------------------------------------*/ 46 47/*---------------------------------------------- 48 @disc : 弿°ã®é åã«è¨è¿°ãããjsãæ¸ãåºã 49 @param : - 50 @ret : - 51----------------------------------------------*/ 52defObj.func.importJs = importJs; 53 54function importJs ( param ) { 55 56 var jsfiles = param; 57 58 function lastof ( pa ) { 59 return pa[pa.length - 1]; 60 } 61 62 function dirname ( path ) { 63 return path.substring( 0, path.lastIndexOf('/') ); 64 } 65 66 var prefix = dirname ( lastof( document.getElementsByTagName('script') ).src ); 67 for( var i = 0; i < jsfiles.length; i ++ ) {
68 document.write('<script type="text/javascript" src="' + prefix + '/' + jsfiles[i] + '"></script>'); 69 } 70}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.