<?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: Allan Sam</title>
    <description>The latest articles on DEV Community by Allan Sam (@allansamcodes).</description>
    <link>https://dev.to/allansamcodes</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%2F945866%2F93788d93-7eb5-45ce-9b38-149a74a72476.jpeg</url>
      <title>DEV Community: Allan Sam</title>
      <link>https://dev.to/allansamcodes</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/allansamcodes"/>
    <language>en</language>
    <item>
      <title>CSS Selectors</title>
      <dc:creator>Allan Sam</dc:creator>
      <pubDate>Sun, 16 Oct 2022 16:59:35 +0000</pubDate>
      <link>https://dev.to/allansamcodes/css-selectors-44aa</link>
      <guid>https://dev.to/allansamcodes/css-selectors-44aa</guid>
      <description>&lt;p&gt;what is CSS selectors ?&lt;/p&gt;

&lt;p&gt;CSS selectors are used to "find" (or select) the HTML elements you want to style.&lt;/p&gt;

&lt;p&gt;We can divide CSS selectors into five categories:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;-Simple selectors (select elements based on name, id, class)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--vMNOTITU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://blog.openreplay.com/static/c45fd938ad466d46d60dd72c9c18fd85/6050d/hero.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--vMNOTITU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://blog.openreplay.com/static/c45fd938ad466d46d60dd72c9c18fd85/6050d/hero.png" alt="Simple CSS Selectors" width="880" height="495"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Basic selectors&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;They select element/id/class. They are also used most often and easiest to remember.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Id selector&lt;/em&gt;&lt;/strong&gt;: &lt;code&gt;id&lt;/code&gt; It selects a given element.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;div id="app"&amp;gt;
  &amp;lt;div class="container"&amp;gt;
    &amp;lt;p class="hello"&amp;gt;Hello&amp;lt;/p&amp;gt;
  &amp;lt;/div&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;&lt;em&gt;Element selector&lt;/em&gt;&lt;/strong&gt;: &lt;code&gt;element_name&lt;/code&gt; It selects any given element.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;p { color: blue; }
div { color: magenta; }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;&lt;em&gt;Class selector&lt;/em&gt;&lt;/strong&gt;: &lt;code&gt;.class&lt;/code&gt; It selects all element containing given class name.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;.hello {
  color: red;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;&lt;em&gt;ID selector&lt;/em&gt;&lt;/strong&gt;: &lt;code&gt;#id&lt;/code&gt; It selects the element containing given HTML ID.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;#app {
  color: red;
}

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

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;&lt;em&gt;Universal selector&lt;/em&gt;&lt;/strong&gt;: &lt;code&gt;*&lt;/code&gt; It selects all elements.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;* {
  color: yellow;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;The CSS Grouping Selector&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The grouping selector selects all the HTML elements with the same style definitions.&lt;/p&gt;

&lt;p&gt;Look at the following CSS code (the h1, h2, and p elements have the same style definitions):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;h1 {
  text-align: center;
  color: red;
}

h2 {
  text-align: center;
  color: red;
}

p {
  text-align: center;
  color: red;
}

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

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Attribute selectors :&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This group of selectors gives you different ways to select elements based on the presence of a certain attribute on an element:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;a[href="https://example.com"]
{
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I hope this blogs helps to understand CSS selectors.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>How semantic elements are used in Html</title>
      <dc:creator>Allan Sam</dc:creator>
      <pubDate>Sun, 16 Oct 2022 16:12:47 +0000</pubDate>
      <link>https://dev.to/allansamcodes/how-semantic-elements-used-in-html-24gn</link>
      <guid>https://dev.to/allansamcodes/how-semantic-elements-used-in-html-24gn</guid>
      <description>&lt;p&gt;If your are already aware of semantic html then let me give you  my view or if you are new to the idea how the semantic html work? Let's know about it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What are Semantic Elements?&lt;/strong&gt;&lt;br&gt;
A semantic element clearly describes its meaning to both the browser and the developer.&lt;/p&gt;

&lt;p&gt;Examples of &lt;strong&gt;semantic elements&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;form&lt;/li&gt;
&lt;li&gt;table&lt;/li&gt;
&lt;li&gt;article&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;As you can see, these html elements provide explanation to the developer and browser what they do.&lt;/p&gt;

&lt;p&gt;Examples of &lt;strong&gt;non-semantic elements&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;_div and span _&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Tells nothing about its content.&lt;/p&gt;

&lt;p&gt;These are some of the examples of semantic and non-semantic elements in html.&lt;/p&gt;

&lt;p&gt;In HTML, We can use the below semantic elements to describe the different parts of a page.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--NEci0xAc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dotnettutorials.net/wp-content/uploads/2021/12/word-image-167.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NEci0xAc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dotnettutorials.net/wp-content/uploads/2021/12/word-image-167.png" alt="Image description" width="794" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;.header&lt;br&gt;
.nav&lt;br&gt;
.section&lt;br&gt;
.article&lt;br&gt;
.aside&lt;br&gt;
.footer&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;HTML _header&lt;/em&gt; Element_&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;-The &lt;strong&gt;_header _&lt;/strong&gt;element represents a container for introductory content or a set of navigational links.&lt;/p&gt;

&lt;p&gt;A &lt;strong&gt;&lt;em&gt;&lt;em&gt;header&lt;/em&gt;&lt;/em&gt;&lt;/strong&gt; element typically contains:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;one or more heading elements {h1 - h6}&lt;/li&gt;
&lt;li&gt;logo or icon&lt;/li&gt;
&lt;li&gt;authorship information&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;HTML &lt;em&gt;footer&lt;/em&gt; Element&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;-The &lt;strong&gt;&lt;em&gt;footer&lt;/em&gt;&lt;/strong&gt; element defines a footer for a document or section.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;HTML_ nav_ Element&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;-The major block of navigation links is contained &lt;br&gt;
 within the &lt;em&gt;nav&lt;/em&gt; element. &lt;br&gt;
-It can include links to the same page as well as links &lt;br&gt;
 to different pages. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;HTML _aside&lt;/em&gt; Element_&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;-The &lt;strong&gt;&lt;em&gt;aside&lt;/em&gt;&lt;/strong&gt; element defines some content aside from the content it is placed in (like a sidebar).Articles can be used to create blog posts, product cards, news articles, etc.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;A &lt;strong&gt;footer&lt;/strong&gt; element typically contains:&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;authorship information&lt;/li&gt;
&lt;li&gt;back to top links&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This how the sematic Element in Html does it's magic.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>beginners</category>
      <category>tutorial</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
