Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: MOD Implementation
 Can't Use Apostrophe In Search
 New Topic  Topic Locked
 Printer Friendly
Previous Page | Next Page
Author Previous Topic Topic Next Topic
Page: of 3

Andy Humm
Average Member

United Kingdom
908 Posts

Posted - 17 May 2008 :  17:21:57  Show Profile
Since adding the amended code to inc_searchlog.asp,(no errors now) the search_mod.asp will not extract can't ie no results.
I have just tried the previous search.asp (since the amended code has been added to inc_searchlog.asp) and the search.asp extracts the word can't okay. ???

However, if I go back to an unamended inc_searchlog.asp the search.asp errors with the same error as we had with search_mod.asp:
Microsoft OLE DB Provider for ODBC Drivers error '80040e14'

[Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'SLK_KEYWORD='can't''.
C:\xxxxxxxxx/forum/inc_searchlog.asp, line 57


From this phy1729's code seems to work for search.asp but not search_mod.asp

Leatherlips could you confirm the same symptoms..


<
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 17 May 2008 :  18:20:33  Show Profile
leatherlips use Response.Write strsql
my_conn.Execute (strsql),,adCmdText + adExecuteNoRecords<
Go to Top of Page

leatherlips
Senior Member

USA
1838 Posts

Posted - 17 May 2008 :  18:46:57  Show Profile  Visit leatherlips's Homepage
OK. I did it correctly this time thanks to your help.

Here is the message it gives when I search for can't:

UPDATE FORUM_SEARCHLOG_KEYWORDS SET SLK_COUNT=SLK_COUNT+1 WHERE SLK_ID=28UPDATE FORUM_SEARCHLOG_QUERIES SET SLQ_COUNT=SLQ_COUNT+1 WHERE SLQ_ID=12<

Mangione Magic Forum - The Music of Chuck Mangione

My Mods: Googiespell MOD | Link To Reply MOD | Petition MOD | Contact Page MOD | Share This Topic MOD | MP3 MOD | PageEar MOD | Google Viewer MOD
Go to Top of Page

leatherlips
Senior Member

USA
1838 Posts

Posted - 19 May 2008 :  15:19:24  Show Profile  Visit leatherlips's Homepage
I now have search able to properly look for "can't". I had to make some changes to my search_mod.asp page. Now I have one more little issue.

I have the search terms mod added to the search.asp page. If you click the "quick look" icon it will not allow the pop up to appear if your search had an apostrophe in it. Here is the code that was added to search.asp:

Response.Write " <a href=""JavaScript:openWindow5('pop_printer_friendly.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & SearchLink & "')"">" & getCurrentIcon(strIconPrint,"","align=""absmiddle""") & "</a>"

Any issues you see with it?

You can test it out on my page here. First search for can and you will see that everything works. Then search for can't and notice it all works except for the "quick look". In IE you'll see that it says there is an error on the page. However, the error doesn't make any sense to me.<

Mangione Magic Forum - The Music of Chuck Mangione

My Mods: Googiespell MOD | Link To Reply MOD | Petition MOD | Contact Page MOD | Share This Topic MOD | MP3 MOD | PageEar MOD | Google Viewer MOD
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 19 May 2008 :  15:31:26  Show Profile
The ' needs to be escaped again. I think you want

Response.Write " <a href=""JavaScript:openWindow5('pop_printer_friendly.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & ChkString(SearchLink,"display") & "')"">" & getCurrentIcon(strIconPrint,"","align=""absmiddle""") & "</a>"
<
Go to Top of Page

leatherlips
Senior Member

USA
1838 Posts

Posted - 19 May 2008 :  15:39:57  Show Profile  Visit leatherlips's Homepage
I tried your fix and I get the same error for "can't". Any other ideas?<

Mangione Magic Forum - The Music of Chuck Mangione

My Mods: Googiespell MOD | Link To Reply MOD | Petition MOD | Contact Page MOD | Share This Topic MOD | MP3 MOD | PageEar MOD | Google Viewer MOD
Go to Top of Page

leatherlips
Senior Member

USA
1838 Posts

Posted - 19 May 2008 :  15:53:33  Show Profile  Visit leatherlips's Homepage
Maybe the issue is really with the pop up page? Here is a section of code I had to add for the mod. Would it need to be changed?:

strSql = "UPDATE FORUM_TOPICS "
strSql = strSql & " SET T_VIEW_COUNT = (T_VIEW_COUNT + 1) "
strSql = strSql & " WHERE (TOPIC_ID = " & Topic_ID & ")"

my_conn.Execute (strSql),,adCmdText + adExecuteNoRecords

if Request("SearchTerms") <> "" then
   SearchLink = "&SearchTerms=" & Request("SearchTerms")
else
   SearchLink = ""
end if
<

Mangione Magic Forum - The Music of Chuck Mangione

My Mods: Googiespell MOD | Link To Reply MOD | Petition MOD | Contact Page MOD | Share This Topic MOD | MP3 MOD | PageEar MOD | Google Viewer MOD
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 19 May 2008 :  22:41:29  Show Profile
Did you apply the above code change to the test page?

That code should be:

SearchLink = "&SearchTerms=" & ChkString(Request("SearchTerms"),"display")
<
Go to Top of Page

Andy Humm
Average Member

United Kingdom
908 Posts

Posted - 20 May 2008 :  02:44:02  Show Profile
phy1729, thank you for you valuable input, like leatherlips I am duplicating his symptoms and receive the same errors. The search_mod.asp works brilliantly for all searches, the pop_printer_friendly.asp displays all terms expect the dreaded ' in can't
This is what I have done:
1. Open search_mod.asp
2. Enter can't into keywords
3. All of these keywords (x and y) - radio box ticked
4. Search
5. /forum/search_mod.asp?mode=DoIt provides results
6. Click on Topic Link
7. /forum/topic.asp?TOPIC_ID=678&SearchTerms=can't displays with highlighted can't in topic message
8. return to results page
9. Hover over quicklook icon next to topic link
10. javascript:openWindow5('pop_printer_friendly.asp?TOPIC_ID678&SearchTerms=can't) is displayed in bottom of browser window
11. Click on icon
12. Error on page appears and the pop up window does not open
13. The following is given as the error:
Line: 1
Char: 68
Error: Expected ')'
Code: 0
URL: http://lynehamvillage.com/forum/search_mod.asp?mode=DoIt

I have tried the same routine on leatherlips forum and the symptoms here are identical.
Scratch head!!!

Here is my pop_printer_friendly.asp
<

Edited by - Andy Humm on 20 May 2008 02:46:55
Go to Top of Page

Andy Humm
Average Member

United Kingdom
908 Posts

Posted - 20 May 2008 :  02:53:58  Show Profile
I have also noticed, following the same steps above upto and including step 7
with the topic results displayed, click on the Printer Friendly link and the same symptoms and errors occur at step 12-13 indicating a common problem with pop_printer_friendly.asp or is it?<

Edited by - Andy Humm on 20 May 2008 02:54:19
Go to Top of Page

leatherlips
Senior Member

USA
1838 Posts

Posted - 20 May 2008 :  06:25:19  Show Profile  Visit leatherlips's Homepage
quote:
Originally posted by phy1729

Did you apply the above code change to the test page?

If by test page you meant the pop up page, then yes, I tried that too. It seems to have no effect with or without the code change.<

Mangione Magic Forum - The Music of Chuck Mangione

My Mods: Googiespell MOD | Link To Reply MOD | Petition MOD | Contact Page MOD | Share This Topic MOD | MP3 MOD | PageEar MOD | Google Viewer MOD

Edited by - leatherlips on 20 May 2008 06:25:28
Go to Top of Page

phy1729
Average Member

USA
589 Posts

Posted - 20 May 2008 :  06:38:30  Show Profile
Test page meaning http://mangionemagic.com/forum/searchforum.asp<
Go to Top of Page

Carefree
Advanced Member

Philippines
4222 Posts

Posted - 20 May 2008 :  07:49:46  Show Profile
If you choose exact phrase, it'll display "can't".<
Go to Top of Page

Carefree
Advanced Member

Philippines
4222 Posts

Posted - 20 May 2008 :  08:27:01  Show Profile
I fixed the search_mod.asp - I incorporated the poll mod into it, but can strip that out for those who don't use it.

With poll mod: http://98.25.191.199/search_mod.txt
Without polls: http://98.25.191.199/search_mod_no_poll.txt<

Edited by - Carefree on 30 May 2008 21:29:52
Go to Top of Page

Andy Humm
Average Member

United Kingdom
908 Posts

Posted - 20 May 2008 :  08:29:15  Show Profile
Carefree if phy1729's suggested code is added to search_mod.asp line 400 and search.asp line 210 then it will display can't in the pop_printer_friendly.asp and topic.asp irrespective of 'Exact phrase' setting, I used 'All of these keywords (x and y)' and it worked.

Leatherlips I have just edited search_mod.asp (yours searchforum.asp) line 400 and search.asp line 210 both:
Find
SearchLink = "&SearchTerms=" & chkString(strKeyWords,"search")
Replace with:
SearchLink = "&SearchTerms=" & ChkString(Request("SearchTerms"),"display")
However, the pop up works, but I'm just looking into why the searched word is now not highlighted including can't. If you revert the new code back to SearchLink = "&SearchTerms=" & chkString(strKeyWords,"search") then the searched word is highlighted but no popup for can't only????????

STRSEARCHHILITECOLOR???????????<

Edited by - Andy Humm on 20 May 2008 08:33:40
Go to Top of Page
Page: of 3 Previous Topic Topic Next Topic  
Previous Page | Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.76 seconds. Powered By: Snitz Forums 2000 Version 3.4.07