How to highlight the keyword in search result?

Discussion in 'PHP' started by hoangthienphuc, Aug 13, 2007.

  1. hoangthienphuc

    hoangthienphuc New Member

    Joined:
    Mar 15, 2007
    Messages:
    17
    Likes Received:
    0
    Trophy Points:
    0
    I want when i type the keyword and click search button, in result will contain the keyword highlighted that i typed. How can i do that?
     
  2. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,375
    Likes Received:
    388
    Trophy Points:
    83
    Do you mean to say your own search engine results I guess. If that is the case then, you render the HTML you replace the "search word" with "<strong>search word</strong>"
     
  3. hoangthienphuc

    hoangthienphuc New Member

    Joined:
    Mar 15, 2007
    Messages:
    17
    Likes Received:
    0
    Trophy Points:
    0
    Yes! That's i mean but can you tell me more detail? Thanks a lots. :confused:
     
  4. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,375
    Likes Received:
    388
    Trophy Points:
    83
    What other details you need? I mean its just a regular function call where you replace a word with some other word.
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice