<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"><channel><title>نوشته های ممدحسن</title><link>https://virgool.ir/feed/@mmdhasnbabaei</link><description></description><language>fa</language><pubDate>2026-11-11 09:30:07</pubDate><image><url>https://files.virgool.ir/upload/users/1862743/avatar/PMB4tT.jpg</url><title>ممدحسن</title><link>https://virgool.ir/@mmdhasnbabaei</link></image><item><title>چگونه با جاوااسکریپت ساعت بسازیم؟</title><link>https://virgool.ir/@mmdhasnbabaei/چگونه-با-جاوااسکریپت-ساعت-بسازیم-afxo6mhaq1nt</link><description>تصویر ساعتقرار با کمک html و css و javascript یه همچین چیزی بسازیم که  در واقع دوتا ساعته یکیش آنالوگ و دیگری دیجیتالهhtml&#xA;&lt;!-- // digital clock --&gt;&#xA;&lt;h1 id=&#34;clock&#34;&gt;&#xA;&lt;span id=&#34;hourespan&#34;&gt;&lt;/span&gt;:&#xA;&lt;span id=&#34;minutespan&#34;&gt;&lt;/span&gt;:&#xA;&lt;span id=&#34;secondspan&#34;&gt;&lt;/span&gt;&#xA;&lt;/h1&gt;&#xA;&lt;!-- // analog clock --&gt;&#xA;&lt;div class=&#34;conten&#34;&gt;&#xA;&lt;p class=&#34;one&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;two&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;three&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;four&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;five&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;six&#34;&gt;&lt;/p&gt;&#xA;&lt;div class=&#34;subcont&#34;&gt;&#xA;&lt;p class=&#34;firsthand&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;secondhand&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;thirdhand&#34;&gt;&lt;/p&gt;&#xA;&lt;p class=&#34;center-nail&#34;&gt;&lt;/p&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;css&#xA;*{&#xA;background-color: black;&#xA;font-family: &#39;Franklin Gothic Medium&#39;, &#39;Arial Narrow&#39;, Arial, sans-serif;&#xA;}&#xA;h1{&#xA;text-align: center;&#xA;margin-left: auto;&#xA;margin-right: auto;&#xA;color: aqua;&#xA;margin-top: 35px;&#xA;border: 2px red solid;&#xA;width: 41%;&#xA;box-shadow: 0px 0px 5px 3px;&#xA;}&#xA;*{&#xA;margin: 0;&#xA;padding: 0;&#xA;box-sizing: border-box;&#xA;}&#xA;.conten{&#xA;background-color: rgb(0 0 0);&#xA;height: 200px;&#xA;border-radius: 50%;&#xA;width: 200px;&#xA;margin-left: auto;&#xA;margin-right: auto;&#xA;position: relative;&#xA;margin-top: 30px;&#xA;box-shadow: 0px -1px 6px 0px #e7e7e7;&#xA;}&#xA;.one{&#xA;background-color: aqua;&#xA;height: 41px;&#xA;position: absolute;&#xA;width: 200px;&#xA;height: 2px;&#xA;top: 99px;&#xA;}&#xA;.two{&#xA;background-color: aqua;&#xA;height: 41px;&#xA;position: absolute;&#xA;width: 200px;&#xA;height: 2px;&#xA;top: 99px;&#xA;left: 1px;&#xA;transform: rotateZ(90deg);&#xA;}&#xA;.three,.four,.five,.six{&#xA;height: 41px;&#xA;position: absolute;&#xA;width: 200px;&#xA;height: 2px;&#xA;top: 99px;&#xA;left: 1px;&#xA;background-color: rgb(218, 192, 41);&#xA;}&#xA;.three{&#xA;transform: rotateZ(117deg);&#xA;}&#xA;.four{&#xA;transform: rotateZ(150deg);&#xA;}&#xA;.five{&#xA;transform: rotateZ(213deg);&#xA;}&#xA;.six{&#xA;transform: rotateZ(244deg);&#xA;}&#xA;.subcont{&#xA;position: absolute;&#xA;width: 178px;&#xA;height: 167px;&#xA;top: 19px;&#xA;left: 12px;&#xA;background-color: rgb(0 0 0);&#xA;border-radius: 50%;&#xA;}&#xA;.firsthand{&#xA;position: absolute;&#xA;width: 85px;&#xA;height: 2px;&#xA;top: 75px;&#xA;left: 86px;&#xA;background-color: rgb(214, 12, 1);&#xA;transform-origin: 0px bottom;&#xA;}&#xA;&#xA;.secondhand{&#xA;position: absolute;&#xA;width: 60px;&#xA;height: 2px;&#xA;top: 75px;&#xA;left: 86px;&#xA;background-color: rgb(41 218 87);&#xA;transform-origin: 0px bottom;&#xA;}&#xA;.thirdhand{&#xA;position: absolute;&#xA;width: 54px;&#xA;height: 4px;&#xA;top: 75px;&#xA;left: 86px;&#xA;background-color: rgb(41 63 218);&#xA;transform: rotate(106deg);&#xA;transform-origin: 0px bottom;&#xA;}&#xA;.center-nail{&#xA;position: absolute;&#xA;width: 18px;&#xA;height: 19px;&#xA;top: 70px;&#xA;left: 79px;&#xA;background-color: rgb(5 10 7 / 99%);&#xA;border-radius: 50%;&#xA;box-shadow: inset 0px 0px 1px wheat;&#xA;}&#xA;&#xA;&#xA;js&#xA;&#xA;setInterval(callme,10)&#xA;function callme(){&#xA;let date=new Date&#xA;let second=date.getSeconds()&#xA;let minute=date.getMinutes()&#xA;let houre=date.getHours()&#xA;const hourespan=document.getElementById(&#34;hourespan&#34;)&#xA;const minutespan=document.getElementById(&#34;minutespan&#34;)&#xA;const secondspan=document.getElementById(&#34;secondspan&#34;)&#xA;const helment=document.getElementById(&#34;clock&#34;)&#xA;second= second&lt;9 ? &#34;0&#34;+second:second&#xA;// minute= minute&lt;9 ? &#34;0&#34;+minute:minute&#xA;// houre= houre&lt;9 ? &#34;0&#34;+houre:houre&#xA;let amorpm=houre&lt;12 ?&#34;am&#34;:&#34;pm&#34;&#xA;helment=`${houre}: ${minute}: &lt;span id=&#34;seccss&#34;&gt; ${second}&#xA;&lt;/span&gt;  ${amorpm}`&#xA;}&#xA;const firsthand=document.querySelector(&#34;.firsthand&#34;)&#xA;const secondhand=document.querySelector(&#34;.secondhand&#34;)&#xA;const thirdhand=document.querySelector(&#34;.thirdhand&#34;)&#xA;let first_hand_degree=6&#xA;let second_hand_degree=6&#xA;let third_hand_degree=6&#xA;setInterval(spinhand,1000);&#xA;function spinhand(){&#xA;if(first_hand_degree&lt;=360){&#xA;firsthand.style.transform = `rotate(${first_hand_degree}deg)`;&#xA;first_hand_degree=first_hand_degree+6&#xA;}else if(first_hand_degree&gt;360){&#xA;first_hand_degree=100&#xA;secondhand.style.transform = `rotate(${second_hand_degree}deg)`;&#xA;second_hand_degree=second_hand_degree+6&#xA;}&#xA;if(second_hand_degree&gt;360){&#xA;const thirdhand=document.querySelector(&#34;.thirdhand&#34;)&#xA;second_hand_degree=6&#xA;thirdhand.style.transform =`rotate(${third_hand_degree}deg)`;&#xA;third_hand_degree+=6&#xA;}&#xA;if(third_hand_degree&gt;360){&#xA;third_hand_degree=6&#xA;}&#xA;}لینک فایل ها https://github.com/mamadhasn/ANALOG-DIGITAL-CLOCK-WITH-JAVASCRIPT </description><category>ممدحسن</category><author>ممدحسن</author><pubDate>Sat, 19 Nov 2022 16:28:13 +0330</pubDate></item><item><title>چگونه با جاوا اسکریپت بازی حدس عدد بسازیم؟</title><link>https://virgool.ir/@mmdhasnbabaei/چگونه-با-جاوا-اسکریپت-بازی-حدس-عدد-بسازیم-yirzadiehadt</link><description>اولین تصویرخوب عکس بالا شکل بازی ماستوقتی حدس غلط می زنیم شکل بالا رو داریمو وقتی هم درست حدس می زنیم این شکل رو داریم و امتیازات هم چه مثبت و چه منفی که بر اساس حدس درست و غلط داده میشه ثپت میشهhtml&#xA;&#xA;&lt;div class=&#34;conteaner&#34;&gt;&#xA;&lt;h1&gt;GUESS NUMBER&lt;/h1&gt;&#xA;&lt;label&gt;Tell me your number, between 1 to 9&lt;/label&gt; &lt;br&gt;&#xA;&lt;div class=&#34;subcon&#34;&gt;&#xA;&lt;span id=&#34;negetive&#34;&gt;-&lt;/span&gt;&#xA;&lt;input type=&#34;text&#34; id=&#34;mynumber&#34; placeholder=&#34;enter your number&#34;&gt;&#xA;&lt;span id=&#34;positive&#34;&gt;+&lt;/span&gt; &lt;br&gt;&#xA;&lt;/div&gt;&#xA;&lt;div class=&#34;seocnsubcon&#34;&gt;&#xA;&lt;h3&gt;click me to check your guess&lt;/h3&gt; &lt;br&gt;&#xA;&lt;button id=&#34;submit&#34;&gt;click&lt;/button&gt;&#xA;&lt;button id=&#34;retry&#34;&gt;↻&lt;/button&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;div id=&#34;textcompar&#34; style=&#34;text-align:center;&#34;&gt;&#xA;&lt;/div&gt;&#xA;css&#xA;.conteaner{&#xA;margin-left: auto;&#xA;margin-right: auto;&#xA;text-align: center;&#xA;display: flex;&#xA;flex-direction: column;&#xA;flex-wrap: wrap;&#xA;justify-content: flex-end;&#xA;align-items: center;&#xA;}&#xA;h1{&#xA;background-color: black;&#xA;color: antiquewhite;&#xA;}&#xA;label{&#xA;background-color: rgb(200, 215, 33);&#xA;line-height: 41px;&#xA;font-size: 27px;&#xA;box-shadow: 0px 2px 3px;&#xA;}&#xA;span{&#xA;color: rgb(0, 0, 0);&#xA;}&#xA;#negetive{&#xA;background-color: red;&#xA;padding: 23px;&#xA;border-radius: 50%;&#xA;}&#xA;#positive{&#xA;background-color: green;&#xA;padding: 23px;&#xA;border-radius: 50%;&#xA;}&#xA;button{&#xA;padding: 15px;&#xA;background-color: black;&#xA;border-radius: 31%;&#xA;box-shadow: 1px 1px 3px;&#xA;color: wheat;&#xA;}&#xA;input{&#xA;padding: 23px;&#xA;text-align: center;&#xA;font-size: larger;&#xA;}&#xA;.subcon,.seocnsubcon{&#xA;margin-top: 12px;&#xA;}&#xA;#textcompar{&#xA;font-size: 23px;&#xA;margin: 20px;&#xA;}&#xA;#numone{&#xA;background-color: aqua;&#xA;padding: 16px;&#xA;border-bottom: 7px solid red;&#xA;border-radius: 36%;&#xA;}&#xA;#numonesecond{&#xA;background-color: rgb(242, 255, 0);&#xA;padding: 16px;&#xA;border-bottom: 7px solid red;&#xA;border-radius: 36%;&#xA;}&#xA;#rote{&#xA;background-color: aqua;&#xA;padding: 16px;&#xA;border-bottom: 7px solid red;&#xA;border-radius: 36%;&#xA;}&#xA;#retry{&#xA;background-color: black;&#xA;color: balack;&#xA;font-size: 21px;&#xA;border-radius: 50%;&#xA;}js&#xA;const submit=document.getElementById(&#34;submit&#34;)&#xA;let negetive_scover=1&#xA;let posiotive_scover=1&#xA;submit.addEventListener(&#34;click&#34;,e=&gt;{&#xA;const generatnumber=Math.floor(Math.random()*10)&#xA;const mynumber=document.getElementById(&#34;mynumber&#34;).value&#xA;const error=document.getElementById(&#34;mynumber&#34;)&#xA;error.value=&#34;&#34;&#xA;if( negetive_scover&gt;7){&#xA;alert(&#34;you lose&#34;)&#xA;}&#xA;if(mynumber&gt;=0 &amp;&amp; mynumber&lt;=9){&#xA;if(generatnumber==mynumber){&#xA;document.getElementById(&#34;textcompar&#34;)=` your number is &#xA;&lt;span id=&#34;rote&#34;&gt;${mynumber}&lt;/span&gt; and mine is &lt;span id=&#34;rote&#34;&gt; &#xA;${generatnumber} :)&lt;span&gt;`&#xA;const positive=document.getElementById(&#34;positive&#34;)&#xA;positive=posiotive_scover&#xA;return posiotive_scover=posiotive_scover+1&#xA;console.log(mynumber);&#xA;}else if(generatnumber!=mynumber){&#xA;document.getElementById(&#34;textcompar&#34;)=` your number is &#xA;&lt;span id=&#34;numone&#34;&gt;${mynumber}&lt;/span&gt; and mine is &lt;span &#xA;id=&#34;numonesecond&#34;&gt; ${generatnumber}:(&lt;/span&gt;`&#xA;const negetive=document.getElementById(&#34;negetive&#34;)&#xA;negetive=negetive_scover&#xA;return negetive_scover=negetive_scover+1&#xA;}&#xA;}else{&#xA;alert(&#34;please enter number between 1 to 9&#34;)&#xA;}&#xA;const retry=document.getElementById(&#34;retry&#34;)&#xA;retry.addEventListener(&#34;click&#34;,e=&gt;{&#xA;const positive=document.getElementById(&#34;positive&#34;)&#xA;const negetive=document.getElementById(&#34;negetive&#34;)&#xA;const textcompar=document.getElementById(&#34;textcompar&#34;)&#xA;positive=&#34;+&#34;&#xA;negetive=&#34;-&#34;&#xA;textcompar=&#34;&#34;})لینک دانلود فایل کد ها https://github.com/mamadhasn/GUESS-NUMBER-game-with-javascript </description><category>ممدحسن</category><author>ممدحسن</author><pubDate>Thu, 17 Nov 2022 15:18:25 +0330</pubDate></item><item><title>چگونه با جاوااسکریپت(generate randome quote) بسازیم؟</title><link>https://virgool.ir/@mmdhasnbabaei/چگونه-با-جاوااسکریپتgenerate-randome-quote-بسازیم-yaa8njitvl3y</link><description>یه همچین چیزی که با زدن رکمه جنریت برامون گوت درست کنهhtml&#xA;&#xA;&lt;div id=&#34;conteaner&#34;&gt;&#xA;&lt;h1&gt; GENERATE RANDOM QUOTE &lt;/h1&gt;&#xA;&lt;button id=&#34;generate&#34;&gt;Generate quote&lt;/button&gt;&#xA;&lt;div id=&#34;textplace&#34;&gt;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;css&#xA;&#xA;h1{&#xA;background-color: #33d30b;&#xA;box-shadow: inset -1px -3px 3px;&#xA;border-radius: 4px;&#xA;}&#xA;#conteaner{&#xA;display: flex;&#xA;flex-direction: column;&#xA;align-content: space-around;&#xA;align-items: center;&#xA;justify-content: center;&#xA;}&#xA;#generate{&#xA;background-color: aqua;&#xA;padding: 17px;&#xA;font-size:x-large ;&#xA;border: none;&#xA;box-shadow: inset -3px -2px 3px;&#xA;border-radius: 11px;&#xA;}&#xA;#textplace{&#xA;background-color: #b79898;&#xA;margin-top: 10px;&#xA;text-align: center;&#xA;font-size: 25px;&#xA;box-shadow: inset -2px -3px 3px;&#xA;&#xA;font-size: x-large;&#xA;display: flex;&#xA;flex-direction: column;&#xA;align-items: center;&#xA;border-radius: 19px;&#xA;&#xA;}&#xA;span{&#xA;background-color: #b79898;&#xA;margin: -28px;&#xA;padding: 6px;&#xA;position: absolute;&#xA;top: 64%;&#xA;&#xA;box-shadow: inset -1px -2px 3px;&#xA;border-radius: 12px;&#xA;}&#xA;js&#xA;&#xA;const quotes=[&#xA;{&#xA;id:1,&#xA;quote:&#34;The greatest glory in living lies not in never falling, but in rising every &#xA;time we fall.&#34;,&#xA;who:&#34; -Nelson Mandela&#34;&#xA;},&#xA;{&#xA;id:2,&#xA;quote:&#34;The way to get started is to quit talking and begin doing.&#34;,&#xA;&#xA;who:&#34; -Walt Disney&#34;},&#xA;{id:3,&#xA;quote:&#34;The future belongs to those who believe in the beauty of their dreams. &#34;,&#xA;who:&#34; --Eleanor Roosevelt&#34;&#xA;},{&#xA;id:4,&#xA;quote: &#34;Spread love everywhere you go. Let no one ever come to you &#xA;without leaving happier.&#34;,&#xA;who:&#34;  -Mother Teresa&#34;&#xA;},&#xA;{&#xA;id:5,&#xA;quote:&#34;I never dreamed about success, I worked for it.&#34; ,&#xA;who:&#34; -Estee Lauder&#34;&#xA;},&#xA;{&#xA;id:6,&#xA;&#xA;quote:&#34;Success seems to be connected with action. Successful people keep moving. They make mistakes but they don&#39;t quit.&#34; ,&#xA;who:&#34; -Conrad Hilton&#34;&#xA;&#xA;},&#xA;{&#xA;id:7,&#xA;quote: &#34;There are no secrets to success. It is the result of preparation, hard&#xA; work, and learning from failure.&#34;,&#xA;who:&#34; -Colin Powell&#34;&#xA;},&#xA;]&#xA;const generate=document.getElementById(&#34;generate&#34;)&#xA;&#xA;generate.addEventListener(&#34;click&#34;,e=&gt;{&#xA;const random=Math.floor(Math.random()*7)+1&#xA;const textplace=document.getElementById(&#34;textplace&#34;)&#xA;textplace.style.padding=&#34;79px&#34;&#xA;&#xA;const filterbyrandom= quotes.filter((w)=&gt;{&#xA;&#xA;return w.id==random&#xA;})&#xA;filterbyrandom.forEach(e =&gt; {&#xA;const textplace=document.getElementById(&#34;textplace&#34;)&#xA;textplace=`&#34;${e.quote}&#34;&lt;br&gt; &lt;span&gt;${e.who}&lt;/span&gt;`&#xA;});&#xA;})لینک دانلود فایل کد ها https://github.com/mamadhasn/GENERATE-RANDOM-QUOTE </description><category>ممدحسن</category><author>ممدحسن</author><pubDate>Thu, 17 Nov 2022 14:46:31 +0330</pubDate></item><item><title>چگونه با جاوااسکریپت ماشین حساب بسازیم  :)</title><link>https://virgool.ir/@mmdhasnbabaei/چگونه-با-جاوااسکریپت-ماشین-حساب-بسازیم-w0w53q41wiha</link><description>عکس اولخوب شکل بالا ماشین حساب ما رو نشون میده که در عین سادگی تقریبا کنترول شده و بی عیب کار می کنه.عکس دومبریم به قسمت کد هاhtml&#xA;&lt;div class=&#34;conteaner&#34;&gt;&#xA;&lt;div id=&#34;shownumer&#34;&gt;&#xA;&lt;div id=&#34;sunelespans&#34;&gt;&#xA;&lt;span id=&#34;yek&#34;&gt;&lt;/span&gt;&#xA;&lt;span id=&#34;doo&#34;&gt;&lt;/span&gt;&#xA;&lt;span id=&#34;see&#34;&gt;&lt;/span&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;button id=&#34;plus&#34;&gt;+&lt;/button&gt;&#xA;&lt;button id=&#34;mines&#34;&gt;-&lt;/button&gt;&#xA;&lt;button id=&#34;multiple&#34;&gt;x&lt;/button&gt;&#xA;&lt;button id=&#34;division&#34;&gt;/&lt;/button&gt;&#xA;&lt;button id=&#34;clean&#34;&gt;c&lt;/button&gt;&#xA;&lt;button id=&#34;two&#34;&gt;2&lt;/button&gt;&#xA;&lt;button id=&#34;three&#34;&gt;3&lt;/button&gt;&#xA;&lt;button id=&#34;four&#34;&gt;4&lt;/button&gt;&#xA;&lt;button id=&#34;five&#34;&gt;5&lt;/button&gt;&#xA;&lt;button id=&#34;six&#34;&gt;6&lt;/button&gt;&#xA;&lt;button id=&#34;zero&#34;&gt;0&lt;/button&gt;&#xA;&lt;button id=&#34;one&#34;&gt;1&lt;/button&gt;&#xA;&lt;button id=&#34;seven&#34;&gt;7&lt;/button&gt;&#xA;&lt;button id=&#34;egiht&#34;&gt;8&lt;/button&gt;&#xA;&lt;button id=&#34;nine&#34;&gt;9&lt;/button&gt;&#xA;&lt;button id=&#34;equal&#34;&gt;=&lt;/button&gt;&#xA;css&#xA;*{&#xA;font-size: xx-large;}&#xA;&#xA;.conteaner{&#xA;width: 50%;&#xA;height: 500px;&#xA;display: grid;&#xA;grid-template-columns: 50px 50px 50px 50px 50px;&#xA;gap: 20px;&#xA;grid-auto-rows: 100px;&#xA;margin-right: auto;&#xA;margin-left: auto;&#xA;}&#xA;#shownumer{&#xA;background-color: rgb(3, 225, 66);&#xA;grid-column: 1 / -1;&#xA;grid-row: 1;&#xA;font-size: 60px;&#xA;text-align: center;&#xA;}&#xA;span{&#xA;font-size: 50px;&#xA;}&#xA;&#xA;button#equal{&#xA;background-color: rgb(247, 0, 0);&#xA;grid-column: 1 / -1;&#xA;grid-row: auto;}&#xA;button:not(#equal){&#xA;border-radius: 50%;&#xA;background-color: black;&#xA;color: aliceblue;&#xA;}&#xA;#sunelespans{&#xA;text-align: center;&#xA;}&#xA;#plus{&#xA;background-color: #af1a1aa1!important&#xA;}&#xA;#mines{&#xA;background-color: rgb(18 130 219) !important;&#xA;}&#xA;&#xA;#multiple{&#xA;background-color: rgb(63, 35, 173) !important;&#xA;}&#xA;#division{&#xA;background-color: rgb(156, 93, 157) !important;&#xA;}&#xA;#clean{&#xA;background-color: rgb(199, 122, 22) !important;&#xA;}&#xA;قسمت جاوااسکریپتیشjs&#xA;const spanone=document.querySelector(&#34;#yek&#34;)&#xA;const spanthree= document.querySelector(&#34;#see&#34;)&#xA;const spancondition=document.querySelector(&#34;#doo&#34;)&#xA;const one=document.getElementById(&#34;one&#34;)&#xA;one.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(1)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(1)&#xA;}&#xA;})&#xA;const two=document.getElementById(&#34;two&#34;)&#xA;two.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(2)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(2)&#xA;}&#xA;})&#xA;const three=document.getElementById(&#34;three&#34;)&#xA;three.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(3)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(3)&#xA;}&#xA;})&#xA;const four=document.getElementById(&#34;four&#34;)&#xA;four.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(4)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(4)&#xA;}&#xA;})&#xA;const five=document.getElementById(&#34;five&#34;)&#xA;five.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(5)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(5)&#xA;}&#xA;})&#xA;const six=document.getElementById(&#34;six&#34;)&#xA;six.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(6)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(6)&#xA;}&#xA;})&#xA;&#xA;const seven=document.getElementById(&#34;seven&#34;)&#xA;seven.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(7)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(7)&#xA;}&#xA;})&#xA;const eight=document.getElementById(&#34;egiht&#34;)&#xA;eight.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(8)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(8)&#xA;}&#xA;})&#xA;const nine=document.getElementById(&#34;nine&#34;)&#xA;nine.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(9)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(9)&#xA;}&#xA;})&#xA;const zero=document.getElementById(&#34;zero&#34;)&#xA;zero.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(spancondition.textContent==&#34;&#34;){&#xA;yek.append(0)&#xA;} else if(!spancondition.textContent==&#34;&#34;){&#xA;spanthree.append(0)&#xA;}&#xA;})&#xA;const plus=document.querySelector(&#34;#plus&#34;)&#xA;plus.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(!spanone.textContent==&#34;&#34; &amp;&amp; spancondition.textContent==&#34;&#34; ){&#xA;document.querySelector(&#34;#doo&#34;)=plus.textContent&#xA;} else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34; &amp;&amp; &#xA;!spanthree.textContent==&#34;&#34;){&#xA;equall()&#xA;document.querySelector(&#34;#doo&#34;)=plus.textContent&#xA;} else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34;){&#xA;document.querySelector(&#34;#doo&#34;)=plus.textContent&#xA;}&#xA;})&#xA;const mines=document.querySelector(&#34;#mines&#34;)&#xA;mines.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(!spanone.textContent==&#34;&#34; &amp;&amp; spancondition.textContent==&#34;&#34; ){&#xA;document.querySelector(&#34;#doo&#34;)=mines.textContent&#xA;} else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34; &amp;&amp; &#xA;!spanthree.textContent==&#34;&#34;){&#xA;equall()&#xA;document.querySelector(&#34;#doo&#34;)=mines.textContent&#xA;}else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34;){&#xA;document.querySelector(&#34;#doo&#34;)=mines.textContent&#xA;}&#xA;})&#xA;const multiple=document.querySelector(&#34;#multiple&#34;)&#xA;multiple.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(!spanone.textContent==&#34;&#34; &amp;&amp; spancondition.textContent==&#34;&#34; ){&#xA;document.querySelector(&#34;#doo&#34;)=multiple.textContent&#xA;} else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34; &amp;&amp; &#xA;!spanthree.textContent==&#34;&#34;){&#xA;equall()&#xA;document.querySelector(&#34;#doo&#34;)=multiple.textContent&#xA;}else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34;){&#xA;document.querySelector(&#34;#doo&#34;)=multiple.textContent&#xA;}&#xA;})&#xA;&#xA;const division=document.querySelector(&#34;#division&#34;)&#xA;&#xA;division.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(!spanone.textContent==&#34;&#34; &amp;&amp; spancondition.textContent==&#34;&#34; ){&#xA;document.querySelector(&#34;#doo&#34;)=division.textContent&#xA;} else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34; &amp;&amp; &#xA;!spanthree.textContent==&#34;&#34;){&#xA;equall()&#xA;document.querySelector(&#34;#doo&#34;)=division.textContent&#xA;}else if(!spanone.textContent==&#34;&#34; &amp;&amp; !spancondition.textContent==&#34;&#34;){&#xA;document.querySelector(&#34;#doo&#34;)=division.textContent&#xA;}&#xA;})&#xA;function equall(){&#xA;const shownumer=document.querySelector(&#34;#shownumer&#34;)&#xA;let firstvalue=document.querySelector(&#34;#yek&#34;)&#xA;let firstvalueu=parseInt(firstvalue.textContent)&#xA;const secondvalue=document.querySelector(&#34;#doo&#34;)&#xA;let secondvalueu=secondvalue.textContent&#xA;let thirdvalue=document.querySelector(&#34;#see&#34;)&#xA;let thirdvalueu=parseInt(thirdvalue.textContent)&#xA;switch(secondvalueu){&#xA;case &#34;+&#34; :firstvalue=firstvalueu+thirdvalueu ,&#xA;thirdvalue=&#34;&#34;,secondvalue=&#34;&#34;&#xA;break;&#xA;case &#34;-&#34; :firstvalue=firstvalueu-thirdvalueu ,&#xA;thirdvalue=&#34;&#34;,secondvalue=&#34;&#34;&#xA;break;&#xA;case &#34;x&#34; :firstvalue=firstvalueu*thirdvalueu ,&#xA;thirdvalue=&#34;&#34;,secondvalue=&#34;&#34;&#xA;break;&#xA;case &#34;/&#34; :firstvalue=firstvalueu/thirdvalueu ,&#xA;thirdvalue=&#34;&#34;,secondvalue=&#34;&#34;&#xA;break;&#xA;}&#xA;}&#xA;const equal=document.querySelector(&#34;#equal&#34;)&#xA;equal.addEventListener(&#34;click&#34;,e=&gt;{&#xA;equall()})&#xA;const clean=document.querySelector(&#34;#clean&#34;)&#xA;clean.addEventListener(&#34;click&#34;,e=&gt;{&#xA;let firstvalue=document.querySelector(&#34;#yek&#34;)&#xA;const secondvalue=document.querySelector(&#34;#doo&#34;)&#xA;let thirdvalue=document.querySelector(&#34;#see&#34;)&#xA;firstvalue=&#34;&#34;&#xA;secondvalue=&#34;&#34;&#xA;thirdvalue=&#34;&#34;&#xA;}) https://github.com/mamadhasn/-calculator-with-js ccc</description><category>ممدحسن</category><author>ممدحسن</author><pubDate>Thu, 17 Nov 2022 01:30:54 +0330</pubDate></item><item><title>چگونه با جاوااسکریپت(To do list)بسازیم؟</title><link>https://virgool.ir/@mmdhasnbabaei/ساختن-to-do-list-با-جاوا-اسکریپت-kl3mt1dh7zwv</link><description>یه همچین چیزی قراره بسازیم که وقتی کار رو از لیست تیک می زنیم به شکل پائین نمایش داده بشه و آیکن حذف هم فعال بشه.html&#xA;&lt;div id=&#34;conteaner&#34;&gt;&#xA;&lt;input type=&#34;text&#34; id=&#34;add-work&#34; placeholder=&#34;NAME...&#34;&gt;&#xA;&lt;button id=&#34;btn&#34;&gt;+&#xA;&lt;/button&gt;&#xA;&lt;/div&gt;&#xA;&lt;div id=&#34;listcont&#34;&gt;&lt;/div&gt;&#xA;قسمت csscss&#xA;#conteaner,#listcont{&#xA;display: flex;&#xA;flex-direction: row;&#xA;flex-wrap: nowrap;&#xA;align-content: flex-end;&#xA;justify-content: center;&#xA;align-items: baseline;&#xA;}&#xA;&#xA;#listcont{&#xA;display: flex;&#xA;align-content: space-between;&#xA;justify-content: space-evenly;&#xA;flex-direction: column;&#xA;align-items: baseline;&#xA;}&#xA;#add-work{&#xA;width: 60%;&#xA;padding: 1rem;&#xA;}&#xA;button{&#xA;width: 10%;&#xA;padding: 1rem;&#xA;font-size: 14px;&#xA;font-weight: 900;&#xA;background-color: green;&#xA;}&#xA;span{&#xA;font-size: 30px;}&#xA;#listcont p{&#xA;width: 100%;&#xA;background-color: rgb(197 213 202);&#xA;color: rgb(0, 0, 0);&#xA;display: flex;&#xA;align-content: space-around;&#xA;justify-content: space-between&#xA;}&#xA;a{&#xA;background-color: #000000;&#xA;color: aliceblue;&#xA;font-size: 29px;&#xA;border-radius: 102%;&#xA;}&#xA;span{&#xA;margin-right: auto;&#xA;&#xA;}قسمت جاوااسکریپتjs&#xA;&#xA;//&#39;گرفتن المنت ها&#39;&#xA;const getvalue=document.getElementById(&#34;add-work&#34;)&#xA;const btn=document.getElementById(&#34;btn&#34;)&#xA;const listcont=document.getElementById(&#34;listcont&#34;)&#xA;//چون اول باید المنت ساخته بشه و بعد ما بتونیم بگیریمش  این یعنی ویژگی تک رشته ای&#xA;// جاوااسکریپت که به&#xA;//Asynchronous Javascript&#xA;//معروفه و برای حل این مشکل می تونیم از&#xA;&#xA;//callback&#xA;//promise&#xA;//async await&#xA;//استفاده کنیم&#xA;function first( callback){&#xA;// ساختن المنت ها در جاوااسکریپت و اضافه کردن آن به دام&#xA;btn.addEventListener(&#34;click&#34;,e=&gt;{&#xA;const deletel=document.createElement(&#34;a&#34;)&#xA;deletel.textContent=&#39;x&#39;&#xA;const elementp=document.createElement(&#34;p&#34;)&#xA;const inpu=document.createElement(&#34;input&#34;)&#xA;const tags=document.createElement(&#34;span&#34;)&#xA;inpu.setAttribute(&#34;type&#34;,&#34;checkbox&#34;)&#xA;elementp.append(inpu)&#xA;elementp.append(tags)&#xA;tags+=getvalue.value&#xA;elementp.append( deletel)&#xA;listcont.append(elementp)&#xA;getvalue.value=&#34;&#34;&#xA;callback()&#xA;})&#xA;}&#xA;//تابع دوم که باید بعد تابع اول اجرا بشه و بتونه المنت های رو که میخواهیم رو بگیره&#xA;&#xA;function two(){&#xA;const taker=document.querySelectorAll(&#39;input[type=checkbox]&#39;)&#xA;const span=document.querySelectorAll(&#34;span&#34;)&#xA;const alla=document.querySelectorAll(&#34;a&#34;)&#xA;//  چون آرایه ای از المنت ها رامی گیریم به همین خاطر از فور ایچ&#xA;//استفاده می کنیم&#xA;taker.forEach(e=&gt;{&#xA;e.addEventListener(&#34;change&#34;,e=&gt;{&#xA;//دسترسی به والد وبرادر و خواهر المنت ها&#xA;&#xA;const feed=e.target.nextSibling&#xA;const parentelem=e.target.parentElement&#xA;const aelem=e.target.nextSibling.nextSibling&#xA;if(e.target.checked){&#xA;aelem.style.background=&#34;#FF0000&#34;&#xA;&#xA;aelem.style.borderColor=&#34;black&#34;&#xA;parentelem.style.background=&#34;#33333&#34;&#xA;feed.style.textDecoration=&#34;line-through&#34;&#xA;}else{&#xA;parentelem.style.background=&#34;&#34;&#xA;feed.style.color=&#34;&#34;&#xA;feed.style.textDecoration=&#34;&#34;&#xA;aelem.style.background=&#34;&#34;&#xA;console.log(e.target.checked);&#xA;}&#xA;})&#xA;})&#xA;alla.forEach(e=&gt;{&#xA;&#xA;e.addEventListener(&#34;click&#34;,e=&gt;{&#xA;const checkfordelet=e.target.previousSibling.previousSibling&#xA;if (checkfordelet.checked) {&#xA;const e_target=e.target.parentElement&#xA;e_target.remove()&#xA;}else if(!checkfordelet.checked){&#xA;return false&#xA;}&#xA;})&#xA;})&#xA;}&#xA;//در نهایت فراخوانی تابع اول با کال بک تابع دوم&#xA;&#xA;first(two)کد ها رو می تونید از لینک زیر دانلود کنید https://github.com/mamadhasn/TODOLIST </description><category>ممدحسن</category><author>ممدحسن</author><pubDate>Fri, 11 Nov 2022 15:31:14 +0330</pubDate></item><item><title>اضافه کردن،انتخاب کردن و حذف کردن با جاوا اسکریپت</title><link>https://virgool.ir/@mmdhasnbabaei/اضافه-کردنانتخاب-کردن-و-حذف-کردن-با-جاوا-اسکریپت-x2awfn0uyobm</link><description>ADD,DELETE,SELECTقرار یه همچین چیزی بسازیمHTML&#xA;&lt;h1&gt; ADD ,SELECT, DELETE &lt;/h1&gt;&#xA;&lt;div id=&#34;contn&#34;&gt;&#xA;&lt;div class=&#34;subone&#34;&gt;&#xA;&lt;!-- creat two inputs to take product&#39;s name and price --&gt;&#xA;&lt;label for=&#34;product&#34;&gt;name:&lt;/label&gt;&#xA;&lt;input type=&#34;text&#34; id=&#34;product&#34; placeholder=&#34;name of product&#34;&gt;&lt;br&gt;&#xA;&lt;!-- //creat checkbox to add product existence --&gt;&#xA;&lt;label for=&#34;price&#34;&gt;price:&lt;/label&gt;&#xA;&lt;input type=&#34;text&#34; id=&#34;price&#34; placeholder=&#34;price of product&#34;&gt;&#xA;&lt;input type=&#34;submit&#34; id=&#34;submit&#34;&gt;&#xA;&lt;!-- empety conteaner for add element --&gt;&#xA;&lt;div id=&#34;subconteaner&#34;&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;div id=&#34;secondsub&#34;&gt;&#xA;&lt;!-- //select all element to remove --&gt;&#xA;&lt;label for=&#34;select-ALL_remove&#34;&gt;SELECT ALL&lt;/label&gt;&#xA;&#xA;&lt;input type=&#34;checkbox&#34; id=&#34;select-ALL_remove&#34; name=&#34;select-ALL_remove&#34;&gt;&#xA;&lt;span&gt;and&lt;/span&gt;&#xA;&lt;label for=&#34;remove-all&#34;&gt;remove all&lt;/label&gt;&#xA;&lt;button id=&#34;remove-all&#34;&gt;DELETE ALL&lt;/button&gt;&#xA;&lt;/div&gt;&#xA;CSS&#xA;&#xA;*{&#xA;box-sizing: border-box;&#xA;}&#xA;input[type=&#34;text&#34;]{&#xA;padding: 9px;&#xA;margin-top:13px;&#xA;}&#xA;input[type=&#34;search&#34;]{&#xA;padding: 9px;&#xA;margin-top:13px;&#xA;width: 100%;&#xA;margin-left: -68px;&#xA;}&#xA;&#xA;input[type=&#34;submit&#34;]{&#xA;&#xA;padding: 9px;&#xA;margcolor: aliceblue;&#xA;in-top:13px;&#xA;background-color: black;&#xA;}&#xA;#contn{&#xA;display: flex;&#xA;align-content: space-between;&#xA;justify-content: space-between;&#xA;align-items: baseline;&#xA;flex-direction: column-reverse;&#xA;font-size: larger;&#xA;}&#xA;&#xA;.subone{&#xA;flex:4 ;&#xA;}&#xA;.subtwo{&#xA;flex: 6;&#xA;}&#xA;#subconteaner{&#xA;background-color: rgb(255, 255, 255);&#xA;}&#xA;input[type=&#34;text&#34;]{&#xA;border-radius: 20px;&#xA;border: 3px solid navy;&#xA;width: 300px;&#xA;line-height: 2rem;&#xA;font-size: 20px;&#xA;}&#xA;#remove-all{&#xA;color: wheat;&#xA;padding: 12px;&#xA;border-radius: 23px;&#xA;background-color: black;&#xA;}&#xA;#remove-all:hover{&#xA;background-color: red;&#xA;color: aliceblue;&#xA;}&#xA;#subconteaner button{&#xA;padding: 13px;&#xA;background-color: #783f3f;&#xA;color: aliceblue;&#xA;margin-left: 12px;&#xA;border-radius: 50%;&#xA;box-shadow: 0px 0px 10px 0px #563c3c;&#xA;border: none;&#xA;}&#xA;#subconteaner button:hover{&#xA;background-color: red;&#xA;color: azure;&#xA;}&#xA;h1{&#xA;text-align: center;&#xA;background-color: coral;&#xA;&#xA;}js&#xA;// مرحله اول گرفتن المنت ها&#xA;&#xA;const product=document.getElementById(&#34;product&#34;)&#xA;const price=document.getElementById(&#34;price&#34;)&#xA;const subconteaner=document.getElementById(&#34;subconteaner&#34;)&#xA;const submit=document.getElementById(&#34;submit&#34;)&#xA;&#xA;const select_toremove=document.getElementById(&#34;select-ALL_remove&#34;)&#xA;const remove_all_select=document.getElementById(&#34;remove-all&#34;)&#xA;// تعریف آریه خالی برای پوش کردن ولیو ها&#xA;let myarry=[];&#xA;&#xA;// اد گردن ایونت لیسنر به  باتن سابمیت برای پوش کردن&#xA;submit.addEventListener(&#34;click&#34;,e=&gt;{&#xA;myarry.push(&#xA;{&#xA;name:product.value,&#xA;price:price.value,&#xA;}&#xA;)&#xA;&#xA;// پیمایش آرایه و نمایش ولیو ها&#xA;document.getElementById(&#34;subconteaner&#34;)=&#34;&#34;&#xA;myarry.forEach(e=&gt;{&#xA;const elemnt=document.createElement(&#34;p&#34;)&#xA;&#xA;const span=document.createElement(&#34;button&#34;)&#xA;const cheky=document.createElement(&#34;input&#34;)&#xA;const linky=document.createElement(&#34;a&#34;)&#xA;cheky.setAttribute(&#34;type&#34;,&#34;checkbox&#34;)&#xA;&#xA;span.textContent=&#34;x&#34;&#xA;linky.setAttribute(&#34;href&#34;,&#34;www.school.ir&#34;)&#xA;elemnt.append(cheky)&#xA;elemnt.append(linky)&#xA;linky+=` ${e.name} is ${e.price}$ `&#xA;&#xA;elemnt.append(span)&#xA;document.getElementById(&#34;subconteaner&#34;).append(elemnt)&#xA;// حذف المنمت ها&#xA;span.addEventListener(&#34;click&#34;,e=&gt;{&#xA;elemnt.remove()&#xA;})&#xA; // حذف کلی المنت ها باسلکت اُل&#xA;select_toremove.addEventListener(&#34;change&#34;,e=&gt;{&#xA;if(e.target.checked){&#xA;cheky.checked=true&#xA;}else{&#xA;cheky.checked=false&#xA;}&#xA;})&#xA;remove_all_select.addEventListener(&#34;click&#34;,e=&gt;{&#xA;if(cheky.checked){&#xA;elemnt.remove()&#xA;select_toremove.checked=false&#xA;}&#xA;})&#xA;})&#xA;product.value=&#34;&#34;&#xA;price.value=&#34;&#34;&#xA;})لینک فایل ها https://github.com/mamadhasn/ADD-SELECT-DELETE </description><category>ممدحسن</category><author>ممدحسن</author><pubDate>Thu, 03 Nov 2022 12:04:05 +0330</pubDate></item><item><title>چگونه با جاوااسکریپت یک تایمر بسازیم؟</title><link>https://virgool.ir/@mmdhasnbabaei/چگونه-با-جاوااسکریپت-یک-تایمر-بسازیم-kezuxquiijx4</link><description>شکل تایمرقرار یک تایمر به شکل بالا بسازیم:اول فرض کنید معلم ورزش هستین و قرار از بچه ها امتحان دویدن بگیرین ، حالا با استفاده از تایمر بالا اسم هاشونو در کادر مینویسین بعد دکمه استارت رو میزنین ، بعد اتمام دویدن هر کدوم از دانش آموزا  دکمه فینیش رو میزنین و سر آخر تایمشون رو با دکمه رکورد  در قسمت پا ئین ثپت می کنین و در مرحله پایانی تایم رو ری ست می کنین و برا دانش آموز بعدی این کار رو انجام میدین.حالا که همه دویدن باید بتونیم سه نفر اول رو که تایمشون از بقیه بهتر رو پیدا کنیم خوب اینجا هم دکمه سورت رو می زنیم و تمام(خیلی راحت،آسون،بی دردسر و بی قلم و خودکار و .... :)داستان تموم شد بریم سراغ  قسمت جالب قضیه :html&#xA;&lt;div id=&#34;cont&#34;&gt;&#xA;&lt;h1 id=&#34;go&#34;&gt;00:00:00&lt;/h1&gt;&#xA;&lt;div id=&#34;inpu&#34;&gt;&#xA;&lt;label for=&#34;esmesh&#34;&gt;NAME OF RUNNER&lt;/label&gt;&lt;br&gt;&#xA;&lt;input type=&#34;text&#34; id=&#34;esmesh&#34; placeholder=&#34;enter runner name&#34;&gt;&lt;br&gt;&#xA;&lt;/div&gt;&#xA;&lt;div id=&#34;btu&#34;&gt;&#xA;&lt;button id=&#34;start&#34;&gt;start&lt;/button&gt;&#xA;&lt;button id=&#34;finish&#34;&gt;finish&lt;/button&gt;&#xA;&lt;button id=&#34;register&#34;&gt;record&lt;/button&gt;&#xA;&lt;button id=&#34;reset&#34;&gt;reset&lt;/button&gt;&#xA;&lt;/div&gt;&#xA;&lt;button id=&#34;SORT&#34;&gt;SORT RUNNER BY THEIR TIME&lt;/button&gt;&#xA;&lt;div id=&#34;add&#34;&gt;&lt;/div&gt;&#xA;&lt;/div&gt;css&#xA;.cont{&#xA;text-align: center;&#xA;display: flex;&#xA;flex-direction: column;&#xA;}&#xA;h1{&#xA;background-color:#07d30a ;&#xA;display: block;&#xA;font-size: 90px;&#xA;}&#xA;@media screen and (max-width: 480px) {&#xA;body {&#xA;background-color: lightgreen;&#xA;}&#xA;h1{&#xA;background-color:#07d30a ;&#xA;display: block;&#xA;font-size: 34px;&#xA;}}&#xA;#btu{&#xA;margin-top: 3rem;&#xA;}&#xA;button{&#xA;padding: 20px;&#xA;background-color: black;&#xA;color: aliceblue;&#xA;border-radius: 12px;&#xA;}&#xA;span{&#xA;line-height: 12px;&#xA;background-color: aqua;&#xA;}&#xA;label{&#xA;background-color: rgb(0 0 0);&#xA;color: rgb(36 209 15);&#xA;font-weight: bold;&#xA;font-size: 30px;&#xA;}&#xA;input{&#xA;padding: 20px;&#xA;}&#xA;li{&#xA;list-style-type: auto;&#xA;line-height: 35px;&#xA;margin-top: 20px;&#xA;background-color: #07d30a;&#xA;}javascript&#xA;//گرفتن  المنت های مدنظر&#xA;const esmesh=document.getElementById(&#34;esmesh&#34;)&#xA;const start=document.getElementById(&#34;start&#34;)&#xA;const register=document.getElementById(&#34;register&#34;)&#xA;const finish=document.getElementById(&#34;finish&#34;)&#xA;const reset=document.getElementById(&#34;reset&#34;)&#xA;const hh=document.getElementById(&#34;go&#34;)&#xA;const sort=document.getElementById(&#34;SORT&#34;)&#xA;//تعریف آرایه خالی برای پوش کردن اسم و تایم دونده ها&#xA;let all_Arry=[];&#xA;let mili=0;&#xA;let sec=0;&#xA;let min=0&#xA;let hor=0;&#xA;let every;&#xA;// استفاده از ایونت ها&#xA;start.addEventListener(&#34;click&#34;,e=&gt;{&#xA;every= setInterval(() =&gt; { timer(); }, 10);&#xA;})&#xA;&#xA;register.addEventListener(&#34;click&#34;,e=&gt;{&#xA;const elem=document.createElement(&#34;li&#34;)&#xA;elem.textContent=`${esmesh.value} time is${hor}:${min}:${sec}:${mili} `&#xA;document.getElementById(&#34;add&#34;).append(elem)&#xA;all_Arry.push({&#xA;name:esmesh.value,&#xA;time:parseInt(hor*24*60*60*1000+min*60*1000+sec*1000+mili)&#xA;})&#xA;console.log(all_Arry);&#xA;esmesh.value=&#34;&#34;&#xA;})&#xA;finish.addEventListener(&#34;click&#34;,e=&gt;{&#xA;clearInterval(every)&#xA;})&#xA;reset.addEventListener(&#34;click&#34;,e=&gt;{&#xA;sec=0;&#xA;min=0&#xA;hor=0;&#xA;hh=`00:00:00`&#xA;})&#xA;function timer(){&#xA;mili+=10;&#xA;if(mili==1000){&#xA;sec++;&#xA;sec=sec&lt;10 ? &#34;0&#34;+sec:sec&#xA;return mili=0&#xA;}&#xA;if(sec===60){&#xA;min++;&#xA;min=min&lt;10 ? &#34;0&#34;+min:min&#xA;return sec=0&#xA;}&#xA;if(min===60){&#xA;hor++;&#xA;hor=hor&lt;10 ? &#34;0&#34;+hor:hor&#xA;return min=0&#xA;}&#xA;&#xA;hh=`${hor}:${min}:${sec}:${mili}`&#xA;}&#xA;sort.addEventListener(&#34;click&#34;,e=&gt;{&#xA;let sorted= all_Arry.sort((a,b)=&gt;{&#xA;return  b.time-a.time&#xA;})&#xA;&#xA;&#xA;const dele=document.getElementById(&#34;add&#34;)&#xA;dele.textContent=&#34;&#34;&#xA;sorted.forEach(e=&gt;{&#xA;let ms = e.time&#xA;let sanie= Math.floor((ms/1000/60) &lt;&lt; 0)&#xA;let dagig = Math.floor((ms/1000) % 60);&#xA;const elem=document.createElement(&#34;li&#34;)&#xA;&#xA;elem.textContent=`${e.name} time is ${dagig}min and ${sanie}sec `&#xA;document.getElementById(&#34;add&#34;).append(elem)&#xA;})&#xA;&#xA;})فایل ها رو میتونید از لینک زیر دانلود کنید https://github.com/mamadhasn/RUNNER-TIMER در  پست بعدی  انشالله  به طور کامل به توضیح کد ها می پردازم :)</description><category>ممدحسن</category><author>ممدحسن</author><pubDate>Sat, 29 Oct 2022 20:07:53 +0330</pubDate></item></channel></rss>