<?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: Dhanush P</title>
    <description>The latest articles on DEV Community by Dhanush P (@pdhanush26).</description>
    <link>https://dev.to/pdhanush26</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%2F3924263%2Fd4731e1b-f0fc-4c42-8631-01a009bd09fc.jpg</url>
      <title>DEV Community: Dhanush P</title>
      <link>https://dev.to/pdhanush26</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/pdhanush26"/>
    <language>en</language>
    <item>
      <title>Cascading Style Sheets(CSS)</title>
      <dc:creator>Dhanush P</dc:creator>
      <pubDate>Fri, 15 May 2026 17:30:43 +0000</pubDate>
      <link>https://dev.to/pdhanush26/cascading-style-sheetscss-3p3g</link>
      <guid>https://dev.to/pdhanush26/cascading-style-sheetscss-3p3g</guid>
      <description>&lt;p&gt;&lt;strong&gt;Introduction to CSS&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;CSS stands for Cascading Style Sheets.&lt;/li&gt;
&lt;li&gt;CSS used to describe the presentation of a HTML document.&lt;/li&gt;
&lt;li&gt;It allows you to apply styles to HTML documents by prescribing colors, fonts, spacing and positioning.&lt;/li&gt;
&lt;li&gt;CSS styles are applied to the HTML element using selectors.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;CSS Syntax&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;CSS syntax consists of a selector and a declaration block. &lt;/li&gt;
&lt;li&gt;The selector targets an HTML element, and the declaration block contains property value pairs.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;selector&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
   &lt;span class="py"&gt;property&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;value&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;p&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;red&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Types of CSS&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;There are three major ways to apply CSS to web pages: &lt;strong&gt;Inline, Internal and External&lt;/strong&gt; CSS.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;1. Inline CSS&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;It is used to apply CSS styles directly to the HTML tags by using the “style” attribute.&lt;/li&gt;
&lt;li&gt;The style attribute is a global attribute that can be used with all HTML tags.&lt;/li&gt;
&lt;li&gt;Inline CSS is used to apply a unique style to a single HTML element.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Example: Using Inline Style to Apply CSS&lt;/strong&gt;&lt;br&gt;
&lt;code&gt;&amp;lt;p style="color: red; font-size: 18px;"&amp;gt;This is a red paragraph.&amp;lt;/p&amp;gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Internal CSS&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;It uses the &lt;code&gt;&amp;lt;style&amp;gt;&lt;/code&gt; tag, placed under the &lt;code&gt;&amp;lt;head&amp;gt;&lt;/code&gt; section, and all the CSS properties are written under the &lt;code&gt;&amp;lt;style&amp;gt;&lt;/code&gt; tag.&lt;/li&gt;
&lt;li&gt;It is used to define a style for a single HTML page.&lt;/li&gt;
&lt;li&gt;This styles affects all matching elements in that document.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Example: Using Internal Style to Apply CSS&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;head&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;title&amp;gt;&lt;/span&gt;Internal Style&lt;span class="nt"&gt;&amp;lt;/title&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;style&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
           &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;lightblue&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="nt"&gt;h1&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
           &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;40px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
           &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;navy&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
           &lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;/style&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/head&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;h1&amp;gt;&lt;/span&gt;Example for Internal Style Sheet&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;3. External CSS&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;External CSS is written in a separate file, which is saved with a &lt;code&gt;.css&lt;/code&gt; extension, and linked to the HTML file by using the &lt;code&gt;&amp;lt;link&amp;gt;&lt;/code&gt; tag in the &lt;code&gt;&amp;lt;head&amp;gt;&lt;/code&gt; section.&lt;/li&gt;
&lt;li&gt;CSS file must not contain any HTML code.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Example: Use External Style to Apply CSS&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;// index.html&lt;/em&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;head&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;title&amp;gt;&lt;/span&gt;External CSS&lt;span class="nt"&gt;&amp;lt;/title&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;link&lt;/span&gt; &lt;span class="na"&gt;rel=&lt;/span&gt;&lt;span class="s"&gt;"stylesheet"&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"text/css"&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"style.css"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/head&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;h1&amp;gt;&lt;/span&gt;Example for External Style Sheet&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;// style.css&lt;/em&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;lightcoral&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nt"&gt;h1&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;50px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;text-align&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;What is Selectors?&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Selectors are used to target the HTML elements on our web pages that we want to style.&lt;/li&gt;
&lt;li&gt;Used to select HTML elements based on tag name, class, id, or attributes.&lt;/li&gt;
&lt;li&gt;It helps apply styles like color, font, spacing, and layout.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Selector Types(Basic)&lt;/strong&gt;&lt;br&gt;
1.Element selector &lt;code&gt;h1, p, body&lt;/code&gt;&lt;br&gt;
2.Class Selector &lt;code&gt;.class-name&lt;/code&gt; &lt;br&gt;
3.Id selector &lt;code&gt;#id-name&lt;/code&gt;&lt;br&gt;
4.Global selector &lt;code&gt;*&lt;/code&gt; (apply this for entire website)&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CSS Properties:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;code&gt;border: 2px solid blue;&lt;/code&gt; - Allows you to define an outline around an HTML element.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;margin: 5px;&lt;/code&gt; - Used to create space outside of element's border.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;padding: 5px;&lt;/code&gt; - Used to create space inside of element's border.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;text-align: center;&lt;/code&gt; - Specifies the horizontal alignment of text in an element.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;text-decoration: none;&lt;/code&gt; -  Specifies the decoration added to text.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;border-radius: 10px;&lt;/code&gt; - Defines the radius of the element's corners.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;display: grid;&lt;/code&gt; - How an element is displayed on a webpage.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;grid-template-columns: 1fr 2fr;&lt;/code&gt; - Defines the number and size of columns in a grid layout.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;justify-content: space-around;&lt;/code&gt; Aligns the flexible container's items&lt;/li&gt;
&lt;/ol&gt;

</description>
      <category>css</category>
      <category>webdev</category>
      <category>frontend</category>
    </item>
    <item>
      <title>Day 1: HTML Learning</title>
      <dc:creator>Dhanush P</dc:creator>
      <pubDate>Tue, 12 May 2026 10:21:38 +0000</pubDate>
      <link>https://dev.to/pdhanush26/html-learning-3ieb</link>
      <guid>https://dev.to/pdhanush26/html-learning-3ieb</guid>
      <description>&lt;p&gt;&lt;strong&gt;HTML&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;HTML stands for &lt;strong&gt;Hypertext Markup Language&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;It is used to create structure and layout of web pages.&lt;/li&gt;
&lt;li&gt;It defines basic structure of web pages and contains &lt;strong&gt;meta-data&lt;/strong&gt; about the page. &lt;/li&gt;
&lt;li&gt;It uses predefined &lt;strong&gt;tags&lt;/strong&gt; such as &lt;code&gt;&amp;lt;body&amp;gt;, &amp;lt;table&amp;gt;, &amp;lt;form&amp;gt;&lt;/code&gt; etc.&lt;/li&gt;
&lt;li&gt;&lt;p&gt;It consist of a series of &lt;strong&gt;elements&lt;/strong&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;We can save html files using two ways. file extension &lt;code&gt;.html or .htm&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!DOCTYPE html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&amp;gt;&lt;/span&gt;
     &lt;span class="nt"&gt;&amp;lt;head&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;title&amp;gt;&lt;/span&gt;HTML Learning&lt;span class="nt"&gt;&amp;lt;/title&amp;gt;&lt;/span&gt;
     &lt;span class="nt"&gt;&amp;lt;/head&amp;gt;&lt;/span&gt;
     &lt;span class="nt"&gt;&amp;lt;body&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;h1&amp;gt;&lt;/span&gt;Heading 1&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Html stands for hypertext markup language&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
     &lt;span class="nt"&gt;&amp;lt;/body&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;META-DATA&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Metadata means data about data.&lt;/li&gt;
&lt;li&gt;It is data that provides information about other data, offering context and meaning to raw information.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Examples:&lt;/strong&gt; For a photograph, metadata includes camera settings, date/time taken, GPS location, and file format. For a document, it includes author, creation date, and document type.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ELEMENT&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Each element requires starting tag and ending tag with content inside it.
Example: &lt;code&gt;&amp;lt;h2&amp;gt;This is example for element&amp;lt;/h2&amp;gt;&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;MARKUP LANGUAGE&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;A markup language is a system of annotating a document to describe its structure and presentation.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Markup languages are used to structure, format, or define relationships between different parts of text documents with the help of tags inserted in the document.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;It uses tags or codes to define elements such as headings, paragraphs, lists, images, links, and more.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;More readable than usual programming.&lt;br&gt;
Example: &lt;code&gt;HTML, XML, XHTML, SGML&lt;/code&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;FILE EXTENSION&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A file extension is a suffix at the end of a computer filename.&lt;/li&gt;
&lt;li&gt;It usually three or four letters preceded by a dot.&lt;/li&gt;
&lt;li&gt;That identifies the file type and indicates which application should open it.
Example: &lt;code&gt;.pdf, .txt, .jpg, .java, .html, .css&lt;/code&gt; &lt;/li&gt;
&lt;/ul&gt;

</description>
    </item>
  </channel>
</rss>
