简体   繁体   English

最新版本的joomla3中的joomla模块-垂直滚动最新文章joomla模块中出现错误

[英]Error in joomla module- vertical-scroll-recent-article-joomla-module with the latest version joomla3

i am getting start with joomla 3 and completely new to joomla 我开始使用joomla 3,对joomla来说是全新的

Set up joomla in localhost . 在localhost中设置joomla。 i tried to install vertical-scroll-recent-article-joomla-module with the latest version 我试图用最新版本安装Vertical-scroll-recent-article-joomla-module

i got 3 error 我有3个错误 在此处输入图片说明

1 and 2nd error gone when change the function getArticleList and loadScripts change to static function. 更改函数getArticleList和loadScripts更改为静态函数时,第1和第2个错误消失了。 Do we really need to change inside a module readily available? 我们真的需要在易于使用的模块内部进行更改吗?

i dont have any idea how to solve the 3rd 我不知道如何解决第三

ERROR Strict standards: Only variables should be assigned by reference in C:\\wamp\\www\\joomla\\modules\\mod_vertical_scroll_recent_article\\helper.php on line 24 错误严格标准:第24行上的C:\\ wamp \\ www \\ joomla \\ modules \\ mod_vertical_scroll_recent_article \\ helper.php中的引用只能分配变量

public static function loadScripts(&$params)
    {
    line 24:    $doc = &JFactory::getDocument();
        $doc->addScript(JURI::Root(true).'/modules/mod_vertical_scroll_recent_article/mod_vertical_scroll_recent_article.js');
    }

i tried removing '&' the error gone ,but the view is not rendering in the front end 我试图删除'&'错误消失了,但视图未在前端渲染

Try this, 尝试这个,

public static function loadScripts(&$params)
    {
       $doc = JFactory::getDocument(); //On line 24 remove the & 
       $doc->addScript(JURI::Root(true).'/modules/mod_vertical_scroll_recent_article/mod_vertical_scroll_recent_article.js');
    }

This module is written for Joomla lower versions that why this kind of errors. 此模块是为Joomla较低版本编写的,它说明了为什么会出现这种错误。

Hope its works.. 希望它的作品..

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM