The problem of mismatch encodings

Helpdesk for my helpdesk software

Moderator: mkoch227

Post Reply
dock1970
Posts: 5
Joined: Wed Apr 13, 2011 9:23 am

The problem of mismatch encodings

Post by dock1970 »

Script URL: http://testsite.ab.biz.ua/online_support/
Version of script: 2.2
Hosting company: freehost.com.ua
URL of phpinfo.php: http://testsite.ab.biz.ua/online_suppor ... hpinfo.php
URL of session_test.php: http://testsite.ab.biz.ua/online_suppor ... n_test.php
What terms did you try when SEARCHING for a solution: utf-8, encoding, mysql

Write your message below:
My database is in UTF-8 format. Article entered in Russian and in the database there are such characters "P" RјReS, SЂReR number RљRѕR · R "RѕRІ. Respectively to search for matches in the knowledge base in Russian does not give any results. Language file in UTF-8 format. Need your advice.

In English, everything works fine, try to find a word - windows
Klemen
Site Admin
Posts: 10145
Joined: Fri Feb 11, 2005 4:04 pm

Re: The problem of mismatch encodings

Post by Klemen »

It seems to be a problem with Javascript code because if you click the search button you do get results, right?

Try this if it helps:

1. open hesk_javascript.js in Notepad
2. change all instances of

Code: Select all

escape(
with

Code: Select all

encodeURIComponent(
3. upload the modified file to the server
4. clear your browser cache (temporary internet files), refresh the help desk and see if it works
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
dock1970
Posts: 5
Joined: Wed Apr 13, 2011 9:23 am

Re: The problem of mismatch encodings

Post by dock1970 »

Helped in part, the search began to work better, but not all of the words it finds.
But the problem of entering data into the database properly encoded.
I can not manage (phpMyAdmin) the database without understanding what is written there.
Here are some screen shots:
Tables
Image
Data posted by HESK forms
Image
Image
Image
Data posted by me in phpMyAdnin
Image
Image
dock1970
Posts: 5
Joined: Wed Apr 13, 2011 9:23 am

Re: The problem of mismatch encodings

Post by dock1970 »

Change the encoding to windows-1251 all appear fine. In the database all is fine. Search finds articles from the knowledge base, if click the search button.
Quick Search. Try to find "windows"and "support" - finds the words. But can not find words in Russian using a quick search. Copy any word from the article and try to find using a quick search.

New link http://testsite.ab.biz.ua/test

I'm confused and very disappointed.
The script is excellent.
I can help test all if you say what to do next.

p.s. The original and modified hesk_javascript.js work the same with windows-1251.
dock1970
Posts: 5
Joined: Wed Apr 13, 2011 9:23 am

Re: The problem of mismatch encodings

Post by dock1970 »

So, any ideas? Waiting for solution
Klemen
Site Admin
Posts: 10145
Joined: Fri Feb 11, 2005 4:04 pm

Re: The problem of mismatch encodings

Post by Klemen »

It must be some inconsistency with charsets - either on the browser or DB (phpmyadmin) part.

Note that when you're making changes to the charset - for example when you change it to URF-8, only NEW articles you add will be saved as UTF-8, not the old ones.

I'm afraid I don't have the time to test this at the moment, try playing a bit with charsets to see if you can get it to work. I will try in on my end next week when I have a break from my job.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
dock1970
Posts: 5
Joined: Wed Apr 13, 2011 9:23 am

Re: The problem of mismatch encodings

Post by dock1970 »

Ok, thanx.
Post Reply