我想为我的 Joomla 使用视差。
特别是这个:https://github.com/IanLunn/jQuery-Parallax
如何将这些插入到我的 joomla 页面中。
<script type="text/javascript" src="scripts/jquery.parallax-1.1.3.js"></script>
<script type="text/javascript" src="scripts/jquery.localscroll-1.2.7-min.js"></script>
<script type="text/javascript" src="scripts/jquery.scrollTo-1.4.2-min.js"></script>
我将此模板与 Helix Framework 一起使用
最佳答案
Joomla 文档中解释了将 Java 脚本库添加到 Joomla 安装(模板或组件)的正确方法:
<?php
$document = JFactory::getDocument();
$document->addScript('/media/system/js/sample.js');
?>
关于javascript - Joomla 3.x : How to add or Link to a external javascript file,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28756219/