.

Wednesday, January 27, 2016

Attributes in HTML | Lesson 7 |Attributes kya hote hain

author photo



Learn Html In Hindi | Attributes Ko Jaane


Aapne abhi tak Tags aur Element ke bare me jaana. Waise to aap abhi tak 6 lesson seekh chuke hain. Aur mera manna hai aap zarror ache se seekh rahe honge. Aaj hum Html ke new lesson me aatpke liye kuch jankari lekar aaye hai. To chaliye pahle ye jante hain ki aaj hum kya seekhenge.

  *  Attribute Kya hote hain
  *  Attributes kaise use kiye jate hain
  *  Main Attributes kaun kaun se hain
  *  Generic Attributes kaun se hain

Attributes Kya hote hain:

Sabse pahle hum ye baat karenge ki aakhir attributes hote kya hain. Attributes Elements me use hui kuch extra information hoti hai. Jiske dwara ek element ki characteristics(व्यव्हार) ko darshaya jata hai. Aur Attributes ko element ke opening tag me hi use kiya jata hai. Attribute ke 2 part hote hain. Pahle part me attribute ka naam aur dusre part me uski value use ki jati hai. Attribute ke naam ka matlab hai ki wo element ke kaun se characteristic ko batata hai. Chaliye is eek example se samajhte hain.



Attributes Kaise Use Hote Hain:

Exampale ke liye main ek Attribute leta hoon jiska naam hai “align”, align ka matlab hai स्थान. Aur iski value hui Left, Center, Right. Mano main ek paragraph likhta hoon. Jise main center me karna chahta hoon to hum kya karenge. Pichle lesson me hamne ye dekha tha ki paragraph ko hum center me kaise use Karenge. Tab us time hum log Tags padh rahe the, tab hum logo ne paragraph ko <center> aur </center> tag ke beech me likha tha. Tab isse bhi hamara paragraph center me ho gaya tha. But friends ab hum Attributes padh rahe hain tab hum iska itemal karenge.

                                      To hum agar kisi paragraph ko browser me teeno jagah (left ,center aur right) me kaise show karenge iska example dekhte hain. Main yaha par ek paragraph ki jagah 3 use karunga. Jisme ek ko right, ek ko enter, ek ko left me show karunga.

<!DOCTYPE html>
<html>
<head>
<title> Attribute Example </title>
</head>
<body>

<p align=”left”>  Yah LEFT me likha hai </p>
<p align=”center”>  Yah CENTER me likha hai </p>
<p align=”right”> Yah RIGHT me likha hai  </p>

</body>
</html>
 
Ab Iska output dekhte hain. Kya jaisa hum chahte hain wahi aaya.




          



Haan theek waisa hi aaya. To dosto hamne yaha Align attribute ko use kiya hai. Attributes hamesha align=”center” ke form me hi use kiye jate hain. Jaha Aligh attribute ka naam hai jiska kaam text ko position dena hai. Aur center uski value hai, matlab text ko kaha position karna hai.

Attributes kaun kaun se hain : 
              1.    Core Attributes
              2.    Genetic Attributes



Core Attributes:

Core shabd ka arth hai मुख्यतः. To kuch core attributes jo commonly use hote hain wo neeche diye hai.

      1.    Title
      2.    Style
      3.    Id
      4.    Class

Upar diye 4 core aatributes me se pahle do ko hum example se samjhenge baaki do ko css ke time par bataya jayega. Bas basic me samjhenge.

Title Attribute:


Title tag ka use element ko title den eke liye use hota hai. Kabhi kabhi iske result me changes bhi aate hai wo is liye jis element me iska use kiya jata hai yah us element ke behavior ke hisab se result deta hai. Chaliye ise kaise use karte hain iska ek example dekhte hain.

<!DOCTYPE html>
<html>
<head>
<title> Title Attribute example </title>
</head>
<body>
<p title="Hello Friends">  Yah LEFT me likha hai </p>
</body>
</html>

Ab hame iska output bade dhyan se dekhna hai. Chaliye dekhte hain.




Title attribute hame tab dikhayin dega jab hum iske upar cursor rakhenge. Jiase hi cursor upar aayega. To job hi title me likha hoga wo ek box me show hone lagega. Jaisa aapne upar screenshot me dekha.

Style Attribute:


Style attribute ko hum jab use karte hain jab hame kisi element ka style change karna hota hai. Jaise maano main ek paragraph leta hoon usme kuch style jaise font, color change karenge. Dhyan rahe dosto style tag kewal ek element ke style matlab css ko hi change kar sakega. Style attribute ko kaise likhenge.

style="font-family:arial; color:#FF0000;"

Yaha hamne 2 property ek sath use ki hain. Dono ko alag karne ke liye beech me gap hona chahiye aur isme = ki jagah : ka use hota hai aur baad me ; ka use hota hai.  Yaha maine color me code use kiya hai jo ki Red ka # (Hash ) code hai. Jaisa upar show ho raha hai. Code ki jagah hum color name bhi use kar sakte hain .Chaliye ek example dekhte hain.


<!DOCTYPE html>
<html>
<head>
<title> style Attribute example </title>
</head>
<body>
<p style="font-family:arial; color:#FF0000;"> Digit Only Par aap Html Seekh Rahe Hain </p>
</body>
</html>

Ab iska example dekhte hain.




Id  and Class Attribute :


Jab hame kisi elment ko bahut bade Html code me alag se dikhana hota hai tab use ek aglag se id de di jati hai. Jiski help se use aasani se pahchana ja sakta hai. Id ke bare me hum abhi nahi samjhenge.

Class attribute bhi same kaam karta hai. Jab ham eek se adhik element jo ek jaise hai, ko alag alag css apply karni hoti hai tab hum classes ka use karte hain. Abhi hum classes ke bare me nahi samjhenge. Id aur classes ke bare me samjhane ke liye hum alag se ek lesson lenge.


Generic Attributes :

Generic attributes kya hote hain abhi batana theek nahi hai, but ye batana jaroori hai ki kaun kaun se hote hain. Aaage hum inhe use karenge. Abhi hun inhe kewal ek table me samjhenge.



 Note: Aaj tak aap logo ne 7 tutorials ko seekh liya hai. Ab aap 2-3 din me in sab par apna code likhe aur practice kare. Aaj ka tutorial lamba tha is liye ispar practice bahut zarrori hai. Aur aap jab koi tutorial seekhe to pichla zarror revise kar liya kare.

Next Tutorial me hum seekhenge, Html Formatting. Jise ham seekhenge italic , bold, underline, superscript, subscript, insert text, delete text, span element and grouping content.


To Dosto aapko aaj ka tutorial kaisa laga. Hame zarror bataye. Article ko share kare jisse aapke dost bhi seekh sake aur hamari post ko like zarror kare.

This post have 9 comments

avatar
Sandeep Singh delete February 21, 2016 12:28 pm

Hello sir my name Deep
main aapke blog par abhi aaya hu aap ke html lessons sabhi read kiye aur usse seekhne ko bhi mila lekin aaj lesson 8 dekhne ke liye aaya toh yaha toh 7 se aage hai hi nhi
plz sir aap aage likhiye html ke bare main aur is ke baad css bhi start karna plz sir

Reply
avatar
Digit Only delete February 21, 2016 2:25 pm

sandeep aapko age ke lesson bhi sikhaye jayenge. bas kuch intezar karna higa. aap blogging bhi start kare aur paise kamaye.

Reply
avatar
Sandeep Singh delete February 21, 2016 4:20 pm

sir plz give me your whatssapp number

Reply
avatar
Sandeep Singh delete February 21, 2016 7:26 pm

sir kis topic par mujhe blog start karni chahiye

Reply
avatar
Digit Only delete February 22, 2016 12:32 pm

pahle to aap ye soche ki aapko kis topic ke baare me acchi jankari hai. aaj kal mobile aur apps ke baare me blog banana bahur easy hai. agar aapke paas ek android phone hai to aap android apps ke baare me likhna shuru kare. sath hi new mobiles ke baare me bhi aap likh sakte hain.

Reply
avatar
Digit Only delete February 22, 2016 12:33 pm

main aapko no nahi de sakta. aap apna no de dijiye main aapko whatsapp se contact kar lunga.

Reply
avatar
Sandeep Singh delete February 24, 2016 10:37 am

sir next lesson kab post karoge
i m waiting for next lesson

Reply
avatar
I am Asad Biggest Fan Of Balveer delete November 27, 2016 1:21 am

sir aapki is post me aapne 1 choti si galti kardi he screnshot upar wala niche or niche wala upar kar dia he

Reply
avatar
Digit Only delete December 21, 2016 12:05 am

ji asad aapne sahi kaha,ye galti se ho gaya, batane ke liye aapka dhanyabad.

Reply


EmoticonEmoticon

Next article Next Post
Previous article Previous Post

Advertisement