|
|
Posted 07/02/2005 14:27:04 |
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 13/06/2007 08:11:59
Posts: 4,
Visits: 3
|
|
When a user brings up a page as a result of a search, the search word or words are automatically highlighted. For the most part, this is a good thing. However, should that word (or words) be an actual part of a URL within the KB article, the URL itself is mangled with the highlighting code.
For example:
PC-ACE Pro32 Command Line Options
Code:
<A href="http://10.0.1.189/SDI/KnowledgeBase/AttachmentsProtected/PC-ACE%20Pro32%20<font style='background-color:#FFFC00;'>Command</font>%20<font style='background-color:#FFFC00;'>Line</font>%20Options.pdf">PC-ACE Pro32 <font style='background-color:#FFFC00;'>Command</font> <font style='background-color:#FFFC00;'>Line</font> Options</A>
Has anyone run across this before and is there anything that can be done about it?
|
|
|
|
Posted 07/02/2005 14:28:31 |
|
|
Support Supremo
      
Group: Customers
Last Login: 13/11/2008 12:44:07
Posts: 568,
Visits: 2,507
|
|
Which version of InstantKB are you using? This shouldn't occur in InstantKB 1.3. Please open a ticket in http://my.instantasp.co.uk to receive InstantKB 1.3 if you have a previous version. Thanks, Carlos Muniz
|
|
|
|
Posted 09/02/2005 13:59:59 |
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 13/06/2007 08:11:59
Posts: 4,
Visits: 3
|
|
I have version 1.3. Unless you have released an interim update, the problem still exists.
I have tracked it down in the source code. First, look in article.ascx.vb in Public Sub ArticleRepeater_ItemDataBound(). On lines 141-143 you'll notice the use of the function InstantASP.InstantKB.Utilities.Strings.Highlight() to highlight a word or phrase in the article text corresponding to the word or phrase found in the session variable "Query". Next, go to Utilities.vb and Public Shared Function Highlight(). You'll notice that the entire text of the article is split on various characters, including the <> characters. No allowance is made for not highlighting text within a tag. This is what leads to the problem. If you include an html link in your article to a file that has spaces within its name, or has a name that matches the search string, then that file name will be highlighted WITHIN the tag, as I demonstrated in the first post. In this particular case, it leads to a mangled and unuseable href value.
Test it yourself. Go over to the InstantKB.NET online demo. Go to the search tab and search on the word "article". Click the first item to come up, "Q10042 - HOWTO: Creating Knowledge Base Articles". When this article comes up, note the link in the third paragraph with the text "(create_new_article.gif)". If you try to follow the link it doesn't work. If you hover your mouse over the link and look at the address, you'll see why. Right in the middle of the address is the font tag around the word "article", rendering the href value unuseable.
|
|
|
|
Posted 11/02/2005 11:32:43 |
|
|
Forum Newbie
      
Group: Customers
Last Login: 04/04/2006 09:14:08
Posts: 8,
Visits: 4
|
|
I had the same problem, opened a problem ticket under My.InstantASP and and Ryan had to get a custom DLL rebuilt for the search function and sent to me to remove the highlighting to solve the issue. The ticket is still 'Under investigation' so I'm hoping that there will be an update in the next version, when ever that shows up. I'm also pondering if the patch that Ryan sent me is now interfering with category searches because now any time a category is selected instead of "All Categories", I get an error: Error Message: Thread was being aborted. Jeffrey Carlton Intranet Administrator Time Warner Cable Charlotte Division
|
|
|
|
Posted 11/08/2006 04:05:31 |
|
|
Forum Member
      
Group: Customers
Last Login: 27/09/2008 09:59:43
Posts: 47,
Visits: 248
|
|
| If there is in fact a fix for this - and the last post in this thread says there is - Could I have the fix please? Actually what I need is a code fix for the highlight utility, since I have changed some of the other subs in the utility code. I've fiddled with a regex myself to fix the highlighting, but with imperfect success. My support has expired, but according to the post dates, the fix was created before I bought the product. TIA.....
Charles
|
|
|
|
Posted 19/12/2006 05:14:39 |
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 13/08/2007 05:46:30
Posts: 12,
Visits: 154
|
|
| Can I also have a fix for this? We are using an external software package to convert documents to HTML, before inserting the HTML code into the WYSIWYG editor in the knowledge base. The software converts all images into .png format and uses the naming convention of imagename_1.png, imagename_2.png where the 'imagename' is the title of the saved file etc Before the code is finalised in the WYSIWYG editor, we do have to change the path of the images for them to apear in the knowledge base. If the 'imagename' of the image is included within the search, <font> tags are placed around the 'imagename', which breaks the img tags for the images. Thanks, Gemma
|
|
|
|
Posted 20/12/2006 07:51:46 |
|
|
Support Supremo
      
Group: Customers
Last Login: 13/11/2008 12:44:07
Posts: 568,
Visits: 2,507
|
|
gemmal (12/19/2006)
Can I also have a fix for this? We are using an external software package to convert documents to HTML, before inserting the HTML code into the WYSIWYG editor in the knowledge base. The software converts all images into .png format and uses the naming convention of imagename_1.png, imagename_2.png where the 'imagename' is the title of the saved file etc Before the code is finalised in the WYSIWYG editor, we do have to change the path of the images for them to apear in the knowledge base. If the 'imagename' of the image is included within the search, <font> tags are placed around the 'imagename', which breaks the img tags for the images. Thanks, Gemma Dear Gemma, Yes, we have a fix for some problems including this one, please open a ticket in our ticketing system (http://my.instantasp.co.uk) asking me for this fix.
|
|
|
|
Posted 15/01/2007 08:08:11 |
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 29/06/2007 05:31:47
Posts: 10,
Visits: 44
|
|
Carlos (12/20/2006)
gemmal (12/19/2006)
Can I also have a fix for this? We are using an external software package to convert documents to HTML, before inserting the HTML code into the WYSIWYG editor in the knowledge base. The software converts all images into .png format and uses the naming convention of imagename_1.png, imagename_2.png where the 'imagename' is the title of the saved file etc Before the code is finalised in the WYSIWYG editor, we do have to change the path of the images for them to apear in the knowledge base. If the 'imagename' of the image is included within the search, <font> tags are placed around the 'imagename', which breaks the img tags for the images. Thanks, Gemma Dear Gemma, Yes, we have a fix for some problems including this one, please open a ticket in our ticketing system (http://my.instantasp.co.uk) asking me for this fix. Hi Carlos, I have now taken over from Gemma on this project, and we intend to get around this issue by altering the file paths to ../attachments/ and using Guids as the filenames, would it still be worth asking fot the fix? Thanks Tom.
|
|
|
|
Posted 13/06/2007 04:12:32 |
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 29/06/2007 05:31:47
Posts: 10,
Visits: 44
|
|
| Would there be any chance of an update on this please? I would raise a ticket, but I don't have the relavant login details, as I took over this project midway through without a handover period. Many thanks. Tom
|
|
|
|
Posted 13/06/2007 07:51:13 |
|
|
Forum Newbie
      
Group: Forum Members
Last Login: 13/06/2007 08:11:59
Posts: 4,
Visits: 3
|
|
I do find it a bit disheartening to find I raised this question over two years ago and no one has implemented what should be an easy fix.
I can only tell you that I found a simple workaround, but it can only be done if you also bought the source code. Since the source is copyrighted I can't post my answer, but I can tell you to search for "Highlight" in article.ascx.vb and you'll see where the highlight occurs. I simply commented it out, so I do not get any article highlighting.
|
|
|
|