<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Форум PHP-MyAdmin.RU &mdash; Вопросики вместо русского]]></title>
		<link>https://forum.php-myadmin.ru/viewtopic.php?id=1523</link>
		<atom:link href="https://forum.php-myadmin.ru/extern.php?action=feed&amp;tid=1523&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[Недавние сообщения в теме «Вопросики вместо русского».]]></description>
		<lastBuildDate>Mon, 18 Jan 2010 17:41:36 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Вопросики вместо русского]]></title>
			<link>https://forum.php-myadmin.ru/viewtopic.php?pid=10319#p10319</link>
			<description><![CDATA[<p>Достаточно строки mysql_query(&#039;SET NAMES cp1251&#039;);<br />Остальное лишнее, так как устанавливается автоматически данным запросом.</p><p>Если возможны несколько соединений, то лучше указать в функции к какому из них относится запрос.<br /></p><div class="codebox"><pre><code>// 1
mysql_query(&#039;SET NAMES cp1251&#039;, $link);

// 2
mysql_query(&#039;SET NAMES cp1251&#039;, $serverid);

// 3
mysql_query(&#039;SET NAMES cp1251&#039;, $this-&gt;conn_id);</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (Hanut)]]></author>
			<pubDate>Mon, 18 Jan 2010 17:41:36 +0000</pubDate>
			<guid>https://forum.php-myadmin.ru/viewtopic.php?pid=10319#p10319</guid>
		</item>
		<item>
			<title><![CDATA[Re: Вопросики вместо русского]]></title>
			<link>https://forum.php-myadmin.ru/viewtopic.php?pid=10316#p10316</link>
			<description><![CDATA[<p>Все спасибо, добавил строчку и заработало.<br />mysql_query(&quot;SET NAMES &#039;cp1251&#039; &quot;); </p><p>и все помогло</p><p>А если поставить <br />mysql_query(&quot;SET NAMES &#039;cp1251&#039; &quot;); <br />mysql_query(&quot;set character_set_client=&#039;cp1251&#039;&quot;);<br />mysql_query(&quot;set character_set_conneccion=&#039;cp1251&#039;&quot;);<br />mysql_query(&quot;set character_set_results=&#039;cp1251&#039;&quot;); </p><p>то какая разница?</p>]]></description>
			<author><![CDATA[null@example.com (seboz)]]></author>
			<pubDate>Mon, 18 Jan 2010 16:30:30 +0000</pubDate>
			<guid>https://forum.php-myadmin.ru/viewtopic.php?pid=10316#p10316</guid>
		</item>
		<item>
			<title><![CDATA[Re: Вопросики вместо русского]]></title>
			<link>https://forum.php-myadmin.ru/viewtopic.php?pid=10315#p10315</link>
			<description><![CDATA[<p>Вот что нашел в php файлах<br />может тут что прописать?</p><p>в 1 файле<br />&nbsp; if (!($link=mysql_connect($hostName,$userName,$password))) {<br />&nbsp; &nbsp; printf(&quot;Ошибка при соединении с MySQL !\n&quot;);<br />&nbsp; &nbsp; exit();</p><p>2 файл - <br /> $serverid&nbsp; = mysql_connect($POLLDB[&quot;host&quot;], $POLLDB[&quot;user&quot;], $POLLDB[&quot;pass&quot;]) or poll_error_msg(&quot;Cannot connect to mysql database&quot;);<br />&nbsp; &nbsp; if(!@mysql_select_db($POLLDB[&quot;dbName&quot;],$serverid)) {<br />&nbsp; &nbsp; &nbsp; &nbsp; mysql_create_db($POLLDB[&quot;dbName&quot;]);</p><p>3 файл - <br /> $this-&gt;conn_id = mysql_connect($this-&gt;db[&#039;host&#039;].&quot;:&quot;.$this-&gt;port,$this-&gt;db[&#039;user&#039;],$this-&gt;db[&#039;pass&#039;]);<br />&nbsp; &nbsp; &nbsp; &nbsp; if ($this-&gt;conn_id == 0) {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $this-&gt;sql_error(&quot;Connection Error&quot;);</p>]]></description>
			<author><![CDATA[null@example.com (seboz)]]></author>
			<pubDate>Mon, 18 Jan 2010 15:36:22 +0000</pubDate>
			<guid>https://forum.php-myadmin.ru/viewtopic.php?pid=10315#p10315</guid>
		</item>
		<item>
			<title><![CDATA[Re: Вопросики вместо русского]]></title>
			<link>https://forum.php-myadmin.ru/viewtopic.php?pid=10308#p10308</link>
			<description><![CDATA[<p><strong>seboz</strong><br />Если в phpMyAdmin кириллица выглядит нормально, то надо только установить кодировку соединения с MySQL в cp1251. Обычные скрипты вроде форумов имеют директиву для установки кодировки соединения с MySQL, поэтому ее только надо прописать. Если скрипт собственный, или такой директивы не имеет, то необходимо найти вызов функции mysql_connect и сразу после нее добавить строку:<br /></p><div class="codebox"><pre><code>mysql_query(&#039;SET NAMES cp1251&#039;);</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (Hanut)]]></author>
			<pubDate>Mon, 18 Jan 2010 14:24:23 +0000</pubDate>
			<guid>https://forum.php-myadmin.ru/viewtopic.php?pid=10308#p10308</guid>
		</item>
		<item>
			<title><![CDATA[Re: Вопросики вместо русского]]></title>
			<link>https://forum.php-myadmin.ru/viewtopic.php?pid=10305#p10305</link>
			<description><![CDATA[<p>Кириллица выглядит совершенно нормально, под разным дампами кодирово.</p><p>Вот что выдает</p><p>Variable_name &nbsp; &nbsp; Value<br />character_set_client &nbsp; &nbsp; latin1<br />character_set_connection &nbsp; &nbsp; latin1<br />character_set_database &nbsp; &nbsp; latin1<br />character_set_filesystem &nbsp; &nbsp; binary<br />character_set_results &nbsp; &nbsp; latin1<br />character_set_server &nbsp; &nbsp; latin1<br />character_set_system &nbsp; &nbsp; utf8<br />character_sets_dir &nbsp; &nbsp; /usr/share/mysql/charsets/</p>]]></description>
			<author><![CDATA[null@example.com (seboz)]]></author>
			<pubDate>Mon, 18 Jan 2010 13:39:01 +0000</pubDate>
			<guid>https://forum.php-myadmin.ru/viewtopic.php?pid=10305#p10305</guid>
		</item>
		<item>
			<title><![CDATA[Re: Вопросики вместо русского]]></title>
			<link>https://forum.php-myadmin.ru/viewtopic.php?pid=10297#p10297</link>
			<description><![CDATA[<p><strong>seboz</strong><br />Покажите вывод глобальных настроек:<br />SHOW GLOBAL VARIABLES LIKE &#039;character%&#039;;</p><p>Посмотрите как выглядит кириллица на новом сервере в phpMyAdmin. Она может выглядеть нормально, либо уже там будет в битом виде (крякозябы).</p>]]></description>
			<author><![CDATA[null@example.com (Hanut)]]></author>
			<pubDate>Mon, 18 Jan 2010 08:47:10 +0000</pubDate>
			<guid>https://forum.php-myadmin.ru/viewtopic.php?pid=10297#p10297</guid>
		</item>
		<item>
			<title><![CDATA[Вопросики вместо русского]]></title>
			<link>https://forum.php-myadmin.ru/viewtopic.php?pid=10293#p10293</link>
			<description><![CDATA[<p>Здравствуйте!<br />Что делать, кодировка отображается не правильно!</p><p>Скачал дамп базы с одного сервера и перенес на другой, и появились вопросики вместо текста. Дамп скачивал в разной кодировке, ничего не меняется, последний раз скачал в cp1251</p><p>после команды SHOW VARIABLES LIKE &#039;character%&#039; <br />на старом месте результаты:<br />Variable_name &nbsp; &nbsp; Value<br />character_set_client &nbsp; &nbsp; utf8<br />character_set_connection &nbsp; &nbsp; utf8<br />character_set_database &nbsp; &nbsp; cp1251<br />character_set_filesystem &nbsp; &nbsp; binary<br />character_set_results &nbsp; &nbsp; utf8<br />character_set_server &nbsp; &nbsp; cp1251<br />character_set_system &nbsp; &nbsp; utf8<br />character_sets_dir &nbsp; &nbsp; /usr/share/mysql/charsets/</p><p>на новом где вопросики:<br />Variable_name &nbsp; &nbsp; Value<br />character_set_client &nbsp; &nbsp; utf8<br />character_set_connection &nbsp; &nbsp; cp1251<br />character_set_database &nbsp; &nbsp; cp1251<br />character_set_filesystem &nbsp; &nbsp; binary<br />character_set_results &nbsp; &nbsp; utf8<br />character_set_server &nbsp; &nbsp; latin1<br />character_set_system &nbsp; &nbsp; utf8<br />character_sets_dir &nbsp; &nbsp; /usr/share/mysql/charsets/</p><p>что делать?</p>]]></description>
			<author><![CDATA[null@example.com (seboz)]]></author>
			<pubDate>Mon, 18 Jan 2010 04:05:53 +0000</pubDate>
			<guid>https://forum.php-myadmin.ru/viewtopic.php?pid=10293#p10293</guid>
		</item>
	</channel>
</rss>
