Community
    • Login

    Between html/css tags

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    3 Posts 3 Posters 1.3k Views 1 Watching
    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.
    • Matija SavićM Offline
      Matija Savić
      last edited by

      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?

      Meta ChuhM 1 Reply Last reply Reply Quote 0
      • Meta ChuhM Offline
        Meta Chuh moderator @Matija Savić
        last edited by Meta Chuh

        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
        • andrecool-68A Offline
          andrecool-68
          last edited by

          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

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post
          The Community of users of the Notepad++ text editor.
          Powered by NodeBB | Contributors