Questions tagged [php]

PHP is a server-side scripting language designed for web development but also used as a general-purpose programming language. Joomla is based on PHP.

Filter by
Sorted by
Tagged with
0 votes
0 answers
35 views

How to remove CSS and JS from Joomla 4 header?

I want to properly remove CSS and JS links from Joomla 4 header For example I did not want: <link href="/newer/media/vendor/fontawesome-free/css/fontawesome.min.css?5.15.4" rel="...
user avatar
  • 73
0 votes
1 answer
40 views

How do I create parameters in a Joomla module depending on another parameter / number?

I'm trying to create a Joomla module for typical CSS cards, but I want to make the number of cards dependent on a number input from the user. For example the user wants 5 cards so in the parameter ...
user avatar
0 votes
2 answers
63 views

Join tables where one column value has leading zeros and the other doesn't

I am trying to LEFT JOIN a table, but the two columns used for relating rows are not identically formatted. My problem is the value in a.vendor, it has leading zeros on it, and c.No doesn't have ...
user avatar
1 vote
0 answers
28 views

Why does Joomla (or Akeeba) recommend that Output buffering is disabled?

When I use Akeeba Kickstart it recommends that output buffering is disabled. Why does it recommend this? All my research shows that it can speed up sites. It seems I'm not the only one asking https:/...
user avatar
  • 1,839
0 votes
1 answer
45 views

Pulling api data and saving to mySQL

So, I am trying to pull data from EA Sports API for games like NHL or FIFA. The issues with EAs API is it only shows the last 5 games played. I am trying to have a script run every minute and save ...
user avatar
  • 69
0 votes
0 answers
62 views

An exception occurred while executing 'INSERT INTO

I am trying to sign up in a portal but I am getting the following error; "SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'password' cannot be null How do I solve this problem?
user avatar
0 votes
2 answers
198 views

JRequest Method in Joomla 4

JRequest Remove from Joomla 4 then how i must use this method for example $controller->execute( JRequest::getCmd('task', $view) not work i must change it to what ?
user avatar
0 votes
0 answers
29 views

Joomla all versions not worked 404 pages on Litespeed server

i see front page without component, → 404 error not shows but i have its in my template.. error.php: error->getCode(); ?> - title; ?> i found very much articles, whats is maybe litespeed not support ...
user avatar
2 votes
1 answer
224 views

What is the difference between mysqli and mysqlnd php extensions?

I'm considering upgrading from PHP7.4 to PHP8.0 on a Joomla 3.10.8 installation. I was surprised to find that my hosting provider only offers mysqlnd as a PHP extension in PHP 8.0, but not mysqli. ...
user avatar
1 vote
1 answer
91 views

Updated to Joomla 4 and custom PHP scripts no longer run

I have just upgraded from Joomla 3.10.8 to the latest version of Joomla 4 (it is 100% better). However some of my scripts that have run for years now no longer work. The scripts basically import files ...
user avatar
  • 31
0 votes
1 answer
460 views

Update Joomla! 3.10.8 to PHP 7.4 or PHP 8.0

I am using a Joomla! 3.10.8 Stack from Turnkey Linux, it shows a warning, that I have to upgrade to a higher PHP-version. So how I update/upgrade the higher PHP-version? And is it clever to upgrade to ...
user avatar
  • 21
0 votes
2 answers
71 views

How can I sort an unordered list alphabetically by class with JavaScript or PHP?

In a custom J4 site I am using the Shack Locations (previously Focalpoint) core extension that displays a dynamically generated legend of location types on the front end, but it is listing the nine ...
user avatar
  • 161
0 votes
0 answers
43 views

How to encrypt and decrypt User data in joomla

I am new to joomla, and working on joomla application which is currently running on production environment. Application contains 1000+ registered users. As per GDPR Policy, I have requirement for ...
user avatar
  • 1
2 votes
0 answers
35 views

MySQL Server has gone away with mysqli_connect to another LAMP Stack / TURNKEY Linux

I am trying to connect to another VM (192.168.16.27) from 192.168.16.28 to get Data out of the MariaDB Database (joomla). So my Code is: $link = mysqli_connect("192.168.16.27", "user&...
user avatar
  • 21
1 vote
1 answer
80 views

How to use Joomla for insert, delete, display and update data from mysql?

I'm just started to learn using Joomla and one of the things that I need to do is to build a form that can insert data and that data can be displayed to another Joomla page. I got a few comments from ...
user avatar
0 votes
1 answer
41 views

Incorrect Uri::root() with external PHP file

The file /srv/http/components/com_mycomponent/ajax/editAction.php was initialized with https://github.com/joomla/joomla-cms/issues/34586#issuecomment-865080001, except that we use define('JPATH_BASE', ...
user avatar
0 votes
0 answers
29 views

Problem with password reset: The object must be an array or an object that implements ArrayAccess

When I try to reset my password from my website, I get this error: Error The object must be an array or an object that implements ArrayAccess What is the root cause?
user avatar
1 vote
2 answers
219 views

How can I reference JFactory within a PHP class?

In Joomla 3: I'm writing a class to represent a semi-complex data structure. In that class, some methods need to access the app, dbo, document and user objects from JFactory. Here's a snippet of the ...
user avatar
3 votes
2 answers
69 views

How to set/change default article category in Joomla 3.10?

When I create a new article, there is a default category of "Uncategorised". Is there any way to set a different default article category instead of the native default "Uncategorised&...
user avatar
0 votes
1 answer
180 views

ERROR 0 - Object of class stdClass could not be converted to string

The code where the error occurs is: $css .= 'height:'.$gallery_height.'px;'; $css = ''; if($gallery_height){ $css .= $addon_id .' .sppb-gallery-parallax:after {'; $css .= 'height:'.$...
user avatar
1 vote
1 answer
33 views

nginx php-fpm server works on simple php website but throws php fatal error on Akeeaba or fresh joomla install

Simple php websites work on my nginx + php-fpm server. But If I do fresh full Joomla or Akeeba kickstart I get "PHP Fatal error: Uncaught Error: Call to undefined method". Also if restart ...
user avatar
1 vote
1 answer
39 views

getMailer gives "Failed to start application" exception, how do I fix it?

Attention! While searching for a solution I have found that the hosting service blocked mails, I'm not sure this is a valid question anymore, don't reply untile further notice. The issue Quoting from ...
user avatar
0 votes
0 answers
13 views

Payment plugin for Documents Seller

I am trying to build a payment plugin for Joomdonation Documents Seller. I can send an order to a Bank and pay, but after that I am having a problem. When an order is created and sent, it has status: ...
user avatar
1 vote
1 answer
36 views

cant display simple text onContentPrepare

I just want to display simple text and this is not working. I don't know is there a way to see something like log to see what happens in the background? public function onContentPrepare($context, &...
user avatar
  • 11
0 votes
0 answers
12 views

How to execute external application in Joomla 3.10 and pass parameters

My scenario is very simple. I want execute a URL menu item to call an external application and pass parameters in the URL. Example: I want to execute my external app "Reporter" and pass the ...
user avatar
1 vote
3 answers
171 views

Execute Joomla CLI script to bulk import JSON data to articles

I have the following PHP code working to bulk add array items from JSON to com_content. The code is executed by directly accessing the file in the web browser. For example, http://examples.com/json-...
user avatar
1 vote
0 answers
15 views

Upload volume changes do not apply to php.ini

Hi I have a centos 7 server and a cwp 7 panel. I have the latest version of Joomla and WordPress installed on them. The size of uploaded files in Joomla is 2 MB. I increased the upload_max_filesize ...
user avatar
1 vote
1 answer
31 views

joomla 4 custom field auto text cleanup

I have this Joomla 4 installed website and I need a custom field(Editor type) for my product specifications which is going to be showing a table. For example, if I put this code: <table> <...
user avatar
1 vote
2 answers
383 views

Loading the built-in jQuery in Joomla 4 if it does not exist

Tell me please. How to load jQuery in Joomla 4 if it has not been loaded yet?
user avatar
  • 111
1 vote
0 answers
23 views

How can I convert a field value to string for use in a custom category blog override?

In Joomla (both 3x and 4x) I am trying to add a php 'if' query to a category blog override so that if the category title is 'X' then it does one thing, but if not, do something else. (I'm having ...
user avatar
  • 161
0 votes
1 answer
468 views

Application shows session_start(): Failed to read session data: on browser

I have hosted a website using a backup and when I access it through a web browser, it shows me error and I have changed configuration.php file from: public $error_reporting = 'none'; To: public $...
user avatar
2 votes
1 answer
64 views

Can't edit index.php in Joomla 3.10

I am trying to edit my index.php file in my website using the Joomla! extension manager. I have to add the code right before my closing tag however there is no HTML! So I've tried adding some, after ...
user avatar
0 votes
1 answer
75 views

How to create menu item in admin menu Joomla 4 in php+mysql in module, plugin?

How to create menu item in admin menu Joomla 4 in php? From plugin/module for Joomla4?
user avatar
1 vote
0 answers
64 views

Troubles with Implementation of self written Module for Joomla and Auto Suggest function which should be in Javascript

I am trying to find a way to implement either a self written module in Joomla with PHP code of an dictionary or try to use the dictionary by putting the PHP code in a joomla article with sourcerer ...
user avatar
  • 11
2 votes
2 answers
185 views

Integrate external news content API into com_content articles

My client is looking to integrate news content coming from an external API into their Joomla website. The API is in the JSON format and includes multiple fields like title, summary, date, and full ...
user avatar
0 votes
0 answers
33 views

Dynamic page filled with content depending on the previous page

I am kinda new as a developer and I want to achieve the following in Joomla. The idea is that I have a category->sub category->products. The category and subcategory will be added in joomla and ...
user avatar
  • 1
1 vote
0 answers
59 views

Use language override to create custom title tags for URL's

I have this piece of code that already runs on the pages I need this done. (The entire Joomla 3.9 site is a Frankenstein of custom code, components, etc. ) $placeholder_country = JText::_('...
user avatar
  • 31
0 votes
1 answer
133 views

What is the correct PHP to render Subform repeatable custom fields on the front end?

When creating custom layout overrides the PHP code <?php echo $this->item->jcfields[X]->value; ?> Works successfully, but does not function at all when it comes to repeatable subform ...
user avatar
  • 45
1 vote
1 answer
21 views

php exclusion in a joomla plugin of the xml sitemap page created by OSMAP

I have trouble uploading OSMAP sitemaps to google because of a plugin I am using. That plugin called autoanchor menu creates a menu based on titles in an article. really usefull for long articles. ...
user avatar
1 vote
1 answer
94 views

Show article fields in module

I have two custom fields in my article for longitude and latitude. I'm then trying to build a module to get these two fields from the current article displayed and show in the module. I have the ...
user avatar
  • 1,992
1 vote
1 answer
72 views

Where do I add php code to submit an HTML form?

I am new to Joomla, and so far, I used the basics to make a simple website. I decided to try out making a component, using JCB, that has a database of a list of items, and for each item, there is a ...
user avatar
  • 11
1 vote
0 answers
63 views

J4.x - How to echo content from a specific article into error.php

In Joomla 3 I had a really simple error.php file which pulled in the content from an article with the title '404'. I created an article named 404 and assigned it to a menu item of type 'single article'...
user avatar
  • 161
0 votes
1 answer
37 views

Get Object Values

I use this code: $currency = new MyCurrency(); print_r($currency); to load/print the following Object: MyCurrency Object ( [currencyCode:protected] => EUR [currencies:protected] => Array ( [USD]...
user avatar
  • 308
1 vote
2 answers
61 views

How to add specific js and css to a particular page in joomla?

I have added the html code using sp page builder extension also need to add css and js to this particular page in joomla 3. i am using t3 blank template is there any procedure to add this or any ...
user avatar
1 vote
1 answer
88 views

View only showing one row from sql result set

I am creating a component and trying to display a list within a model. The code I have shows the multiple arrays that should be on the list, but when I add echo inside the view table, I am only ...
user avatar
  • 69
1 vote
0 answers
15 views

Joomla restricted pages are redirected to 301 Moved Permanently after HTTPS redirection

I have Joomla site with a load balancer (AWS). The website is redirected to https, after redirecting home page works correctly. However, on restricted pages after login are giving the error 301 Moved ...
user avatar
  • 111
1 vote
1 answer
41 views

Ajax call from module default.php file in order to fulfill a sql query

I have a fully working module in Joomla, but I'm struggling with the last piece which is sending a value from Javascript in my default.php file into the helper file, where it will be used in a sql ...
user avatar
  • 125
1 vote
2 answers
85 views

J4 Get an array of parameters from template/module

The current Joomla implementation looks like $moduleHelper->getParams()->get('paramName'); // don't remember this one perfectly $app->getTemplate(true)->params->get('paramName'); Is ...
user avatar
  • 395
2 votes
2 answers
647 views

Get site application via Factory::getApplication() in Joomla 4

The documentation for J3 instructs using Factory::getApplication('site') to get the site application, however according to the documentation for J4 doesn't have those method parameters anymore. I'm ...
user avatar
  • 395
0 votes
1 answer
41 views

No such file or directory while using Vina Dongky template

I am using a template called Vina Dongky for VirtueMart content and I'm getting some errors. Warning: require_once(/home/priskork/public_html/libraries/joomla/document/html/renderer/head.php): failed ...
user avatar

1
2 3 4 5
15