WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When I create a page whose title contains only digits - wordpress adds '-2' to the url, like it does in cases, where there is a page with the same name already existing. However this is not the case here.

Example: If I create a page titled 909303, the url will be: ../909303-2/

I want it to be ../909303/. How do I do that conveniently?

share|improve this question
up vote 0 down vote accepted

well.. it is not exactly the case, but in a way, it is . every page has actually "2" names , one is the name you give and one is the ID, which is the number. If you will give a "name" which is a "number" - it might override another entity (Can be a post, page , attachment, or even a draft) with the same ID. that would result in multiple errors and 404 , depending on your permalink structure.

SO , it is not such a good idea to do that, but if you really want to go with it first try to change your permalink structure and if that does not work, you will need to hook the sanitize_title() - but I will still advise to avoid such a practice.

( read here for more: http://core.trac.wordpress.org/ticket/5305#comment:25 - it is an old post from previous wordpress releases - , but maybe will let you understand WHY it is doing what it does.)

share|improve this answer

Your Answer


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.