| www.simball.de | Links mods | Search Only Mod | 

Gossamer-Threads - Links 2.0 mod

Search Only Mod - for templates

This modification allows you to search a specific database field from the 'search-options-page'.

See it in action: here in the search options. Instructions in a text file: follow this.


Step 1:

File: search.cgi

In search.cgi in sub search find:

code:


# Check to see if the link matches.   
and add the following above it:

code:


# Search Only Mod

$searchonly = $in{'searchonly'};

if ($searchonly eq "all") {
@search_fields = (1,2,5);
}
if ($searchonly eq "title") {
@search_fields = (1);
}
if ($searchonly eq "description") {
@search_fields = (5);
}
if ($searchonly eq "url") {
@search_fields = (2);
}

Step 2:

File: search.html

Modify the template file. In search.html find:

code:


OR connector: <input type="RADIO" name="bool" value="or">
and add the following behind:

code:


Search in:
All: <input type="RADIO" name="searchonly" value="all" checked>
Title: <input type="RADIO" name="searchonly" value="title">
Description: <input type="RADIO" name="searchonly" value="description">
URL: <input type="RADIO" name="searchonly" value="url"><p>

That's it. Enjoy it. For installation of modifications please visit the webservices.


AnzeigeJPC - der Spezialist für Musik

Problems with installing or questions, visit the Gossamer-Threads Support Forum.


| Top