If title have "? , " how to replace

If
http://domain.com/knowledgebas/id/title-knowledgebase ---> OK
But

http://domain.com/knowledgebas/id/title-knowledgebase? ---> 404