Giter Club home page Giter Club logo

Comments (8)

wpsmort avatar wpsmort commented on July 28, 2024

See also this forum post where the user has double quotes in his Site Title which is throwing the character count off - https://wordpress.org/support/topic/error-calculating-title

from all-in-one-seo-pack.

nishant981 avatar nishant981 commented on July 28, 2024

we are working on Bug with character counter.

from all-in-one-seo-pack.

nishant981 avatar nishant981 commented on July 28, 2024

This issue is not because of html that is being counted in the length. This is because of All in one SEO Pack taking the length of the separator between the site title and page title. As you can see in the screenshot it is showing 3 even when there is no title as shown in screenshot. e.g. We have the title including website name and page title 'WN | Shop' , here length will be 9 including separator. Also do we need to trim the space if user intentionally add spaces left and to the right?

blank-title
title with extra length

from all-in-one-seo-pack.

debabratakarfa avatar debabratakarfa commented on July 28, 2024

Hi,
The 3 Count is coming for %page_title% | %blog_title% setting at All In One SEO Setting

1 for %page_title%, another 1 for | and last for %blog_title%

If set %page_title% or nothing to Page Title Format, you will find 0 count on Each page

Thanks
edit page wordpress 3
general settings wordpress 1

from all-in-one-seo-pack.

wpsmort avatar wpsmort commented on July 28, 2024

@nishant981, that's not the bug. The bug is with HTML characters included in the Site Title field in WordPress. Here are the steps to replicate this bug:

1). Go to Settings > General in WordPress and set the Site Title as A & B
2). Create a page called Test and scroll down to the All in One SEO Pack meta box and set the Title as ABC
3). You should see that the character counter shows 15 characters when it should show 11 characters
4). View the source code of this page and you'll see that the Title tag is output as this - <title>ABC | A & B</title>. You'll see that the & symbol is output in the source code as the HTML code & which is why the character count is 15 characters:

This is 15 characters: ABC | A & B
But this is 11 characters: ABC | A & B

This is only a bug when someone uses special characters in their Site Title and they set a Title in All in One SEO Pack.

from all-in-one-seo-pack.

nishant981 avatar nishant981 commented on July 28, 2024

Thanks for explaining, We will check it again and apply the fixes.

from all-in-one-seo-pack.

nishant981 avatar nishant981 commented on July 28, 2024

I have uploaded my code to git, please check and let me know it is fine and I can follow the same steps further

from all-in-one-seo-pack.

wpsmort avatar wpsmort commented on July 28, 2024

I found that this bug was fixed in v2.4

from all-in-one-seo-pack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.