问题标签 [joomla3.2]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
2 回答
1212 浏览

php - Joomla 动态样式表在 css.php 文件中使用模板参数

我正在尝试使用动态 css.php 文件创建模板。我花了一整夜的时间在谷歌上搜索一个解决方案,以在用作 css 文件的 php 文件中调用 joomla 对象类。我知道我以前见过这样做,我只是从未注意它是如何完成的。这就是我到目前为止所拥有的。

注意 - 我不想使用 addstyledecloration 因为它在处理多个参数时太麻烦 *

索引.php:

配置.php:

模板-css.php:

0 投票
0 回答
1016 浏览

joomla - Joomla 3.2:未定义的偏移量:C:\Apache2\htdocs\ictogcio\libraries\cms\application\site.php 中的 0 行 479

我的网站 Joomla 3.2 网站最近运行良好,当我收到此错误消息并且事情不再起作用时。

0 投票
1 回答
1541 浏览

php - 在 PHP SQL Joomla 3 中查询多个表

我的 SQL 技能有点有限,但我可以弄清楚如何长期查询事物。有没有更好的方法可以在一个操作中执行下面的 SQL 语句,而不是将其分成三个?

最终结果我能够告诉 $t->group_id 等于什么。

0 投票
1 回答
444 浏览

php - Joomla 3.2 修改com_content/分类查询/添加过滤器

我想修改 com_content / category 以适应自定义数据库 /w 一些额外的字段(出于兼容性原因,从 J1.5 修改了 com_content)。

在components/com_content/models/category.php_buildContentWhere中 Joomla 1.5 中可用的功能已消失。

我不知道,我现在可以在哪里修改查询以添加额外的 WHERE 子句。我只想列出此类别中符合特殊条件的项目(作为 GET-Param 传递)。

0 投票
1 回答
6201 浏览

css - 在 Joomla 中更改徽标位置

我一直在使用 joomla 默认模板:Protostar。在模板管理器中,我设置了一个徽标,它出现在每个页面的左上方。如何将徽标向右移动 100 像素?

我在 localhost 中运行 joomla 3.2.1。

0 投票
1 回答
678 浏览

joomla - Joomla 3.2 - 从另一个组件内的特定菜单项 ID 加载组件视图

我正在尝试了解 Joomla 3.2 的新框架,并在自定义组件(我们称之为com_custom)中开发一种功能/特性,该组件可以使用类别博客的菜单项 ID 在 com_custom 的视图中加载 com_content 的类别博客视图!

我在这里和网络上看到了很多代码,它们只加载“导入”组件的默认视图,而不是在导入组件的指定菜单参数中指定的视图。此外,这些代码中的大多数都使用了不推荐使用的函数,所以我现在很迷茫。

所以我需要能够添加的是:

  1. 在 com_custom 的当前视图中包含一个类别博客视图(例如来自菜单项 id 223)。
  2. 它应该导入类别博客的菜单项的所有参数设置。
  3. 它不应该在 iFrame 中

任何帮助深表感谢!!!

0 投票
1 回答
1503 浏览

joomla - Joomla - saved failed with the following error super user

I am getting the above error while saving an article. It occurs on few articles and not all.

As part of the context to this problem. I migrated all articles from a joomla 1.5 installation to a joomla 3.x installation. In the 1.5 installation, everything works fine but after migration, only few articles seem like that .. It doesn't say what the error is else I'd be able to figure it out.

Can someone help me diagnose this problem.

UPDATE: Just happens with two categories and not others.

UPDATE 2: Better Explanation

Articles in uncategorized works correctly. No problems there. As soon as I put these articles in a new category or existing category where it should actually be, it gets saved there but then the above error comes up.. viz. 'Save failed with the following error:' but it doesn't mention what error. Any modification gets saved without an issue as per my latest understanding.

0 投票
1 回答
839 浏览

joomla - 在本地主机上将大型扩展上传到 joomla 时出错

当我尝试在本地主机上上传 Akeeba Backup 扩展时,出现以下错误:“将此文件上传到服务器时出错。”

我尝试上传 JCE 编辑器,效果很好。我了解出现此错误是因为我无法上传大于 X MB 的扩展名(JCE 为 1.5MB,Akeeba 为 2.25MB)。所以我的猜测是我不能上传大于 2MB 的扩展。

研究我遇到了两种解决方案,都不适合我。

第一个解决方案:在文件 ini.php 中找到以下行upload_max_filesize = xM并将“x”替换为值 10(例如)。我在 ini.php 文件中找不到上述行。

第二种解决方案:在您的 .htaccess 中添加以下内容:

添加了代码,什么也没发生。

我正在使用 Joomla 3.2

0 投票
1 回答
1389 浏览

joomla - 从另一个组件获取参数

我有两个引用外部数据库的自定义组件。在 component1 中,我设置了连接到该外部数据库所需的参数。

有没有办法可以在component2中使用component1中的参数集?

我在组件2中的模型中的代码:

告诉我一个致命错误:

我应该停止偷懒并在component2中重新定义相同的参数,还是有合理的解决方案?

0 投票
1 回答
310 浏览

php - 剥离 HTML 字符以显示图像

我正在尝试显示来自 Joomla 3.2 的介绍图像,它保存在表中“图像”列中的数据库中。但是,介绍图像和全文图像保存在同一列中,因此当我尝试回显该列时,我只是获取值。

我看到了这个值:

这将输出以下内容:

{"image_intro":"images/stories/imagetest.jpg","float_intro":"","image_intro_alt":"","image_intro_caption":"","image_fulltext":"","float_fulltext":"", "image_fulltext_alt":"","image_fulltext_caption":""}

理想情况下,我希望能够剥离 html 并只显示“image_intro”的值,然后我可以将其用于 img src。以上似乎是 JSON 格式,但我不知道如何回显第一个值。