Opened 12 years ago

Last modified 8 years ago

#9503 closed defect

Doesn't catch all matches of pagename. — at Initial Version

Reported by: anonymous Owned by: Trap
Priority: normal Component: BackLinksMacro
Severity: normal Keywords:
Cc: Trac Release: 0.12

Description

I had to set up the sql like this to match more variations of the reference in web pages. The most common was page name at the end of a sentence like: Details at SandBox.

        if thispage:
              sql += 'AND (w1.text LIKE \'%%[wiki:%s %%\'' % thispage
              sql += ' OR w1.text LIKE \'%%[wiki:%s]%%\'' % thispage
              sql += ' OR w1.text LIKE \'%%[%s %%\'' % thispage        #New
              sql += ' OR w1.text LIKE \'%%[%s]%%\'' % thispage        #New
              if self._check_unicode_camelcase(thispage):   
                      sql += ' OR w1.text LIKE \'%%\n%s %%\'' % thispage 
                      sql += ' OR w1.text LIKE \'%% %s %%\'' % thispage 
                      sql += ' OR w1.text LIKE \'%%\n%s\r%%\'' % thispage 
                      sql += ' OR w1.text LIKE \'%% %s\r%%\'' % thispage 
                      sql += ' OR w1.text LIKE \'%% %s.%%\'' % thispage        #New 
              sql += ')' 

Change History (0)

Note: See TracTickets for help on using tickets.