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.
Download Location: SnitzBitz
This is a modified standard Snitz search.asp. This MOD allows a member to search for keywords in his/her inbox, outbox, or inbox and outbox. It also lets the member search in the title or the entire PM.
Currently, this MOD is set up for searching only the private messages that the member has sent or received.
If you are an administrator and you want to search your members' mailboxes in addition to your own, contact me, and I'll work that into a future version as an option.
The .zip contains only one file: pm_search.asp. I can include instructions for installing it, an image icon, and also search terms highlighting in the next version. There are no database upgrades and no additional files. It uses the same files as search.asp. You'll have to make a link to it for now. Remember, this is just the first version.
My username at SnitzBitz is WhoHasItWhere. <
This is a modified standard Snitz search.asp. This MOD allows a member to search for keywords in his/her inbox, outbox, or inbox and outbox. It also lets the member search in the title or the entire PM.
Currently, this MOD is set up for searching only the private messages that the member has sent or received.
If you are an administrator and you want to search your members' mailboxes in addition to your own, contact me, and I'll work that into a future version as an option.
The .zip contains only one file: pm_search.asp. I can include instructions for installing it, an image icon, and also search terms highlighting in the next version. There are no database upgrades and no additional files. It uses the same files as search.asp. You'll have to make a link to it for now. Remember, this is just the first version.
My username at SnitzBitz is WhoHasItWhere. <
آخرین ویرایش توسط
نوشته شده در
See your EMail. I sent you a revision.<
نوشته شده در
Etymon, line 328 in the pm_search.asp may need updating, it put you back to search.asp.
Also I have noticed that if I search in the Inbox only, I will not come back with a returned result, but if I select the Outbox or the Inbox and Outbox from the drop down I get results back. Great work on it by the way.<
Also I have noticed that if I search in the Inbox only, I will not come back with a returned result, but if I select the Outbox or the Inbox and Outbox from the drop down I get results back. Great work on it by the way.<
Cheers,
David Greening
David Greening
نوشته شده در
Thanks guys for the help! I'll take a look at it as soon as I can.
<
نوشته شده در
to fix it:
lines 251 -258
changed to:
lines 503 - 511
changed to:
lines 628 - 630
changed to
I think that lines from 564 to 562 could be deleted
the same for lines from 516 to 528
the same for lines from 446 to 465
line 328 :
change search.asp to pm_search.asp<
lines 251 -258
Code:
if cLng(Request.Form("SearchPM")) = 0 then
strSql3 = strSql3 & " AND P.M_OUTBOX= " & cLng(Request.Form("SearchPM")) & " "
elseif cLng(Request.Form("SearchPM")) = 1 then
strSql3 = strSql3 & " AND P.M_OUTBOX= " & cLng(Request.Form("SearchPM")) & " "
elseif cLng(Request.Form("SearchPM")) = 2 then
strSql3 = strSql3 & " AND (P.M_OUTBOX = 1 "
strSql3 = strSql3 & " OR P.M_OUTBOX = 2) "
end if
changed to:
Code:
if cLng(Request.Form("SearchPM")) = 1 then
strSql3 = strSql3 & " AND P.M_OUTBOX= 0 AND (P.M_TO = " & MemberID & "))"
elseif cLng(Request.Form("SearchPM")) = 2 then
strSql3 = strSql3 & " AND P.M_OUTBOX= 1 AND (P.M_FROM = " & MemberID & "))"
elseif cLng(Request.Form("SearchPM")) = 3 then
strSql3 = strSql3 & " AND (P.M_OUTBOX = 0 "
strSql3 = strSql3 & " OR P.M_OUTBOX = 1) AND (P.M_FROM = " & MemberID & " OR P.M_TO = " & MemberID & ")) "
end if
lines 503 - 511
Code:
if OutBox_ID = "0" then
Response.Write "privatesent.asp"
elseif OutBox_ID = "1" then
Response.Write "privateread.asp"
elseif OutBox_ID = "2" and Topic_Author = MemberID then
Response.Write "privatesent.asp"
elseif OutBox_ID = "2" and Topic_Recipient = MemberID then
Response.Write "privateread.asp"
end if
changed to:
Code:
if OutBox_ID = 2 then
Response.Write "privatesent.asp"
elseif OutBox_ID = 1 then
Response.Write "privateread.asp"
elseif OutBox_ID = 2 and Topic_Author = MemberID then
Response.Write "privatesent.asp"
elseif OutBox_ID = 1 and Topic_Recipient = MemberID then
Response.Write "privateread.asp"
elseif OutBox_ID = 3 then
Response.Write "privateread.asp"
end if
lines 628 - 630
Code:
" <option value=""0"">Inbox</option>" & vbNewLine & _
" <option value=""1"">Outbox</option>" & vbNewLine & _
" <option value=""2"">Inbox and Outbox</option>" & vbNewLine
changed to
Code:
" <option value=""1"">Inbox</option>" & vbNewLine & _
" <option value=""2"">Outbox</option>" & vbNewLine & _
" <option value=""3"">Inbox and Outbox</option>" & vbNewLine
I think that lines from 564 to 562 could be deleted
the same for lines from 516 to 528
the same for lines from 446 to 465
line 328 :
change search.asp to pm_search.asp<
نوشته شده در
Change the following from this:
to this:
Note that if you send a message to yourself, this doesn't account for that.
modifichicci, I haven't tried your fix. The code above will show the messages in your inbox, outbox, and inbox/outbox. You may be fixing some other errors along the way that I haven't discovered.
Thanks for your help too!<
Code:
if cLng(Request.Form("SearchPM")) = 0 then
strSql3 = strSql3 & " AND P.M_OUTBOX= " & cLng(Request.Form("SearchPM")) & " "
elseif cLng(Request.Form("SearchPM")) = 1 then
strSql3 = strSql3 & " AND P.M_OUTBOX= " & cLng(Request.Form("SearchPM")) & " "
elseif cLng(Request.Form("SearchPM")) = 2 then
strSql3 = strSql3 & " AND (P.M_OUTBOX = 1 "
strSql3 = strSql3 & " OR P.M_OUTBOX = 2) "
end ifto this:
Code:
if cLng(Request.Form("SearchPM")) = 0 then
strSql3 = strSql3 & " AND (P.M_FROM <> " & MemberID & ")"
elseif cLng(Request.Form("SearchPM")) = 1 then
strSql3 = strSql3 & " AND (P.M_TO <> " & MemberID & ")"
end ifNote that if you send a message to yourself, this doesn't account for that.
modifichicci, I haven't tried your fix. The code above will show the messages in your inbox, outbox, and inbox/outbox. You may be fixing some other errors along the way that I haven't discovered.
آخرین ویرایش توسط
نوشته شده در
Etymon,
your fix worked nice and easy. Now getting results from the search. <
your fix worked nice and easy. Now getting results from the search. <
Cheers,
David Greening
David Greening
نوشته شده در
Originally posted by Classicmotorcycling
Etymon,
your fix worked nice and easy. Now getting results from the search.
Thanks David!
CareFree has packaged together a really nice installation guide with a pic for the search and some other fixes and tweaks of his own. When We get these errors all corrected, I'll upload the newest version of the MOD to SnitzBitz.
Thank again for all the help guys/gals! <
نوشته شده در
For anyone who is interested in testing the next unofficial version(s), contact me through my forum member profile e-mail here at Snitz (You have to login first
). We're throwing around some ideas via e-mail.<
نوشته شده در
That is true.. but it search only in outbox or only in inbox, i think it's missed the double option.. but I could be wrong..
you have to change also lines 503-511 to point to the correct link and lines 628-630 if you abort double check..
Edit: I haven't tryed your fix but are you sure that setting the query to P.M_FROM <> " & MemberID or P.M_TO <> " & MemberID you don't restrict the search to member PM but it takes on all PM?
Because the select command is bring on the PM table, with only a WHERE on subject or message and then you query on P.M_FROM that is NOT members bringing on the search or P.M_TO that is NOT the same members
<
Edit: I haven't tryed your fix but are you sure that setting the query to P.M_FROM <> " & MemberID or P.M_TO <> " & MemberID you don't restrict the search to member PM but it takes on all PM?
Because the select command is bring on the PM table, with only a WHERE on subject or message and then you query on P.M_FROM that is NOT members bringing on the search or P.M_TO that is NOT the same members
<
آخرین ویرایش توسط
نوشته شده در
The latest version (that I just mailed back to Etymon) searches in/out/both boxes and restricts members to their own PMs. Works just the way it should.<
Email Member
Message Member
Post Moderation
بارگزاری فایل
If you're having problems uploading, try choosing a smaller image.
پیشنمایش مطلب
Send Topic
Loading...