Search Term Highlighting - Perl Script
5005
£150(approx. $187)
- Posted:
- Proposals: 1
- Remote
- #29736
- Archived
Description
Experience Level: Expert
Requirements:
we have an existing Perl script:
# Author: Pieter Wessels
# Purpose:
# This script will find a given set of term/s in an HTML document.
# Those occurances in the HEAD section of the document and all occurances
# within an HTML tag will be ignore (effectively this should result in only
# text visible in the browser being found). The terms found will be
# surround with a start and end tag which can be customised.
# A customisable inclusion will be made at the top and bottom of the BODY section
# which will effecively provide the user with a hyperlink to each term found.
# Parameters:
# Filename - path/name of the file which will be tagged. Note this is relative
# to the base directory set as a constant in this script. If however
# SiteURL is found in the filename it will be substituted with the
# Base Directory.
# Terms - the terms which will be sought.
This script has been modified:
a) it includes bits of HTML that would have been included through a Server-side include routine
b) it searches for and highlights terms between a single set of <!-- Searchable --> & <!-- /Searchable --> tags.
Functionality needs to be extended further - specifically the file might contain several <!-- Searchable --> & <!-- /Searchable --> tags that may or may not be nested.
The original scripts were written and adapted by a novice (me) and are well documented. I would expect that any solution presented be equally well documented.
we have an existing Perl script:
# Author: Pieter Wessels
# Purpose:
# This script will find a given set of term/s in an HTML document.
# Those occurances in the HEAD section of the document and all occurances
# within an HTML tag will be ignore (effectively this should result in only
# text visible in the browser being found). The terms found will be
# surround with a start and end tag which can be customised.
# A customisable inclusion will be made at the top and bottom of the BODY section
# which will effecively provide the user with a hyperlink to each term found.
# Parameters:
# Filename - path/name of the file which will be tagged. Note this is relative
# to the base directory set as a constant in this script. If however
# SiteURL is found in the filename it will be substituted with the
# Base Directory.
# Terms - the terms which will be sought.
This script has been modified:
a) it includes bits of HTML that would have been included through a Server-side include routine
b) it searches for and highlights terms between a single set of <!-- Searchable --> & <!-- /Searchable --> tags.
Functionality needs to be extended further - specifically the file might contain several <!-- Searchable --> & <!-- /Searchable --> tags that may or may not be nested.
The original scripts were written and adapted by a novice (me) and are well documented. I would expect that any solution presented be equally well documented.
Pieter W.
0% (0)Projects Completed
1
Freelancers worked with
1
Projects awarded
100%
Last project
26 Jul 2010
United Kingdom
New Proposal
Login to your account and send a proposal now to get this project.
Log inClarification Board Ask a Question
-
There are no clarification messages.
We collect cookies to enable the proper functioning and security of our website, and to enhance your experience. By clicking on 'Accept All Cookies', you consent to the use of these cookies. You can change your 'Cookies Settings' at any time. For more information, please read ourCookie Policy
Cookie Settings
Accept All Cookies