News:

Support for jDownloads 3 has been ended
Since 17 August 2023 Joomla.org has discontinued support for Joomla 3.x. Therefore, we will no longer offer official support for our Joomla 3 jDownloads version 3.9.x from January 2024.
Please update your website to the latest Joomla version (Joomla 4 or Joomla 5) as soon as possible. Afterwards, please update jDownloads to the latest published version. The longer you delay, the more difficult the upgrade process for your website is likely to be.

Main Menu
Support-Forum

Jdownload mass import

Started by jabba, 08.11.2016 15:10:23

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

jabba

Hello! Is there a way to mass import a large number of files?
I have ~6000 PDF to import, is there a way to add them as CSV (after uploading all the files in a folder via FTP) something like:
('File Name','File Path in Server','Custom field 1','Custom field 2','Custom field 3').
Thank you!
  •  

ColinM

Hi,
Yes there is a way to mass import files into jD. But I would suggest you do it in blocks of say 500 or less files at a time as there is a lot of database work involved in the creation so you could run out of server time.

the root file for jD is located in the Downloads tab of Config.  Typically it is a directory in the root of your site and is usually called jdownloads.

The basic scheme is to go to the monitoring tab in Config and set Download Directory Monitoring to No.  You may also want to set Automatically Publish Downloads to Yes.  Then after copying the top directory levels and any files as sub-directories of the jdownloads directory, using say your favourite FTP client, then go to the jD Control Panel and in the Status panel click on 'Check Download Area now'.  This will then create all the relevant Categories (directories) and Downloads (files).  Then repeat with another batch of directories/files as appropriate.  Yes it is a little tedious to do multiple times but your web server is probably not totally flexible in its resource allocations.

If you do not have access to ftp then you could use the Files section of jD but this is a lot slower.

Colin
Colin M
  •  

jabba

Thank you for your answer!
But in this way how can i set specific custom fields to specific files? I have to do it one by one after upload and import? Thank you again.
Gianluca
  •  

ColinM

#3
Hi
Yes the information has to come from somewhere! So it has to be added individually.

When you say custom fields do you mean the jD Custom fields or are you meaning say adding 'regular' items like description, licence details and so on?

All of the additional information is held in the jD related tables in the database. One can easily download and reload the contents of the jD database - see Control Panel Tools.

So if you are making multiple changes and you have software that works with a database structured file then one can do it offline in a more bulk way but any error could be 'challenging'. But this method is one that I personally not do as my detail database knowledge is limited, and I have never invested in the appropriate software.  Arno handles all of that side of things.

Colin
PS If I were to attempt to modify the database contents more directly I would do it first on XAMPP or WAMP on my own PC
Colin M
  •