The Forum has been Updated
The code has been upgraded to the latest .NET core version. Please check instructions in the Community Announcements about migrating your account.
I searched Snitz and couldn't find a topic on this: I was wondering if it's possible to type a search string directly in my browser's address field to search the forums without using the forum's search form? For example, typing this directly in the browser's address bar:
http://www.website.com/forum/search.asp?forum_ID=4&SearchTerms=word1,word2<
http://www.website.com/forum/search.asp?forum_ID=4&SearchTerms=word1,word2<
Postet den
i dont think you add search terms..if i remember correctly its to stop a security flaw..correct me if im wrong that may have been for somthing else but im sure they made it this way so that a user cannot exploit anything that may occur via dodgy search terms.<
© 1999-2010 MaD2ko0l
Postet den
it has always been a POST form rather than a GET, I don't know why it was done the way it was, it has allways been that way.<
Postet den
Thanks for the answers.
<
<
Postet den
You can in Google.
For example, in Google's search field type:
Google will only search for that term within the URL you specified.
So if I wanted to search for the word concert in my forum I would type:
concert site:www.mangionemagic.com/forum
Here is what the results would show up as in Google.
<
For example, in Google's search field type:
Code:
your search terms here site:www.yoursite.com/forumSo if I wanted to search for the word concert in my forum I would type:
concert site:www.mangionemagic.com/forum
Here is what the results would show up as in Google.
<
Sist redigert av
Postet den
Find the line in search.asp that has:
if Request.QueryString("mode") = "DoIt" then
Above that add this:
Change:
if Request.QueryString("mode") = "DoIt" then
To:
if Request.QueryString("mode") = "DoIt" or ThisSearch <> "" then
And, change all instances of:
Request.Form("Search")
To:
ThisSearch
Try your search for one word as:
http://www.mydomain.com/search.asp?search=word1
Try your search for two words as:
http://www.mydomain.com/search.asp?search=word1+word2
Most of all ... have fun!
<
if Request.QueryString("mode") = "DoIt" then
Above that add this:
Code:
if trim(Request.Form("Search")) <> "" then
ThisSearch = Request.Form("Search")
elseif trim(Request.QueryString("Search")) <> "" then
ThisSearch = Request.QueryString("Search")
end ifChange:
if Request.QueryString("mode") = "DoIt" then
To:
if Request.QueryString("mode") = "DoIt" or ThisSearch <> "" then
And, change all instances of:
Request.Form("Search")
To:
ThisSearch
Try your search for one word as:
http://www.mydomain.com/search.asp?search=word1
Try your search for two words as:
http://www.mydomain.com/search.asp?search=word1+word2
Most of all ... have fun!
Postet den
Try your search for two words as:it would work, but would not actually do what Lon2 asked which was to search a particular forum
http://www.mydomain.com/search.asp?search=word1+word2
Most of all ... have fun!
Postet den
In addition to what I wrote above ...
Below the following:
Add this:
And, change all instances of:
Request.Form("Forum")
To:
ThisForum
Try your search for one word as:
http://www.mydomain.com/search.asp?search=word1&forum=1
Try your search for two words as:
http://www.mydomain.com/search.asp?search=word1+word2&forum=1
if the forum id you are querying does not produce results, then try the next forum id.
Above of all ... have much more fun than you were having before!
<
Below the following:
Code:
if trim(Request.Form("Search")) <> "" then
ThisSearch = Request.Form("Search")
elseif trim(Request.QueryString("Search")) <> "" then
ThisSearch = Request.QueryString("Search")
end ifAdd this:
Code:
if trim(Request.Form("Forum")) <> "" then
ThisForum = Request.Form("Forum")
elseif trim(Request.QueryString("Forum")) <> "" then
ThisForum = Request.QueryString("Forum")
end ifAnd, change all instances of:
Request.Form("Forum")
To:
ThisForum
Try your search for one word as:
http://www.mydomain.com/search.asp?search=word1&forum=1
Try your search for two words as:
http://www.mydomain.com/search.asp?search=word1+word2&forum=1
if the forum id you are querying does not produce results, then try the next forum id.
Above of all ... have much more fun than you were having before!
Sist redigert av
Postet den
Hey Huw,
If you think this qualifies as a MOD, then after Lon2 gets to have a look at it, would you mind moving the topic over to the MOD Add-on Forum w/Code for others to enjoy as well?
Cheers,
Etymon<
If you think this qualifies as a MOD, then after Lon2 gets to have a look at it, would you mind moving the topic over to the MOD Add-on Forum w/Code for others to enjoy as well?
Cheers,
Etymon<
Postet den
The ideal thing would be to store the search terms in a string variable (e.g. searchterms) and replace all the Request.Form instances with that variable.
<
<
Podge.
The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)
My Mods: CAPTCHA Mod | GateKeeper Mod Tutorial: Enable subscriptions on your board
Warning: The post above or below may contain nuts.
My Mods: CAPTCHA Mod | GateKeeper Mod Tutorial: Enable subscriptions on your board
Warning: The post above or below may contain nuts.
Postet den
Isn't that what I did here:
<
Code:
if trim(Request.Form("Search")) <> "" then
ThisSearch = Request.Form("Search")
elseif trim(Request.QueryString("Search")) <> "" then
ThisSearch = Request.QueryString("Search")
end ifEmail Member
Message Member
Post Moderation
Filopplasting
If you're having problems uploading, try choosing a smaller image.
Forhåndsvis post
Send Topic
Loading...