Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Single apostrophe is changed to two in Doc title #961

Closed
michaeltorbert opened this issue Jul 14, 2017 · 4 comments
Closed

Single apostrophe is changed to two in Doc title #961

michaeltorbert opened this issue Jul 14, 2017 · 4 comments
Labels
Milestone

Comments

@michaeltorbert
Copy link
Contributor

michaeltorbert commented Jul 14, 2017

Reported here: https://wordpress.org/support/topic/july-update-adding-an-extra-to-my-title/ to have broken in 2.3.14

@wpsmort
Copy link

wpsmort commented Jul 14, 2017

@michaeltorbert @amostajo I was able to reproduce this on a brand new site. The problem is with the %blog_title% part of the title tag. To reproduce this follow these steps:

  • Set up a site where the Site Title has an apostrophe, i.e Steve's Test Site
  • Activate AIOSEOP v2.3.14 with default config
  • Visit any page or post on the site and look at the browser tab, you should see the two apostrophes, see screenshot below

I tested this with all versions of PHP from 5.2 to 7.1 and got the same result.

screen shot 2017-07-14 at 9 55 26 am

@michaeltorbert
Copy link
Contributor Author

In my testing I just left everything blank but put Michael's site in the site title in WordPress General Settings (not AIOSEOP settings) and it showed up as a quotation mark.

@michaeltorbert
Copy link
Contributor Author

michaeltorbert commented Jul 14, 2017

The problem is that ' (which is a single apostrophe) is being checked for in aioseop_class.php:4913

amostajo added a commit to amostajo/all-in-one-seo-pack that referenced this issue Jul 14, 2017
@amostajo
Copy link
Contributor

@michaeltorbert The change is partially fine. But we might need to include the charcode conversion in the preg_replace to support PHP5.2.

See this commit on my fork.

michaeltorbert pushed a commit that referenced this issue Jul 15, 2017
Fixes apostrophe charcode conversion.
amostajo added a commit to amostajo/all-in-one-seo-pack that referenced this issue Jul 16, 2017
Standarizes and encodes multiple instances and charcodes of apostrophe
for better encoding.
michaeltorbert pushed a commit that referenced this issue Jul 16, 2017
Standarizes and encodes multiple instances and charcodes of apostrophe
for better encoding.
michaeltorbert pushed a commit that referenced this issue Jul 16, 2017
Fixes apostrophe charcode conversion.
michaeltorbert pushed a commit that referenced this issue Jul 16, 2017
Standarizes and encodes multiple instances and charcodes of apostrophe
for better encoding.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants