We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29525
    • 388 Posts
    I’m a MODx newbie, but learning fast. . .

    I’m working on my first site. I created a local site to get the basic site developed. Then recreated it on my server (yes I know there are ways to move it, but this very small so far). I updated a folder full of image for my page. I’m trying to insert some of those images into the Content area using TinyMCE. I select the insert image tool, navigate to the images folder (the browse button opens directly to the image folder) where I can see a thumbnail of image and select it. However, the image does not display in the insert image dialog preview box and of course does not appear on my page. This worked just fine on my PC, but doesn’t on the server.

    I’ve checked the path in the configuration. It matches the path to the images. The image permissions are 0644.

    Any suggestions?

    Thank you!
      www.terrybarthdesign.com
      • 29525
      • 388 Posts
      The path makes sense. Something must be out of sync somewhere.

      Here’s the path to the file:

      /home/terrybar/public_html/John D/assets/images/steamship.jpg

      Here’s the html code:

      <img src="../images/Steamship.jpg" />

      File manager path in tools->configuration:

      /home/terrybar/public_html/John D/

      Resource Path in User Interfaces:

      /home/terrybar/public_html/John D/assets/

      Resource URL:

      assets/

      What I don’t understand is why the tool to insert the image opens directly to the proper folder when I click on the browse button, but then won’t display it in the preview window of the insert tool (even before I click insert to place it into the content area).

      Your help is greatly appreciated.

      Terry
        www.terrybarthdesign.com
        • 29525
        • 388 Posts
        OK

        I’ve tried a hundred combinations of path names. How do I find the correct one?

        When I started this I could at least browse to the images and see the thumbnails--even if TinyMCE couldn’t preview them.

        Now I can’t even browse to them from the editor.

        Help. . .
          www.terrybarthdesign.com
          • 2734
          • 165 Posts
          Hi Terry

          Are you really using the correct Path? Put this code into a file (.php), upload it to your MODx install directory and open the url with your browser. You should now see the correct absolute path to your modx dir.
          <?php
          echo realpath(dirname(__FILE__));
          ?>
          


          If you’re using the correct path, did you test if the filemanager (not imagebrowser) works? Maybe you got some problems with folder-access permissions? Did you set them accordingly (as described in the modx install procedure)?

          Edit:
          In the image-browser: If you can see the image-names, but no thumbnail, make sure you delete all .thumb_*.png files in your assets folder (including subfolders). These are the thumbs generated by the image browser. It will re-create them as soon as you browse to that directory again...
            • 29525
            • 388 Posts
            Thank you Banal.

            Well I’ve made progress. You’re script was helpful. Thank you. I was able to restore my ability to browse to the folder and see the thumbnails. However, I still couldn’t see the image in the browser preview. So I thought I’d check permission on the folder, images, etc. Somewhere I messed up my permissions and I lost access to manager entirely--no idea what I did. After spending way too much time, I decided to simply start over and reinstall it all. (don’t worry it just for learning at this point). I’ll post again once I get that done.

            Thank you so much for responding. Stay tuned.

            Terry
              www.terrybarthdesign.com