Take the 2-minute tour ×
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

I want to fix this issue:

this is a select list

this is a list of my wordpress category but it language is Persian and show like this!

I've convert all php files into UTF8 encoding but didn't work.

how can fix?

share|improve this question
add comment

1 Answer

ha ha :) I've find solution.

Just decode the URL format with this function: urlencode ( string )

but my issue is not string it is array with changing count.

I fixed with this code:

$count=count($blog_categories);
for ($x=0;$x<$count;$x++){
$blog_categories[$x] = urldecode($blog_categories[$x]);}

comment: $blog_categories is my array. this array returns category in wordpress.

and result:

enter image description here

I hope My experience can help you someday!

good luck :)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.