• Login
Community
  • Login

BUG: Problem with syntax highlighting: Not working on ASP Classic Scripts

Scheduled Pinned Locked Moved General Discussion
asphighlighthighlightingbug
17 Posts 13 Posters 3.8k 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.
  • S
    SalviaSage
    last edited by May 25, 2019, 9:16 PM

    What file extension is that?
    Can you also give me some sample code so I can test it from my end?

    Thanks.

    D 1 Reply Last reply May 26, 2019, 2:08 AM Reply Quote 0
    • D
      DirtyEcho @dail
      last edited by May 26, 2019, 1:47 AM

      @dail This is an example of an ASP Script:

      <%
      Session(“display”) = “Regitrazione”
      Session(“link”) = “register.asp”
      %>

      Normally in Notepad++ (until the 7.6.6 release) the content inside the ASP tags (“<% … %>”) was highlighted in light blue, also the ASP tags themseves were higlighted in yellow.

      This was until the 7.7 release, that contains a bug that don’t highligh the content in light blue.

      This is not a big problem, but I just want to know why, if It’s a chose made by the developers, or if It’s just an annoying bug.

      1 Reply Last reply Reply Quote 0
      • D
        DirtyEcho @SalviaSage
        last edited by DirtyEcho May 26, 2019, 2:08 AM May 26, 2019, 2:08 AM

        @SalviaSage The file extension is ASP (You can find it in Notepad++: Language --> ASP).

        This is an example of an ASP Script:

        <%
        Session(“display”) = “Regitrazione”
        Session(“link”) = “register.asp”
        %>

        Just copy/paste into a Notepad++ ASP set page.

        E 1 Reply Last reply May 26, 2019, 12:34 PM Reply Quote 0
        • E
          Ekopalypse @DirtyEcho
          last edited by May 26, 2019, 12:34 PM

          @DirtyEcho

          I haven’t found any builtin theme which had set it to light blue but anyways, check if the color is set for your theme. To do so,
          goto Settings->Style Configurator->Language(choose ASP) and in Style choose ASPSYBOL. Now you can see and modify the color.

          D 1 Reply Last reply May 26, 2019, 3:07 PM Reply Quote 0
          • D
            DirtyEcho @Ekopalypse
            last edited by May 26, 2019, 3:07 PM

            @Ekopalypse

            Trying to explain me better i link this image: ASP Tags - Notepad++ 7.7 .

            The color “yellow” works good, If I change It into the “ASPSYBOL” section It’s displayed correctly; but the content inside the ASP tags should be highlighted in light blue (This image , took by using the previous version of Notepad++, explain me better for sure).

            Any ideas?

            E 1 Reply Last reply May 26, 2019, 4:06 PM Reply Quote 0
            • E
              Ekopalypse @DirtyEcho
              last edited by Ekopalypse May 26, 2019, 4:07 PM May 26, 2019, 4:06 PM

              @DirtyEcho

              asp is no longer the default language for html lexer and has been changed to JS.
              I guess this makes sense, doesn’t it?
              But this means that the attribute asp.default.language needs to be set to 2 if one chooses ASP lexer.
              You might open an issue here .

              If by any chance you are using a scripting language plugin you can set it your self by doing something like editor.setProperty('asp.default.language', 2)

              1 Reply Last reply Reply Quote 4
              • L
                Liga Tablas
                last edited by May 28, 2019, 3:03 PM

                I have same problem. I changed the Lenguaje to ActionScript in the Notepad ++ (in Lenguaje–>A–>ActionScript option menú) and this changed colours. I now this is not solution, but I can see my code in colours, is better than see all in white and black

                1 Reply Last reply Reply Quote 0
                • J
                  Jacqui King
                  last edited by May 28, 2019, 4:32 PM

                  I am having the same problem with ASP files. The reality is that there are still many sites running on classic ASP (whether it is fashionable or not). The colour coding worked until I upgraded to 7.7 today, and I have confirmed that it is still working on 7.5.9. Irrespective of the file extension (which is ASP in this case), I should be able to choose the language color-coding from the language menu. If I look at the Style Configurator, asp is still defined correctly, but it is only seeing the <%%> markers and nothing else. Something broke in the upgrade.

                  1 Reply Last reply Reply Quote 1
                  • C
                    Christian Guillod
                    last edited by Christian Guillod May 28, 2019, 5:25 PM May 28, 2019, 5:23 PM

                    I have the same problem and I have found that the colour coding still work if you have this line in the beginning of the file:

                    <%@LANGUAGE=“VBSCRIPT”%>

                    1 Reply Last reply Reply Quote 1
                    • D
                      donho
                      last edited by May 30, 2019, 1:26 AM

                      @dail has provided the fix here : https://github.com/notepad-plus-plus/notepad-plus-plus/pull/5708
                      The fix will be included in v7.7.1.

                      1 Reply Last reply Reply Quote 6
                      • S
                        Sriram N
                        last edited by May 30, 2019, 2:59 PM

                        Good to see that it’s getting fixed, this will help me. I had this problem too - it would recognize the <% %> code blocks, but would not highlight the language within them (VBScript) correctly unless if the <%@LANGUAGE=“VBSCRIPT”%> line was included.

                        1 Reply Last reply Reply Quote 0
                        • N
                          Nathaniel Courtens
                          last edited by Jun 5, 2019, 3:19 PM

                          is anyone using UDL http://docs.notepad-plus-plus.org/index.php/User_Defined_Languages as alternative (for now)? And would they mind sharing their .xml?

                          1 Reply Last reply Reply Quote 0
                          • P
                            patrickdrd
                            last edited by Jun 6, 2019, 9:35 PM

                            I don’t know if it’s been reported but I renamed a file and syntax highlighting was gone

                            1 Reply Last reply Reply Quote 0
                            • K
                              kkmuffme
                              last edited by Jun 9, 2019, 11:53 AM

                              Same exact problem in PHP. NP++ ver 7.6.2 works correctly
                              See: https://notepad-plus-plus.org/community/topic/17774/php-syntax-not-highliting-when-inside-other-language-string-ver-7-7

                              1 Reply Last reply Reply Quote 0
                              • N
                                niente0
                                last edited by Jun 13, 2019, 8:04 AM

                                Same here, my ASP scripts aren’t highlighted anymore since v7.7.
                                I can confirm it works with Notepad++ 7.6.6, I downgraded until bug is fixed.

                                1 Reply Last reply Reply Quote 0
                                12 out of 17
                                • First post
                                  12/17
                                  Last post
                                The Community of users of the Notepad++ text editor.
                                Powered by NodeBB | Contributors