NBSP; instead of spaces

General Chat, Comments
Post Reply
User avatar
cbsarge
Posts: 195
Joined: Mon Sep 14, 2015 3:20 pm

NBSP; instead of spaces

Post by cbsarge »

I just checked and all of the CSS files in play have utf-8 declared at the top but, some of my "spaces" are rendering as   when displayed.

Anyone have any suggestions on a fix?
User avatar
cbsarge
Posts: 195
Joined: Mon Sep 14, 2015 3:20 pm

Re: NBSP; instead of spaces

Post by cbsarge »

I just checked and it seems to do it even on an unmodified version of NWE on my test server.

It looks like more than one "space" is causing an nbsp to be rendered. Below are the results of entering test and then 1, 2 and 3 spaces after.

test onespace
test  twospaces
test   threespaces

Has anyone dealt with this issue yet?
User avatar
cbsarge
Posts: 195
Joined: Mon Sep 14, 2015 3:20 pm

Re: NBSP; instead of spaces

Post by cbsarge »

a space followed by a carriage return is also causing a nbsp to be displayed.
User avatar
hallsofvallhalla
Site Admin
Posts: 12031
Joined: Wed Apr 22, 2009 11:29 pm

Re: NBSP; instead of spaces

Post by hallsofvallhalla »

Thats a strange one and I wish I had an answer but I have never had that issue. Does all HTML entities do that or just the space? What happpens if you use &xa0; ?
User avatar
cbsarge
Posts: 195
Joined: Mon Sep 14, 2015 3:20 pm

Re: NBSP; instead of spaces

Post by cbsarge »

Could it be something different about the collation of my database? Right now the Content field in the DB is set to utf_bin.
User avatar
gmoore
Posts: 212
Joined: Wed Jun 04, 2014 5:40 pm

Re: NBSP; instead of spaces

Post by gmoore »

Do you have a link with the example? Very interested.
Greg
Running a game is like riding a bike ... well it should be!

New Worlds Engine / FunMayhem.com
Helping you get your game concept up and running. Now.
User avatar
cbsarge
Posts: 195
Joined: Mon Sep 14, 2015 3:20 pm

Re: NBSP; instead of spaces

Post by cbsarge »

If you log onto my site and browse the forum (not alot there) you'll see it.
http://www.villainsvsheroes.net
User avatar
gmoore
Posts: 212
Joined: Wed Jun 04, 2014 5:40 pm

Re: NBSP; instead of spaces

Post by gmoore »

Am on but already fighting people. Ooomf, Powwww!
Running a game is like riding a bike ... well it should be!

New Worlds Engine / FunMayhem.com
Helping you get your game concept up and running. Now.
User avatar
gmoore
Posts: 212
Joined: Wed Jun 04, 2014 5:40 pm

Re: NBSP; instead of spaces

Post by gmoore »

Running a game is like riding a bike ... well it should be!

New Worlds Engine / FunMayhem.com
Helping you get your game concept up and running. Now.
User avatar
hallsofvallhalla
Site Admin
Posts: 12031
Joined: Wed Apr 22, 2009 11:29 pm

Re: NBSP; instead of spaces

Post by hallsofvallhalla »

Ah so this going into the databse then being extracted back out before being put on the page. Have you tried HTML encoding and unencoding?
Post Reply

Return to “General”