We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 17270
    • 13 Posts
    Hey guys,

    I’ve just installed modx 0.9.5 on my shared server and am really amazed about it’s user-friendliness and robustness. Nevertheless, there are a couple of problems I’ve encountered.

    First, when creating new folders in the file manager, am I always supposed to do this via modx or can I use, say, putty or WinSCP?

    Second, if I create a folder in, say, assets/files, I can’t create subfolders anymore. Apache is running as wwwrun in www group, but I have to change the owner to <my_username> and leave the group intact in order to be able to create a new subfolder. The rights have to be set to 775. How to make it possible to create subfolders via modx?

    Third, once a file is uploaded to the file manager, I can’t link to it when creating a web page - when I browse the file manager, it simply doesn’t show the file. I’ve uploaded the file via modx (manage files). One such uploaded file I can see though. Any ideas?

    I’m on Suse 9.3 Pro with Plesk 8.1 installed. It’s a shared host, but I have root access to everything. I would really appreciate your help at this point.

    Cheers,
    Algirdas
      • 17270
      • 13 Posts
      Since people are just checking this thread, but find it hard to reply, maybe I should rephrase my most important question: how do you create folders and upload files via modx API on a shared host? Am I the first one to experience the problem with being able to create folders of only one level of depth?

      Thanks a lot for any info,
      Algirdas
        • 26982
        • 75 Posts
        I think you have a permissions problem.
        I’ve just run a quick test and I can create nested folders and see files in them via MODx.

        MODx is written in PHP, so it will run as the same user as PHP. This means that your folders and files need to be read and write enabled by that user (the username will depend on your host).

        It sounds to me that some of your folders are read but not write enabled, so you can’t create folders - and others are write but not read enabled (so the contents are invisible).

        When you chmod or chgrp folders, make sure you use the -R option to recurse through the whole folder.
        eg:
        chmod -R 775 assets/images/

        chown -R <phpuser> assets/images/
        or
        chgrp -R <phpuser> assets/images/
        etc etc.

        /\dam
          • 17270
          • 13 Posts
          Ok, my bad. Forgot to change the permissions on the very top (server root) folder. Now I can create subfolders, but the files are still invisible. I’m sure permissions are correct. Two other files (with exactly the same permissions but in a different folder that also has exactly the same permissions) can be seen and attached. I’ve just triple-checked all permissions and all of them are exactly the same (for the two different folders and files). How come one file is visible and the other one is not?

          Thanks so much,
          Algirdas
            • 26982
            • 75 Posts
            All I can think of is that you’ve checked the permissions, but not the owners.
            Sorry I can’t offer anything else.

            /\dam