1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

RM 1.1 Upload all a folder

Discussion in 'Resource Manager Support' started by aana, Aug 29, 2015.

  1. aana

    aana Member


    i have a folder with 3500 pdf on my server. I would like to add thoses 3500 pdf on the ressources manager but not by uploading them one by one with my little hand.

    its possible to add the complet folder and use the ressource manager option to creat a topic for each new one ?
  2. Brogan

    Brogan XenForo Moderator Staff Member

    It's not possible to automatically create resources from a list of files.

    You would need to manually create each resource.
  3. aana

    aana Member

    thx Brogan,

    and with a script ?

    i mean the script should take the name of the document without the .pdf and complet the form for each files. is that possible ? risked ?
    othet solution: i list all files of the folder on a text document, remove the .pdf and creat a script who take this name to complet name and description and add the url + .pdf to complet the external link.

    or if i already have all thoses 3500 files on the ressources manager but without topic created for each one. How can i "refresh" the ressources to make it creat à topic for each one ? ( i already try to rebuild cache but he don't creat topic )
  4. Brogan

    Brogan XenForo Moderator Staff Member

    It would be possible with custom development.
  5. aana

    aana Member


  6. 0ptima

    0ptima Well-Known Member

    You could probably adapt this importer to import all the files
    Beta - DownloadsII -> XenForo Resource Manager Importer
    This importer creates a thread with an attachment and then converts it to a resource. The thread gets deleted, but you could comment out that part to prevent the delete.

    You could probably create a CSV file with all the required info and have the addon read the file and process all the files.
    Your csv file would need the following fields
    • filename
    • user ID
    • title
    • message text
    • node ID (for the thread)
    • Category ID (for the resource)
    You can easily read the CSV into an array with the following
    $csv = array_map('str_getcsv', file('data.csv'));
    Last edited: Aug 30, 2015
  7. aana

    aana Member


    thx i am going to look that.

Share This Page