Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jonas 123 posts 206 karma points
    Mar 25, 2015 @ 10:34
    Jonas
    0

    Replacing image in media does not work. Old image shows in preview and on page

    We have an item in Media wich we have change, we changed it to a new image.

    On the page in the backend where the image is used the new image appear.

    Also in the database in cmsContentXml the new image in the new folder appears.

    We have cleared the cache, removed umbraco.config, resaved the page. Recycled app-pool and rebuilt the index. Still the old image appear when we preview the page and view the page on the website.

    Can anyone explain this magic?

    We are using Umbraco 7.2.1

  • Alex Skrypnyk 6132 posts 23951 karma points MVP 7x admin c-trib
    Mar 28, 2015 @ 17:53
    Alex Skrypnyk
    0

    Hi Jonas,

    Did you check on the disk, which image is saved ? Maybe it's browser cache.

    Thanks

  • Jonas 123 posts 206 karma points
    Apr 14, 2015 @ 09:59
    Jonas
    0

    Hi Alex, its not browser, if I go to the Media section, the image is there and its clickable.

    But when Previewing och Viewing the page where the image is supposed to appear it does not.

    I have checked that the file exist on disk also. Same goes for other items in the Media folder, PDF, png and other.

    Umbraco.config has been deleted and IIS recycled. Still the wrong URL.

  • Alex Skrypnyk 6132 posts 23951 karma points MVP 7x admin c-trib
    Apr 14, 2015 @ 10:12
    Alex Skrypnyk
    0

    Hi Jonas,

    Very strange, is everything fine with permissions ?

  • Jonas 123 posts 206 karma points
    Apr 14, 2015 @ 10:21
    Jonas
    0

    Permissions is fine.. And in the database the correct file shows... in this case it is a PDF and we are using the MultiUrlPicker. But its the same with a regular image and MediaPicker.

          <contentLink><![CDATA[[
      {
        "id": 13431,
        "name": "Primegrilldinner",
        "url": "/media/680464/alacarte-dinner-11-18april-2015.pdf",
        "target": "_blank",
        "isMedia": true,
        "icon": "mediaFile.gif"
      }
    ]]]></contentLink>
    

    But when adding the link/file to a page the wrong/old url shows.

    It must be cached somewhere in Umbraco.

  • Alex Skrypnyk 6132 posts 23951 karma points MVP 7x admin c-trib
    Apr 14, 2015 @ 10:22
    Alex Skrypnyk
    0

    How did you get url to media file ? Did you try republish all ?

  • Jonas 123 posts 206 karma points
    Apr 14, 2015 @ 10:26
    Jonas
    0

    I have published/unpublished all items.

    var multiUrlPicker = child.GetPropertyValue

  • Alex Skrypnyk 6132 posts 23951 karma points MVP 7x admin c-trib
    Apr 14, 2015 @ 10:29
    Alex Skrypnyk
    0

    what is 'child' ?

    I'm usually using media like that :

    var mediaId = currentPage.GetPropertyValue<int>("image");
    var media = Umbraco.TypedMedia(mediaId);
    var imageUrl = media.Url;
    

    Thanks

  • Damian Chambers 23 posts 87 karma points
    Nov 04, 2015 @ 16:31
    Damian Chambers
    0

    I am having a similar problem. Whenever I attempt to change an image, the link to the old image still appears. I checked in the page inspector of the browser. The new image link works fine.

  • Dave Woestenborghs 3504 posts 12133 karma points MVP 8x admin c-trib
    Nov 05, 2015 @ 08:03
    Dave Woestenborghs
    0

    Have you tried rebuilding the Examine indexes ?

    For performance reasons the Umbraco API first checks the Examine index if it can find a media item there. If not it will query the database.

    But if it finds it in the Examine index, and that is not updated then you will see your old image/file.

    Dave

  • Mats Stam 61 posts 210 karma points
    Jan 28, 2016 @ 09:40
    Mats Stam
    0

    Anyone found a solution for this? I'm trying to update my media-item by uploading a new file to it, but it just refuses to use it. It changes the file in the in the upload file window etc, but everything that links to the media-item still uses the old file. Whats up with that? =(

    edit: I'm also using 7.2.1

  • Sjors Pals 617 posts 270 karma points
    Sep 20, 2016 @ 15:14
    Sjors Pals
    1

    I also got this reported by a client, they are running 6.2.5 It seems to be related to the Lucene Index, if i delete the index, and rebuild it, the media url is retrieved correctly.

Please Sign in or register to post replies

Write your reply to:

Draft