Copied to clipboard

Flag this post as spam?

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


  • David Negley 9 posts 51 karma points
    Apr 24, 2015 @ 16:25
    David Negley
    0

    How Do I Insert Image into Template?

    My question is extremely basic.

    I have an existing website. All I want to do is port the site into Umbraco. I thought the easiest way to do this might be to copy the existing HTML into a "Homepage" template. This worked surprisingly well. All the images and scripts that are hosted on the internet are displaying nicely. However, images that were hosted locally on the original server as part of the site are not displaying. That makes sense to me.

    The obvious solution, it seems to me, is to copy those images into the Media library of my Umbraco site, then set the "src" attribute of my <img> tag to "/media/logo.jpg", or something like that. But I can't seem to make this happen.

    Where am I going wrong?

    Thanks!

  • Alex Skrypnyk 6175 posts 24186 karma points MVP 8x admin c-trib
    Apr 24, 2015 @ 22:44
    Alex Skrypnyk
    0

    Hi David,

    Welcome to the best community )

    You can't use Umbraco Media folder just like usual folder on the disk. You need to upload images there via Umbraco admin part -> Media Section. How to use Media section look here -

    http://www.umbraco.tv/videos/umbraco-v7/content-editor/basics/creating-content/media-section/documentation

    http://www.umbraco.tv/videos/umbraco-v7/content-editor/basics/creating-content/media-section/

    If you want just to upload image to disk, use 'img' or 'images' or other folder names, but not Umbraco folders.

    Thanks, Alex

Please Sign in or register to post replies

Write your reply to:

Draft