<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Arun Nautiyal</title>
    <description>The latest articles on DEV Community by Arun Nautiyal (@nautiyalar).</description>
    <link>https://dev.to/nautiyalar</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F522192%2Fce69f8e1-ca79-4c4a-9e91-0e1f386accae.jpg</url>
      <title>DEV Community: Arun Nautiyal</title>
      <link>https://dev.to/nautiyalar</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/nautiyalar"/>
    <language>en</language>
    <item>
      <title>function inside javascript</title>
      <dc:creator>Arun Nautiyal</dc:creator>
      <pubDate>Sat, 28 Nov 2020 09:12:38 +0000</pubDate>
      <link>https://dev.to/nautiyalar/function-inside-javascript-550n</link>
      <guid>https://dev.to/nautiyalar/function-inside-javascript-550n</guid>
      <description>&lt;p&gt;HTML File&lt;br&gt;
&amp;lt;!DOCTYPE html&amp;gt;&lt;br&gt;
&lt;br&gt;
&lt;/p&gt;
&lt;br&gt;
    &lt;br&gt;
    Photo Gallery
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;link rel="stylesheet" href="css/gallery.css"&amp;gt;

&amp;lt;script src = "js/gallery.js"&amp;gt;&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;div id = "image"&amp;gt;
    Hover over an image below to display here.
&amp;lt;/div&amp;gt;

&amp;lt;img class = "preview" alt = "Styling with a Bandana" src = "https://s3-us-west-2.amazonaws.com/s.cdpn.io/389177/bacon.jpg" onmouseover = "upDate(this)" onmouseout = "unDo()"&amp;gt;

&amp;lt;img class = "preview" alt = "With My Boy" src = "https://s3-us-west-2.amazonaws.com/s.cdpn.io/389177/bacon2.JPG" onmouseover = "upDate(this)" onmouseout = "unDo()"&amp;gt;

&amp;lt;img class = "preview" src = "https://s3-us-west-2.amazonaws.com/s.cdpn.io/389177/bacon3.jpg" alt = "Young Puppy" onmouseover = "upDate(this)" onmouseout = "unDo()"&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;CSS file&lt;/p&gt;

&lt;p&gt;body{&lt;br&gt;
        margin: 2%;&lt;br&gt;
        border: 1px solid black;&lt;br&gt;
        background-color: #b3b3b3;&lt;br&gt;
}&lt;/p&gt;

&lt;h1&gt;
  
  
  image{
&lt;/h1&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;line-height:650px;
    width: 575px;
height: 650px;
    border:5px solid black;
    margin:0 auto;
background-color: #8e68ff;
background-image: url('');
background-repeat: no-repeat;
color:#FFFFFF;
text-align: center;
background-size: 100%;
margin-bottom:25px;
font-size: 150%;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;br&gt;
.preview{&lt;br&gt;
        width:10%;&lt;br&gt;
        margin-left:17%;&lt;br&gt;
    border: 10px solid black;&lt;br&gt;
}&lt;br&gt;
img{&lt;br&gt;
        width:95%;&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;Need to write a code inside  function &lt;/p&gt;

&lt;p&gt;function upDate(previewPic){&lt;br&gt;
 /* In this function you should &lt;br&gt;
    1) change the url for the background image of the div with the id = "image" &lt;br&gt;
    to the source file of the preview image&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;2) Change the text  of the div with the id = "image" 
to the alt text of the preview image 
*/



}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;function unDo(){&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; /* In this function you should 
1) Update the url for the background image of the div with the id = "image" 
back to the orginal-image.  You can use the css code to see what that original URL was

2) Change the text  of the div with the id = "image" 
back to the original text.  You can use the html code to see what that original text was
*/

}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>css</category>
      <category>javascript</category>
      <category>html</category>
    </item>
  </channel>
</rss>
