Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
The results are in! See what nearly 90,000 developers picked as their most loved, dreaded, and desired coding languages and more in the 2019 Developer Survey.

Questions tagged [encoding]

The tag has no usage guidance.

0
votes
0answers
16 views

encoding characters utf8

i have an array who contain french character ( à , é ex: [5] => 2 c à s d’huile d’olive) , when i print the array , it display whell this characters , but when i save them on the mysql database , i ...
0
votes
0answers
22 views

French accented text replaced with ? in woocommerce product list

I am building a website for a french company which sells products using Woocommerce and Elementor Pro. Almost all of the website is in french and I face no issues there. Only when I upload the csv ...
0
votes
0answers
19 views

Encoding video without exec function

I use ffmpeg to encode videos that i upload to my website, it works fine but the problem is that it requires exec function on host enabled, my host provider says enabling this function is a security ...
0
votes
0answers
20 views

Using decoded (non-latin) URL as a share link

I'm getting the non-latin WP permalink this way, to avoid ugly, long, encoded URL: $hebrew_url = rawurldecode(get_permalink()); And later, I'm using this URL in share popup: <div class="share-...
0
votes
0answers
15 views

How to fix UTF-8 string from webservice with illegal characters

I am consuming a webservice in my plugin. The responses says it is utf-8 encoded. However in some of the attributes (mostly names of people) there are special characters that look to be UTF-8 encoded ...
0
votes
0answers
26 views

Blank character set with WP-CLI

On one of our servers, WP-CLI seems to be convinced that the character set must be an empty string. $ wp db cli mysql: Character set '' is not a compiled character set and is not specified in the '/...
1
vote
1answer
38 views

Why WP encodes UNICODE (UTF8) containing urls? Any drawbacks of UNICODE url?

I am interested, if I have a category with unicode chars in slug, i.e. ა-ბ wp outputs that in html source like: %e1%83%98-%92%90 However, I can stop that functionality (with term_link filter), and ...
0
votes
1answer
40 views

How Can I Concatenate A String With One Of My Custom Field Value Before Saving The Post?

My website is a daily deals and offers site. I promote many online stores with affiliate links. I have created a php script to detect any merchant's link (ex- Amazon) and convert it to my affiliate ...
0
votes
0answers
61 views

How are cookie values encoded?

Title kind of says it all. I can easily generate the md5 hash for the key, but I noticed in my devtools that the value is also encoded somehow. I tried setting it to the plain-text value, but this isn'...
0
votes
1answer
28 views

Getting Non-printable characters were found while entering Euro Symbol

While inserting Euro symbol in wordpress theme code getting "Non-printable characters were found" error and also the euro symbol was not even shown properly. I have attached screenshot and also add ...
0
votes
0answers
18 views

How to encode correclty an url with the char “&” for an email?

In a plugin I need to send an email to confirm a member registration. Inside this email HTML Content, there is a link with two parameters like this : site_url() . "/user-profile/?activate=true&...
0
votes
0answers
10 views

Can I edit mogrify command arguments in WordPress if it uses ImageMagick during upload of images?

Reading through https://www.smashingmagazine.com/2015/06/efficient-image-resizing-with-imagemagick/ and https://wordpress.org/plugins/ricg-responsive-images/ from my understanding, it seems that ...
1
vote
2answers
349 views

Wordpress content shows this character ​​

In my website this characters ​​ showing up on everywhere in blog content and title, after many hours of searching and googling cant find any useful answer i tried this meta but no luck header("...
0
votes
1answer
203 views

Rest API encoding of double quotes

I have a standard rest API setup in WP. The results are displayed in an IOS App. Now the problem occurres, that single and double quotes and & are returned in the JSON as Unicode Decimal Code: eg. ...
3
votes
1answer
275 views

Strange characters on wordpress site - Not UTF8 Issue

I've imported WordPress post data onto a new site and noticed I have strange characters showing on pages and Blog posts. It usually shows where apostrophes should be. I've searched multiple ...
1
vote
1answer
118 views

HTML Entities displaying improperly as malformed escaped code

I'm having a strange issue that I've never seen before. I moved a WordPress site from Siteground over to GoDaddy a few days ago, and now the site appears to have problems displaying HTML entities in ...
0
votes
1answer
4k views

Remove “Category Archives: title” at the top of a category page [duplicate]

I created a category page that's linked to the main menu. It posts the categories fine, but it has the text "Category Archives:________" at the top of the page. Does anyone know to remove this. I'm ...
0
votes
1answer
58 views

js code not stored in database currectly

I'm trying to let the admin store a js code with one of the plugins I developed. For some reason for(i = 0; i < 5; i++) stores as for(i = 0; i &lt; 5; i++). I'm using sanitize_textarea_field to ...
1
vote
0answers
59 views

Emojis getting converted to “?”

Emojis in posts and comments on a 500+ posts blog get converted automatically into single question marks in irregular and untraceable intervals. The respective tables wp_comments and wp_posts are ...
0
votes
0answers
608 views

Character encoding issue - black diamond question marks on imported post excerpts

I am having some issues with character encoding on imported posts from an old Wordpress install. I am getting black diamonds with question marks on some of the posts I have imported to a new install. ...
0
votes
1answer
588 views

Uploaded image with non-english characters is named incorrectly in upload folder

When I upload an image with non-english characters in media uploader it gets incorrectly converted name in wordpress uploads folder but the image link in database is has correct name which results in ...
2
votes
2answers
490 views

Encode text string being appended as query to URL [closed]

I have a shortcode in use at present that embeds a button on selected product pages. Upon clicking this button, the user is brought to a contact form on another page and the title of the Product from ...
1
vote
1answer
452 views

How do I change database charset when using `wpdb`

I have a separate connection to connect to another DB with this code of line: $wpdb = new wpdb(STATYBA_USER, STATYBA_PASS, STATYBA_DB, STATYBA_HOST); and it has another DB charset (latin1 instead of ...
1
vote
1answer
288 views

Why does wp_redirect strip out %0A (url encoded new line character) and how do I make it stop?

Does this have something to do with sanitization? I need to pass a string as a URL parameter, and that string has \n characters in it. When the URL gets to the client, all other encoding is there (...
0
votes
0answers
241 views

Wordpress theme character encoding issue

I have set up nulled wordpress template with few functions and loops.Everything worked fine on localhost and hosting services. But i have got different charset while activating theme . The default ...
-2
votes
1answer
56 views

How to make sure the letters 'pez' do not convert to a fish symbol? [closed]

I have one field in a profile that converts the letters 'pez' into a fish symbol. It doesn't happen anywhere else throughout the site. Any suggestions on why this is happening and how to fix this?
1
vote
0answers
174 views

Avoid glitchy characters - my own version of the problem

I am having a problem with how WP handles content in the Visual vs. Text editor views. This has been very thoroughly discussed here and here, but my situation is not quite addressed: If I enter a ...
0
votes
1answer
56 views

How can I automatically add a post with Latin characters?

I would like to add a post in Wordpress with cURL (php) and I have this string to add as a content: $text = "Trovato, assieme a Massimo e Anna, in una cantina di Via Barrili a Milano, con un'...
0
votes
1answer
57 views

Theme-based character encoding issue

I am getting a Swiss Standard German, which looks like the letter "B", that replaces "ss" in my copy. When I test with plugins enabled/disabled using the 2017 theme the issue goes away. When I ...
1
vote
1answer
293 views

Adding inline JavaScript encoding issue

I came across an encoding issue when adding inline JavaScript to the footer of a WordPress page via wp_add_inline_script(). The following description is a boiled down version of the problem for ...
3
votes
1answer
280 views

DB_COLLATE not working on fresh install

I always knew that WordPress uses utf8_general_ci as tables collation, but recently it keeps installing utf8mb4_unicode_520_ci. What I do is: Download WordPress from wordpress.org Rename wp-config-...
2
votes
1answer
289 views

add_rewrite_rule not working for language specific characters

My default search query: example.com/search/?search_text=keyword What I want to transform it: example.com/search/keyword So I added this to my function.php add_rewrite_rule('^search/([^/]*)?','...
0
votes
1answer
508 views

character encoding problem in custom template

I am working on a website where I am using a custom template. My site having German character. When I use the visual editor(without template) it displays perfectly. Link But when I am using a custom ...
2
votes
0answers
168 views

Unexpected = (equal sign) characters in wp mail

I have created a custom form for user registration and a custom html email when someone registers. $headers = 'From: test<ttest@test.org>' . "\r\n"; $subject = 'Test Subj'; $msg=''; $msg .= '...
2
votes
1answer
361 views

How to set charset for wp_remote_post request?

I'm using wp_remote_post() on a project and it works great. But seems like the server on which I need to make the POST request is a Windows (ISS) server. So the third-party service that provides this ...
0
votes
1answer
35 views

restored old database now some characters have changed?

I had some site issues so I had to restore DB from old backup I used phpmy admin.... import function to restore DB Now all of sudden some characters have changed to "? " I have noticed mostly ...
3
votes
1answer
42 views

Website dumps encoded result

So for some reason i get this result on my website By reading other questions and searching the web i found that something like this could have been a result of some caching plug-in that interferes ...
1
vote
1answer
497 views

copying text from ms word to wordpress post appears weird [closed]

someone has send me an article for blog post it is an msword file when i copy and paste the text in my wordpress blog post the preview shows like this some characters appear small , some big, i ...
1
vote
0answers
44 views

images not showing after transfer

After transfer Wordpress to another host some images not shown on pages. I fixed all permissions firstly but I realized that images which contains characters like ç,ş not recognised by server. In ...
0
votes
1answer
316 views

Strange special character/Latin characters

We have developed many blogs on wordpress which is hosted on Rackspace server(Red Hat). Last Sunday we worked on user and set 'myuser' to run as PHP. So if we execute echo shell_exec('whoami'); then ...
0
votes
2answers
68 views

Search terms in other language turns out to question mark and symbols

I am facing one issue while i'm creating my website. I have a search bar on my website. I tried to type and search in chinese, but the search terms on page that i entered become question mark and ...
6
votes
2answers
1k views

Syntax error, unexpected 'class' (T_CLASS) on line 1 after upgrade to php 5.6.4

After upgrading to php 5.6.4 my widgets file causes: Parse error: syntax error, unexpected 'class' (T_CLASS) in /home/path/fss-widgets.php on line 1 I'm mystified - several hours research has ...
1
vote
1answer
554 views

WordPress load-scripts.php encoding issue

After updating to Wordpress 4.7, the WordPress load-scripts.php is producing the following result. We are unable to identify the cause of this.
5
votes
2answers
5k views

How to stop WordPress using utf8mb4_unicode_520_ci collation?

Recently I've installed PHP7 on my MAMP and updated to newest version of WordPress. Every time I do a new site all my tables are using collation utf8mb4_unicode_520_ci I have tried setting define('...
0
votes
2answers
3k views

How do I convert a MySQL database from utf8mb4 to utf8 encoding?

What happened: I had my blog hosted on SiteGround and my plan expired. I created a full website backup first which contained all the files including the public_html folder adn the databases associated ...
0
votes
1answer
1k views

wp_mail encode ’ in &rsquo; in subject

I create a function to send mail (in french) for custom post, it's work but subject is encoding in html. I do this : $get_title = get_the_title($ID); wp_mail("me@my.com","new article : ".$get_title,"...
0
votes
1answer
2k views

urlencode query string in gravity forms confirmation redirect

I have a form that passes information such as 'name', 'email', 'orderno', 'amount' and 'note' to a payment form hosted at ePay. In order to pass the field-values I use the standard-confirmation on ...
3
votes
1answer
105 views

do_settings_sections() doesn't escape quotes

I'm using the Settings API on a custom settings page: <form action='options.php' method='post'> <?php settings_fields('myplugin_settingsPage'); do_settings_sections('...
1
vote
1answer
179 views

How to write Hebrew characters?

Our database is set to: define(‘DB_CHARSET’, ‘utf8’); define(‘DB_COLLATE’, ”); As a result, entered Hebrew characters in a post are turned into question marks (?) on saving of the post. What is the ...
0
votes
1answer
74 views

How to distinguish between a hack and an encoding error?

This morning I was working with a new image gallery plugin. After two hours of working with it, our server was struggling with a heavy network traffic, and then the server appeared to go out. ...