Search engine on single page

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Sam Smarty

    Search engine on single page

    I got a singe page where is a lot of text. Visitors usually looks a
    one special text from that page, but it's so large-sized that they
    will be frustrated. So, I need a javascript code which includes search
    field where visitor can specify that single or multiple word that one
    is looking for from the page. And when visitor press a search button,
    javascript will highlight the correct word(s) from that page... Did
    you understand? I know that somewhere on the internet is the code i'm
    looking for, but i cannot find it. Thanks!

    Sam
  • Ivo

    #2
    Re: Search engine on single page

    "Sam Smarty" wrote[color=blue]
    > I got a singe page where is a lot of text. Visitors usually looks a
    > one special text from that page, but it's so large-sized that they
    > will be frustrated. So, I need a javascript code which includes search
    > field where visitor can specify that single or multiple word that one
    > is looking for from the page. And when visitor press a search button,
    > javascript will highlight the correct word(s) from that page... Did
    > you understand? I know that somewhere on the internet is the code i'm
    > looking for, but i cannot find it. Thanks!
    >
    > Sam[/color]

    Do you mean something like
    <URL: http://4umi.com/code/highlighttext.htm >
    The search is for all entered words individually by default but optionally
    for the exact phrase. Case-sensitivity is another option.
    Ivo


    Comment

    • denisb

      #3
      Re: Search engine on single page

      Ivo <no@thank.you > wrote:[color=blue]
      > Do you mean something like
      > <URL: http://4umi.com/code/highlighttext.htm >
      > The search is for all entered words individually by default but optionally
      > for the exact phrase. Case-sensitivity is another option.[/color]

      nice !
      but ...
      be care...
      if i find ' ' (blank space only) or ' o' (blank space first then o) ...

      boum !

      --
      @@@@@
      E -00 comme on est very beaux dis !
      ' `) /
      |\_ =="

      Comment

      • David Dorward

        #4
        Re: Search engine on single page

        Sam Smarty wrote:
        [color=blue]
        > I got a singe page where is a lot of text. Visitors usually looks a
        > one special text from that page, but it's so large-sized that they
        > will be frustrated.[/color]

        Edit > Find in many browsers.

        Mozilla has the funky Find-As-You-Type feature which can be activated for
        non-link text by typing '/'.

        (I have a thing about needlessly duplicating built in browser functionality
        with JavaScript)

        --
        David Dorward <http://blog.dorward.me .uk/> <http://dorward.me.uk/>

        Comment

        • Sam Smarty

          #5
          Re: Search engine on single page

          That code seemed nice, but is there any other solutions available?

          Sam

          Comment

          Working...