Forum FAQForum FAQSearchSearch MemberlistMemberlist Forum ignore listForum ignore list RegisterRegister ProfileProfile Log in to check your private messagesLog in to check your private messages Log inLog in
encoding problem

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Client-side
View previous topic :: View next topic  
Author Message
tmihetec



Joined: 23 Jan 2006
Posts: 27

PostPosted: 31.01.2007 14:56    Post subject: encoding problem Add user to your forum ignore list Reply with quote

Dakle, stranica je na
[url]veski.mihetec.com [/url]
charset je windows-1250. Kad se otvori stranica u browseru, po defaultu se postavi "western european (ISO)" tek kad se ručno postavi na "central european (windows)" stvar izgleda kako treba, U čemu je problem, kako da se automatski stranica otvara sa ce (win) encodingom? Neka preporuka za charset?

hvala!
Tomek
Back to top
View user's profile Send private message
tubak



Joined: 14 Mar 2005
Posts: 133
Location: Istra

PostPosted: 31.01.2007 15:04    Post subject: Add user to your forum ignore list Reply with quote

Ne znam šta koristiš u pozadini (ASP, PHP ili nešto drugo), ali meni se taj problem javljao kada sam miješao encoding po razlicitm includovima. (nadam se da kužiš o čemu pričam)

da se takvo nešto ne bi pojavljivalo, otpočetka izrade sajta, trebao bi sve stranice koje koristiš na sajtu staviti u ISTI encoding.
Back to top
View user's profile Send private message Visit poster's website
Sulien



Joined: 04 Jan 2004
Posts: 2905
Location: Zagreb

PostPosted: 31.01.2007 15:09    Post subject: Add user to your forum ignore list Reply with quote

imaš dobar META tag, ali server šalje krivi encoding u Content-Type headeru. znači - namjesti skriptu da pošalje isti content-type header kao što je naveden u meta

Code:
<?php
header('Content-Type: text/html; charset=windows-1250');


pravi HTTP header ima veći prioritet nego "http-equiv" META podatak
Back to top
View user's profile Send private message Send e-mail Visit poster's website
tmihetec



Joined: 23 Jan 2006
Posts: 27

PostPosted: 31.01.2007 15:53    Post subject: Add user to your forum ignore list Reply with quote

ta-da... radi... hvala Sulien, iako, nisam baš 100% ziher da sam shvatio u čemu je problem. Možeš li to malo pojasniti? Jel bi trebalo promijeniti nešto na serveru?

još 1om hvala!
Back to top
View user's profile Send private message
Sulien



Joined: 04 Jan 2004
Posts: 2905
Location: Zagreb

PostPosted: 31.01.2007 21:47    Post subject: Add user to your forum ignore list Reply with quote

koristiš PHP, ne Confused e pa linija koda koju sam ti poslao rješi problem, ona pošalje HTTP header prema browseru

ako ne znaš što je HTTP header možda je vrijeme da naučiš barem kako osnovno Web funkcionira
Back to top
View user's profile Send private message Send e-mail Visit poster's website
tmihetec



Joined: 23 Jan 2006
Posts: 27

PostPosted: 01.02.2007 10:54    Post subject: Add user to your forum ignore list Reply with quote

moje pitanje je bilo inicirano time što ista stranica na jednom serveru/hostingu radi onako kako ja očekujem, dok na drugom moram ručno prebaciti encoding u browseru da stvar kopa.
Mislio sam da znam dovoljno o headerima i kako web funkcionira Embarassed ... jeb'ga... ovo mi je prije svega izgledao kao problem u konfiguraciji servera (Apache). A s druge strane, da sve znam, nebih ništa ni pitao. ...

svejedno na odgovoru
odoh spoznavati o headerima...
Back to top
View user's profile Send private message
tmihetec



Joined: 23 Jan 2006
Posts: 27

PostPosted: 05.02.2007 16:37    Post subject: Add user to your forum ignore list Reply with quote

ako tko naleti na isti problem... ovdje može krenuti tražiti odgovor...

http://padawan.info/web/debugging_charset_encoding_mismatch_with_apache.html

pozdrav,
tomek
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Client-side All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group