|
11-19-2004, 10:26 AM | #1 |
Green Mole
Join Date: Nov 2004
Posts: 4
|
Bold Search Terms
Great search script!!!
How can I get the search terms that the user entered to appear as bold words in the search results? Right now, all of the text comes up normal so it is hard to determine how their search terms relate to the context of the results. Thanks Ben |
11-19-2004, 05:48 PM | #2 |
Purple Mole
Join Date: Jan 2004
Posts: 694
|
In config.php, find the following code:
Code:
define('HIGHLIGHT_BACKGROUND','#FFBB00'); //Highlighting background color //Only for classic mode define('HIGHLIGHT_COLOR','#000000'); //Highlighting text color //Only for classic mode |
11-20-2004, 09:06 AM | #3 |
Green Mole
Join Date: Nov 2004
Posts: 4
|
hmmm... doesn't seem to be working.. or maybe I'm not using classic mode... what is classic mode?
Thanks Ben |
11-20-2004, 09:47 AM | #4 |
Purple Mole
Join Date: Jan 2004
Posts: 694
|
First of all, read section 10 of the phpdig documentation. (You should read all of the documentation anyway. RTFM* applies here ). Classic mode is all the premade templates that you can view in the phpdig demo.
* Someone is bound to ask. RTFM = read the manual. There are variations on the "F" - some of which are vulgar. No need to elaborate on that. |
11-20-2004, 12:35 PM | #5 |
Green Mole
Join Date: Nov 2004
Posts: 4
|
RTFM.. I like that. Sorry I didn't read it thoroughly... thanks for your reply though!!
So, for my situation, I can't use the Classic mode, I need to be able to modify the display. Got any hacks up your sleeve to get the text highlighting capabilities to work with a template? Thanks in advance. Ben |
11-20-2004, 01:28 PM | #6 |
Purple Mole
Join Date: Jan 2004
Posts: 694
|
That is governed by the stylesheet for your search page. For example, here is how it's defined in the template bluegrey.html:
Code:
.phpdigHighlight { color: white; background-color: #220044; font-weight: bold; } Hope this helps. |
11-21-2004, 09:09 AM | #7 |
Green Mole
Join Date: Nov 2004
Posts: 4
|
beautiful.. I see the phpdigHighlight span class in the results. Thanks!!!
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
No most searched terms, biggest results, most 0 results, last search queries, etc. | jongag1 | How-to Forum | 6 | 04-22-2005 11:43 AM |