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

    Anyone any ideas how I can change the path used for an image.

    I currently have a context set up for a subdomain which works fine. But when I try to insert a image the sub domain directory is being included.

    So for example i’d get a relative path like

    mysubdomain/assets/images/myimage.jpg

    But as the mysubdomain folder is set as my root i don’t need that in the url, what I actually need is:

    /assets/images/myimage.jpg

    Thanks

    Ben
      • 36926
      • 701 Posts
      Quote from: bennyb at Jan 29, 2011, 10:42 AM

      Hi,

      Anyone any ideas how I can change the path used for an image.

      I currently have a context set up for a subdomain which works fine. But when I try to insert a image the sub domain directory is being included.

      So for example i’d get a relative path like

      mysubdomain/assets/images/myimage.jpg

      But as the mysubdomain folder is set as my root i don’t need that in the url, what I actually need is:

      /assets/images/myimage.jpg

      Thanks

      Ben

      managed to get this working using s context setting.

      filemanager_path
        • 19604 ☆ A M B ☆
        • 179 Posts
        When I include an image via TinyMCE I get these double slashes before "images".:
        http://subdomain.domain.com/assets/user//images/people.jpg

        The "MODx RESOURCE BROWSER" shows only "broken" images (no previews) but the TinyMCD window "Insert/edit image" displays the image correctly but inserts it with the "//".

        My settings are:
        assets_url  http://subdomain.domain.de/assets
        base_url   /
        http_host   subdomain.domain.com
        site_url  http:// subdomain.domain.com
        setting_filemanager_path   /customers/htdocs/domain.com/subdomain/assets/user/
        setting_filemanager_url   http://subdomain.domain.com/assets/user/
        


        The core run ins "/customers/htdocs/domain.com/cms/", the subdomain is a context and stored at "/customers/htdocs/domain.com/subdomain/".

        Any idea?
          MINDEFFECTS – DESIGN for PRINT, WEB and MEDIA
          http://twitter.com/mindeffects · http://www.facebook.com/mindeffects · http://www.youtube.com/mindeffects/ · skype://mindeffects_oliver