The online racing simulator
That's a fantastic idea. +20!
Well, I'll take that as a no, so:

Does anybody know an open source font that
- includes all the required characters
- isn't too large
- doesn't look too shitty
?
I encountered some strange behaviour in color converting lately:
I've been playing with some old files and came across this (see attached pic):
which was given as: ^1^2^4Zs^3oo^4ti instead of - as I would expect -:
^1^^2^4Zs^3oo^4ti

Now the question is:
Is my colour conversion wrong and it should display without "^2" (meaning it would had once been possible to "row-up" "color-switches")
Or is this correct and a literal "^" wasn't escaped back then?

Unfortunately I cannot have a look ingame as the corresponding replay was of patch P, which I can't unlock

I got this 3 or 4 times (from different drivers) but always from replays of patch P or Q ... so no checking possible on my side


EDIT:
Well, by now I figured it out myself by simply naming a new player that way and checking with the unlocked version in demo mode

For those wondering: It was handled as consecutive color changes, so no red "^2" in that name and the error was on my part ... I never trusted those regex-things anyway *grmblfx*
Attached images
zsoooti.PNG
This
^1^2^4Zs^3oo^4ti

, should really be sanitized down to
^4Zs^3oo^4ti

that should be Zsooti. The way I read it, the first two colors should have no effect.
Yeah, quite so ... I also already fixed my functions

Anyway, I wonder, how and why it was ever possible to get such a name as nowadays this doesn't seem to happen anymore
Quote from avetere :Yeah, quite so ... I also already fixed my functions

Anyway, I wonder, how and why it was ever possible to get such a name as nowadays this doesn't seem to happen anymore

cfg file backup or editing?
Quote from Krammeh :cfg file backup or editing?

Manual input into the config file that was not sanitized by the LFS game name parser?

[edit] Oh never mind, apparently Krammeth beat me to it.
LOL ... yeah ... this was simply too obvious, as I tested it the same way
For some reason the codepage converter doesn't work on this string " 55 M.^EŒmieszek^L finished 3rd" - in a MySQL db but doesn't work out of it either (should be M. Śmieszek). Am I doing something wrong?
hm yeah when i try with the function in the first post, it doesn't work.

I seem to be using a way more elaborate function myself though. It's a combination of mb_convert_encoding and the good old fashioned lookup tables for a number of codepages that I think were problematic with mb_convert_encoding.

So umm, want me to post that whole thing? It doesn't look super nice, but I think it works well. It decoded the given string just fine.
I'm not sure if anyone else has found a better solution yet. It's always been a tough thing to get right.
Would be nice to try it
Ok, here they are.
Note that the FunctionsLFSColors.php file includes (require_once()) the cp_unicode_tables.php file. So if this stuff fails, make sure that works.

Once you include these files in your pages, you just use the following to convert any LFS string :

WriteColor($lfsstring);

NOTE : I think it only converts to HTML-entities. So if you need utf8 you might be outta luck.
Attached files
cpconvert.zip - 3.8 KB - 869 views
Hmm yeah, HTML entities are not what I'm looking for. I'm comparing something in a database (e.g. T.Nogie^Eæ or M.Mizio^E³ek) to a name I already have in UTF-8 to check if a driver has finished the race or not, so I just need the character. Those two work fine with the original code, but ^EŒ just returns nothing!
In this zip yes;

function codepage_convert (&$str, $conv_to = 'HTML-ENTITIES') {

but like the first post of this topic already mentions;

function codepage_convert ($str, $conv_to = 'UTF-8') {

Just came back from the club, might be completely missing the point here. (Always nice these disclaimers)
I did try that, but it still provides an HTML entity.
Ehhhmm...

Where? Not as far as I know.

You might want to know I use this code myself to display the 24h chat .. If you look at the source it's UTF8 and special chars are the same as in-game.

(*You need to select a part of the chat and do view source because of AJAX)
(** updated screenshot shows no HTML entities for Euro sign and trademark symbol as another example )
Attached images
screenshot.jpg
updatedscreenshot.png
Might want to look at 16:10, I joined as Śmad to say hi but it removed the first letter
Hmm yeah, indeed... Also just discovers that it filters something else (direct talking to somebody else) but thats my problem .


^7^EŒmad ^7: ^8^1CG^7™^4»^3nl2dav ^7- ^9hi

I think this character you are using is somewhere not supported in the code pages..

But, it does not produce HTML entities. Trademark symbols, Euro signs (see updated post above) are not converted to HTML entitites.
I downloaded the files again to make sure I hadn't changed anything since yesterday, then changed it to UTF-8 - still produces HTML entities.

The problem is that viewing the selection source is that it doesn't show HTML entities (see attachment)
Attached images
blahblah.png
I see you have problems with Polish characters Just change them removing special parts, like: ś to s, ą to a, ć to c. I can make you replace array for that.
Quote from boothy :
The problem is that viewing the selection source is that it doesn't show HTML entities (see attachment)

No its not... I don't know how you get that but I think you are getting tricked by Firefox.


<a href="#" title="Steelbeen">[Mâ[B]„[/B]¢]Steelbeen</a></div> <div class="td60… [URL="http://validator.w3.org/feedback.html?uri=http%3A%2F%2Fwww.cargame.nl%2Fchat_s2.php;errmsg_id=139#errormsg"]✉[/URL]
You have used an illegal character in your text. HTML uses the standard [URL="http://www.unicode.org/"]UNICODE Consortium[/URL] character repertoire,

Source: validator (if I force ISO-8859-1 on the original chat source bit)

I don't have a text browser installed to ultimately verify it but I cannot think of a reason there are HTML entities, nowhere this request is being made in PHP coding.

Quote from misiek08 :Just change them removing special parts, like: ś to s, ą to a, ć to c. I can make you replace array for that.

Thats evading the problem, not solving it
2
This thread is closed

FGED GREDG RDFGDR GSFDG