We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 27067
    • 3 Posts
    I need to make a form that uploads files to the server, along with some meta-data to be stored in the database.
    I’m trying to get some direction on the best approach for doing this.

    We need to have this form accessible from the web portal (not the modx manager), we are using Modx Revolution 2.0.0-pl rev7212.

    I want to know if it would be best to try to use "static resources" to store the data in the modx database or perhaps make our own tables for the meta information?

    Any suggestions on where to start would be greatly appreciated, thanks.
      • 19980 ☆ A M B ☆
      • 275 Posts
      big files probably will not go by form submit

      i do advise flash uploader for win users

      and javauploader for mac, linux users
        modx and ecommerce pro
        • 27067
        • 3 Posts
        We are able to upload the files, the problem is the database.
        We need to have a place to store the meta-information about each file.

        Should we make our own table in the database and store it there?
        How do we communicate with the database directly through modx revolution?

        or

        Can we store the meta information using some feature of modx?
        Would there be a limitation for the number of files we could upload? (5000 limit?)
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          You should have a custom table. There is no limit inherent in MODx for this; the 5000 resource limit refers to the point where Evo (1.0.4) begins to suffer from an overload of its cache system.
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 27067
            • 3 Posts
            Should we connect to the database via php’s mysql functionality or is there a connection to the database already open and available via the modx api?
              • 28042 ☆ A M B ☆
              • 24,524 Posts
              You can use the connection MODx has opened. There is a db API that you can use.
                Studying MODX in the desert - http://sottwell.com
                Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                Join the Slack Community - http://modx.org