Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Other Discussions
  3. Site Bugs / Suggestions
  4. Difficulty changing article picture

Difficulty changing article picture

Scheduled Pinned Locked Moved Site Bugs / Suggestions
helpcsharpvisual-studiocom
5 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Sergey Alexandrovich Kryukov
    wrote on last edited by
    #1

    I notice this problem long time ago, but everything worked out finally; and I did not have precise description. Today, I can describe the problem I observed when I updated the top picture of the article All in One Toolchain for Article Writing with Visual Studio Code. In the article submission wizard, I first removed all uploaded files. Then I uploaded new files, not touching article text, but the file names were the same. After submission, I still saw the old picture. In second attempt, I noticed that the img element was different: its src was pointing not to the article directory, but some sub-directory (it's name made of several decimal digits). Apparently, is was some shadow copy of old .png file. On third attempt, I changed src to the name of the new file. After submission, I still saw old picture. On next attempt, I managed to fix the problem by giving the image file a new .png name, but it does not sound right. Thank you.

    —SA

    Sergey A Kryukov

    C 1 Reply Last reply
    0
    • S Sergey Alexandrovich Kryukov

      I notice this problem long time ago, but everything worked out finally; and I did not have precise description. Today, I can describe the problem I observed when I updated the top picture of the article All in One Toolchain for Article Writing with Visual Studio Code. In the article submission wizard, I first removed all uploaded files. Then I uploaded new files, not touching article text, but the file names were the same. After submission, I still saw the old picture. In second attempt, I noticed that the img element was different: its src was pointing not to the article directory, but some sub-directory (it's name made of several decimal digits). Apparently, is was some shadow copy of old .png file. On third attempt, I changed src to the name of the new file. After submission, I still saw old picture. On next attempt, I managed to fix the problem by giving the image file a new .png name, but it does not sound right. Thank you.

      —SA

      Sergey A Kryukov

      C Offline
      C Offline
      Chris Maunder
      wrote on last edited by
      #2

      The best thing to do is not delete images when uploading new ones. The system handles updates by placing them in a Working directory so that the original images are still available to the currently published version of your article. Once the new version is made public the images are swapped out.

      cheers Chris Maunder

      S 1 Reply Last reply
      0
      • C Chris Maunder

        The best thing to do is not delete images when uploading new ones. The system handles updates by placing them in a Working directory so that the original images are still available to the currently published version of your article. Once the new version is made public the images are swapped out.

        cheers Chris Maunder

        S Offline
        S Offline
        Sergey Alexandrovich Kryukov
        wrote on last edited by
        #3

        All right, thank you for the advice. If I have a change, I'll try that way. But frankly, it's not logical. With file systems, if you delete file and immediately copy another one under the same name, or if you copy without deletion, logically, results are the same, right? :-)

        —SA

        Sergey A Kryukov

        C 1 Reply Last reply
        0
        • S Sergey Alexandrovich Kryukov

          All right, thank you for the advice. If I have a change, I'll try that way. But frankly, it's not logical. With file systems, if you delete file and immediately copy another one under the same name, or if you copy without deletion, logically, results are the same, right? :-)

          —SA

          Sergey A Kryukov

          C Offline
          C Offline
          Chris Maunder
          wrote on last edited by
          #4

          You're forgetting that updates and existing articles must exist together. If you delete a file then you delete if from the current article. Current readers suddenly see broken images. When you upload a file it belongs to the new version of the article, which is not yet visible, and so the files are kept in a separate location. Deleting from the current and uploading a new doesn't not do a "delete and replace". You're doing a "delete and store in staging".

          cheers Chris Maunder

          S 1 Reply Last reply
          0
          • C Chris Maunder

            You're forgetting that updates and existing articles must exist together. If you delete a file then you delete if from the current article. Current readers suddenly see broken images. When you upload a file it belongs to the new version of the article, which is not yet visible, and so the files are kept in a separate location. Deleting from the current and uploading a new doesn't not do a "delete and replace". You're doing a "delete and store in staging".

            cheers Chris Maunder

            S Offline
            S Offline
            Sergey Alexandrovich Kryukov
            wrote on last edited by
            #5

            No, I'm not forgetting it. :-) It simply means that the operations should be presented differently. Just think about it. Isn't that obvious that all the operations should do the same? There is no difference between deleting, replacing, adding. All you do you do on a new version of the article, no matter what... —SA

            Sergey A Kryukov

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups