Special characters on "link" col[] doesn't show data

QuestionsSpecial characters on "link" col[] doesn't show data
Oscar asked 11 years ago

Hi Abu,
I'm working with MSSQL and so far the grid works excellent when I show data with no col["link"] format, if I do and the text have special characters then doesn't show the text, like Name: "PÉREZ" or "ACUÑA"
I already try the tag <html lang="es"> and <meta UTF-8, Latin…> and no results.

I was trying col["link"] because I've been unable to get it run with "on_select" event, if I do then the entire document is blank, no errors… nothing

If I just comment the line where "set_events" is at then I have data

Would you please help me?

Thanks
Oscar

2 Answers
Oscar answered 11 years ago

Following this issue, I already run a REPLACE() function but doesn't work, let me show an example:

Patient name: "MORALES ACUÑA JUAN"

SELECT patient.oid, patient.completeName, REPLACE(patient.completeName, 'Ñ', 'N') as Nombre FROM Patient

Still shows the origina name "MORALES ACUÑA JUAN", only works in SQL Server

Thanks in advance
Oscar

Abu Ghufran answered 11 years ago

For link fix, change one line in jqgrid_dist.php in lib/inc.

Search this line:
$row[$col_name] = htmlentities($row[$col_name],ENT_QUOTES, "UTF-8");

Replace with:
$row[$col_name] = htmlentities(utf8_encode($row[$col_name]),ENT_QUOTES, "UTF-8");

We added utf8_encode function.

For set_events issue, i reviewed your code, and you should call $g object instead of $grid.

Your Answer

0 + 14 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate it.

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?