Jump to content

[SOLVED] character problem in new server


AmirMahmood

Recommended Posts

hi guys

first sorry for my bad English.

i moved my site to a new host. in my new host, characters seems too don't processed correctly. 

for example look at uploaded image. title beside of product image has incorrect characters.

and other example, some times when i add tags in Persian characters and press save button , it gives me this error: "Property Tag -> name is not valid"

i didn't have this problem in my previous host.

Capture.jpg

Edited by AmirMahmood
SOLVED (see edit history)
Link to comment
Share on other sites

2 hours ago, selectshop.at said:

You changed it for now, or it was before utf8_general_ci ?

Products description added manually or by csv import ?

it was utf8_general_ci.

all things added manually. i don't use csv.

does php have a way for specifying the encoding of php files ?

for example in python we add 

# -*- coding: utf-8 -*-

is there a way for defining Php Source Codes Encodings?  and can Source Codes Encoding causes this problem ??

Link to comment
Share on other sites

i find some thing.

for example my product name is "سشوار و حالت دهنده چرخشی 1000 وات پرنسلی+کیف نگه دارنده مدل PR306"

when i use below code, it just show "..." for name insted of "سشوار و حالت دهنده چرخشی 1000 وات پرنسلی+کیف ..."

{$product.name|truncate:70:'...'|escape:'html':'UTF-8'}

but when i  use below code

{$product.name|escape:'html':'UTF-8'}

it show "سشوار و حالت دهنده چرخشی 1000 وات پرنسلی+کیف نگه دارنده مدل PR306" in my site.

it seems characters that inject in tpl files have different encoding and tpl can't modify strings correctly, but when tpl files leave strings wthout any modification, string show correctly in my site. i think tpl didn't get strings in utf8.

any idea ?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...