Community
    • 登入

    Is there any way to auto insert tag end in html/php

    已排程 已置頂 已鎖定 已移動 Help wanted · · · – – – · · ·
    phphtml
    10 貼文 3 Posters 10.6k 瀏覽
    正在載入更多貼文
    • 從舊到新
    • 從新到舊
    • 最多點贊
    回覆
    • 在新貼文中回覆
    登入後回覆
    此主題已被刪除。只有擁有主題管理權限的使用者可以查看。
    • rowan harleyR
      rowan harley
      最後由 編輯

      Is there any way to auto-create the end tag (e.g. Auto-Create the </html> tag when I type <html>) in php/html like a plugin or a setting

      Claudia FrankC 1 條回覆 最後回覆 回覆 引用 0
      • Claudia FrankC
        Claudia Frank @rowan harley
        最後由 Claudia Frank 編輯

        Hello rowan-harley,

        this can be achieved by switching between php and html language.
        ALT+L+H+H+ENTER -> html
        ALT+L+P+P+P+ENTER -> php
        (assuming you did not modify your language menu)

        Cheers
        Claudia

        1 條回覆 最後回覆 回覆 引用 0
        • dailD
          dail
          最後由 編輯

          Settings > Preferences > Auto-Completion > html/xml close tags

          1 條回覆 最後回覆 回覆 引用 0
          • Claudia FrankC
            Claudia Frank
            最後由 編輯

            Hello dail,

            should this work if a language like php is selected. If so,
            than there is a problem, it doesn’t work on my side.

            Cheers
            Claudia

            1 條回覆 最後回覆 回覆 引用 0
            • dailD
              dail
              最後由 編輯

              Hmm…I’m actually not sure…I’ve only ever used it for XML.

              1 條回覆 最後回覆 回覆 引用 0
              • Claudia FrankC
                Claudia Frank
                最後由 編輯

                And there is another one … if I use it and use html or xml language
                I get two closing tags. <xml></xml></xml>
                When using php I don’t get any closing tag.

                NPP 6.8.7
                Windows 7 x64

                Cheers
                Claudia

                1 條回覆 最後回覆 回覆 引用 0
                • dailD
                  dail
                  最後由 編輯

                  It is probably because you have XML Tools installed to autoclose tags. I’ve never used XML Tools but it may be a better option than the built-in autocomplete for tags

                  1 條回覆 最後回覆 回覆 引用 0
                  • Claudia FrankC
                    Claudia Frank
                    最後由 編輯

                    @dail,
                    shame on me - I didn’t do what I always propose to others.
                    You’re right, when running with noPlugin switch it works but still
                    only when using html or xml language.

                    In addition I need to see if xml tools has a bug, because I didn’t use the auto close tag feature
                    or maybe another plugin intersected.

                    Cheers
                    Claudia

                    1 條回覆 最後回覆 回覆 引用 0
                    • Claudia FrankC
                      Claudia Frank
                      最後由 編輯

                      ok, found TextFX Settings has also a autoclose feature which was, in my case, enabled.
                      So, XML Tools has been discharged.

                      Cheers
                      Claudia

                      1 條回覆 最後回覆 回覆 引用 0
                      • rowan harleyR
                        rowan harley
                        最後由 編輯

                        Ok, thanks! I’ll just have to keep switching over from php to html when doing the tags

                        1 條回覆 最後回覆 回覆 引用 0
                        • 第一個貼文
                          最後的貼文
                        The Community of users of the Notepad++ text editor.
                        Powered by NodeBB | Contributors