• Login
Community
  • Login

Between html/css tags

Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
3 Posts 3 Posters 866 Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M
    Matija Savić
    last edited by Jan 28, 2019, 10:17 AM

    Hi, i started learning HTML and CSS and i would like to whenever i put something in between tags, let’s say

    <html>

    </html>

    to go a bit right, and not left, here’s what i mean :

    <html>

       sjaisjaisjia
    

    </html>

    and not like this

    <html>
    sjiasjaiosjaioisja
    </html>

    it’s kinda ugly like that, is there a option in settings to remove this and set it up like i want?

    M 1 Reply Last reply Jan 28, 2019, 10:32 AM Reply Quote 0
    • M
      Meta Chuh moderator @Matija Savić
      last edited by Meta Chuh Jan 28, 2019, 10:58 AM Jan 28, 2019, 10:32 AM

      welcome to the notepad++ community, @Matija-Savić

      there are many ways to do indenting in html output.

      if you want to output your text the same way as you see it in notepad++ (pre-formatted), you can use the <pre> tag.

      for example:

      <html>
      	<pre>
      	my text
      		more text
      			even more text
      	</pre>
      </html>
      

      will look like this in a browser window:

      	my text
      		more text
      			even more text
      

      you can find more ways about how to do html output indenting here: http://www.blooberry.com/indexdot/html/topics/indent.htm

      note:
      if you just want to indent your html source code in notepad++, just press the tab key at the beginning of a line (for example the line below <html>).
      all following lines will also start at the same position as this one, the same amount of tabs you used at the line above will automatically be added to the next one, like seen at the screenshot below:

      Imgur.

      1 Reply Last reply Reply Quote 3
      • A
        andrecool-68
        last edited by Jan 29, 2019, 6:10 AM

        1. Try enabling the option:
          Settings >> Preferences >> MISC >> Auto-indent
        2. Test the Tidy 2 plugin, it can format the finished code.
        1 Reply Last reply Reply Quote 1
        1 out of 3
        • First post
          1/3
          Last post
        The Community of users of the Notepad++ text editor.
        Powered by NodeBB | Contributors