Skip to main content
2 votes
Accepted

MySQL "LOAD DATA LOCAL INFILE" with database connection object in Joomla 4

Since 4.0, Joomla database layer always uses prepared statements. And as the error states, the query you're trying to run is not supported when used in prepared statements. This is true at least for ...
Sharky's user avatar
  • 11.5k
1 vote
Accepted

Using MySQL "LOAD DATA LOCAL INFILE" with the Joomla database connection object

Updated to include the more detailed example based on the 1st comment. I have been able to get the follow statement to work, or at least not fail, in a simple Joomla 3 Model; $db = $this->getDbo(); ...
Irata's user avatar
  • 4,001
1 vote
Accepted

Best way to save timestamp for new or modified records in custom component

Using the Banners component as an example you can see the way that it handles the empty date fields in the ..\administrator\components\com_banners\src\Table\BannerTable.php check() method. The check() ...
Irata's user avatar
  • 4,001
1 vote

Best way to save timestamp for new or modified records in custom component

Do your database tables have associated classes which extend the Joomla Table class? If so, you can set these attributes in a store() function, overriding Table::store(). They'll then be set just ...
Robbie Jackson's user avatar
1 vote

Standalone PHP script to get username in Joomla 4?

The first thing you need to do is to replace the first part of your code that establishes the Site instance of Joomla 4. In this answer you will find sample code that provides for accessing the four ...
Irata's user avatar
  • 4,001
1 vote
Accepted

Is insertObject sanitizing the inputs?

In the meantime I experimented with this to find out the answer. I have tested with $action->json_data = json_encode([ 'category' => $category, 'template' => $...
Lajos Arpad's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible