Подтвердить что ты не робот

Изображения на страницах github и относительные ссылки

Я создал страницу пользователя github.

Теперь предположим, что у меня есть файл изображения в корне репо, расположенный как Images/Emoticons/Cool.png

Я пытаюсь вставить это изображение в мой основной файл Index.html.
Я пишу -
- <img src="\images\emoticons\cool.png"> и ничего не отображается в Интернете и офлайн - <img src="images\emoticons\cool.png"> и ничего не отображается в сети , но я могу видеть изображение в автономном режиме
- <img src="..\images\emoticons\cool.png"> и ничего не отображается в Интернете и офлайн

Что делать?

4b9b3361

Ответ 1

Поскольку сайт обслуживается серверами Linux, путь чувствителен к регистру.

Чтобы выполнить эту работу, замените emoticons на emoticons в предоставленном URL-адресе.

enter image description here

Следующий HTML-код должен правильно отображать изображение

<img src="images/Emoticons/cool.png" alt="hi" class="inline"/>

Ответ 2

try this

    <img src="images/emoticons/cool.png" alt="hi" class="inline"/>

Full Page 

<!DOCTYPE html>
<html>

  <head>
    <meta charset='utf-8' />
    <meta http-equiv="X-UA-Compatible" content="chrome=1" />
    <meta name="description" content="Home Page : My Github Web" />

    <link rel="stylesheet" type="text/css" media="screen" href="stylesheets/stylesheet.css">

    <title>Home Page</title>
  </head>

  <body>

    <!-- HEADER -->
    <div id="header_wrap" class="outer">
        <header class="inner">
          <a id="forkme_banner" href="#" onclick="location.href='https://github.com/Avi-Aryan'; return false;">View on GitHub</a>

          <h1 id="project_title">Home Page</h1>
          <h2 id="project_tagline">Avi Aryan</h2>

        </header>
    </div>

    <!-- MAIN CONTENT -->
<div id="main_content_wrap" class="outer">
    <section id="main_content" class="inner">
    <br />
    Hi ! <img src="images/emoticons/cool.png" alt="hi" class="inline"/><br /><br />
    I am a young coder currently having school time in India.<br />
    I love intelligent-coding, algorithms and logics and<br />
    enjoy playing Cricket and Badminton.<br />
    <br />
    My coding abilities are currently limited Autohotkey and only Autohotkey.<br />
    A listing of my Autohotkey works can be found <a href="Autohotkey.html">here</a>.<br />
    <br />
    You can always visit my <a href="#" onclick="location.href='http://www.avi-win-tips.blogspot.com'; return false;">blog</a> if you are looking for cool tricks and cracks.<br />
    I write original , hard to find content.<br />
    <br />
    <hr><br />
    <h3>My Github Project List</h3>
    <ul>
    <li><a href="#" onclick="location.href='https://github.com/Avi-Aryan/Clipjump'; return false;">Clipjump</a>
    <li><a href="#" onclick="location.href='https://github.com/Avi-Aryan/Sublime4Autohotkey'; return false;">Sublime 4 Autohotkey</a>
    <li><a href="#" onclick="location.href='https://github.com/Avi-Aryan/AutoHotKey'; return false;">Sublime Text Autohotkey Package</a>
    </ul><br />
    <h3>Other Links</h3>
    <ul>
    <li><a href="Autohotkey.html">Autohotkey Scripts Listing</a>
    <li><a href="#" onclick="location.href='http://avi-win-tips.blogspot.in/p/my-autohotkey.html'; return false;">Blog Index</a>
    </ul>
    <br /><br />
    </section>
</div>

    <!-- FOOTER -->
    <div id="footer_wrap" class="outer">
    <footer class="inner">
        <h2><font color="#FFFFFF">Profiles</font></h2>
        <p>
            <a href="#" onclick="location.href='http://www.github.com/avi-aryan'; return false;">Github</a><br />
            <a href="#" onclick="location.href='http://www.autohotkey.com/board/user/24563-a-v-i/'; return false;">Autohotkey Forum</a><br />
            <a href=https://plus.google.com/110328513842183229282">Google +</a><br />
            <a href="#" onclick="location.href='http://www.avi-win-tips.blogspot.com'; return false;">Blog</a>
        </p>
    </footer>



  </body>
</html>