Skocz do zawartości
  • 👋 Witaj na MPCForum!

    Przeglądasz forum jako gość, co oznacza, że wiele świetnych funkcji jest jeszcze przed Tobą! 😎

    • Pełny dostęp do działów i ukrytych treści
    • Możliwość pisania i odpowiadania w tematach
    • System prywatnych wiadomości
    • Zbieranie reputacji i rozwijanie swojego profilu
    • Członkostwo w jednej z największych społeczności graczy

    👉 Dołączenie zajmie Ci mniej niż minutę – a zyskasz znacznie więcej!

    Zarejestruj się teraz

Polskie Znaki w plikach Shakes&Fidget


ZeuSXP

Rekomendowane odpowiedzi

Opublikowano

######REKLAMA#####

#

#

#

#

#

#

#

#

#

######REKLAMA#####

Jak zauważyłem w najnowszych plikach sfgame

brakuje paru linijek które są potrzebne by

polskie znaki działały w opisach itp.

Postanowiłem więc udostęnić moje linijki kodu:

 

Instrukcja:

 

Zmieniamy w pliku req.php

całą funkcje "fixSpecialChars"

na to :

function fixSpecialChars($text)
{

$text = str_replace('ł', 'ł', $text);
$text = str_replace('Ł', 'Ł', $text);
$text = str_replace('ą', 'ą', $text);
$text = str_replace('Ą', 'Ą', $text);
$text = str_replace('ę', 'ę', $text);
$text = str_replace('Ę', 'Ę', $text);
$text = str_replace('ć', 'ć', $text);
$text = str_replace('Ć', 'Ć', $text);
$text = str_replace('ś', 'ś', $text);
$text = str_replace('Ś', 'Ś', $text);
$text = str_replace('ż', 'ż', $text);
$text = str_replace('Ż', 'Ż', $text);
$text = str_replace('ź', 'ź', $text);
$text = str_replace('Ź', 'Ź', $text);
$text = str_replace('%40', '@', $text);

return $text;
}

 

Ewentualnie jeśli kożystamy z

innych plików:

 

1.Szukamy takich linijek:

 

$ret[511] .= ";" . urldecode($db_data['user_desc']) . ";";

 

2. Zmieniamy powyższy kod na :

 

$ret[511] .= ";" . fixSpecialChars(urldecode($db_data['user_desc'])) . ";";

 

3. Dodajemy funkcje :

 

function fixSpecialChars($text)
{

$text = str_replace('ł', 'ł', $text);
$text = str_replace('Ł', 'Ł', $text);
$text = str_replace('ą', 'ą', $text);
$text = str_replace('Ą', 'Ą', $text);
$text = str_replace('ę', 'ę', $text);
$text = str_replace('Ę', 'Ę', $text);
$text = str_replace('ć', 'ć', $text);
$text = str_replace('Ć', 'Ć', $text);
$text = str_replace('ś', 'ś', $text);
$text = str_replace('Ś', 'Ś', $text);
$text = str_replace('ż', 'ż', $text);
$text = str_replace('Ż', 'Ż', $text);
$text = str_replace('ź', 'ź', $text);
$text = str_replace('Ź', 'Ź', $text);
$text = str_replace('%40', '@', $text);

return $text;
}

 

 

 

 

I cieszymy się polskimi znakami!!!

Opublikowano

funkcja jest nieco wybrakowana

 

brakuje m.ni.

$text = str_replace('on-game', 'prosf', $text); 
$text = str_replace('norbisf', 'prosf', $text); 
$text = str_replace('ń', 'ń', $text);
$text = str_replace('Ń', 'Ń', $text);

polecam

Hejo

Opublikowano

funkcja jest nieco wybrakowana

 

brakuje m.ni.

$text = str_replace('on-game', 'prosf', $text); 
$text = str_replace('norbisf', 'prosf', $text); 
$text = str_replace('ń', 'ń', $text);
$text = str_replace('Ń', 'Ń', $text);

polecam

Polskie znaki miałem kilka miesięcy temu, nie wiem o co Ci chodzi.

 

Polecam skrypty. Teraz Ci Wnosi czy wynosi?... - Dla moda.

Zarchiwizowany

Ten temat przebywa obecnie w archiwum. Dodawanie nowych odpowiedzi zostało zablokowane.

×
×
  • Dodaj nową pozycję...