Documentation Source Text

Check-in [bfc81cf6e4]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Filter out <script> tags when building the search database.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: bfc81cf6e40eeb990097f1b4fca4edf09360cb15
User & Date: dan 2010-01-08 17:57:37.000
Context
2010-01-08
18:17
Corrections to substr() documentation text. Updates to the makefile. (check-in: bdfb8d83ff user: drh tags: trunk)
17:57
Filter out <script> tags when building the search database. (check-in: bfc81cf6e4 user: dan tags: trunk)
16:29
Make sure search works even if the q= parameter is omitted. Suppress the s=Go parameter on queries. (check-in: 817a320509 user: drh tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to search/parsehtml.c.
172
173
174
175
176
177
178
179
180
181


182
183
184
185
186
187
188
      while( ISSPACE(*z) ) z++;
      zTag = z;

      while( *z && !ISSPACE(*z) && *z!='>' ) z++;
      nTag = z-zTag;

      if( nTag==5 && 0==strncasecmp("style", zTag, 5) ){
        while( *z && strncasecmp("/style>", z, 6 ) ) z++;
      } else if( nTag>=3 && 0==memcmp("!--", zTag, 3) ){
        while( *z && strncasecmp("-->", z, 3 ) ) z++;


      } else {
        Tcl_Obj *pParam = Tcl_NewObj();

        while( *z && *z!='>' ){
          char *zAttr;

          /* Gobble up white-space */







|


>
>







172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
      while( ISSPACE(*z) ) z++;
      zTag = z;

      while( *z && !ISSPACE(*z) && *z!='>' ) z++;
      nTag = z-zTag;

      if( nTag==5 && 0==strncasecmp("style", zTag, 5) ){
        while( *z && strncasecmp("/style>", z, 7 ) ) z++;
      } else if( nTag>=3 && 0==memcmp("!--", zTag, 3) ){
        while( *z && strncasecmp("-->", z, 3 ) ) z++;
      } else if( nTag>=3 && 0==memcmp("script", zTag, 6) ){
        while( *z && strncasecmp("/script>", z, 8 ) ) z++;
      } else {
        Tcl_Obj *pParam = Tcl_NewObj();

        while( *z && *z!='>' ){
          char *zAttr;

          /* Gobble up white-space */