<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Programowanie &#187; Opera</title>
	<atom:link href="http://cyryl.wordpress.com/category/opera/feed/" rel="self" type="application/rss+xml" />
	<link>http://cyryl.wordpress.com</link>
	<description>Cyryl i jego Metody</description>
	<lastBuildDate>Thu, 18 Oct 2007 13:38:00 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<language>pl</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<cloud domain='cyryl.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://www.gravatar.com/blavatar/922517fa0fdb146690e73f7f93dd9367?s=96&#038;d=http://s.wordpress.com/i/buttonw-com.png</url>
		<title>Programowanie &#187; Opera</title>
		<link>http://cyryl.wordpress.com</link>
	</image>
			<item>
		<title>Kolejna wpadka Opery, czyli Opera jest zła part 2</title>
		<link>http://cyryl.wordpress.com/2007/10/10/kolejna-wpadka-opery-czyli-opera-jest-zla-part-2/</link>
		<comments>http://cyryl.wordpress.com/2007/10/10/kolejna-wpadka-opery-czyli-opera-jest-zla-part-2/#comments</comments>
		<pubDate>Wed, 10 Oct 2007 15:42:27 +0000</pubDate>
		<dc:creator>cyryl</dc:creator>
				<category><![CDATA[Opera]]></category>

		<guid isPermaLink="false">http://cyryl.wordpress.com/2007/10/10/kolejna-wpadka-opery-czyli-opera-jest-zla-part-2/</guid>
		<description><![CDATA[Po tym jak już raz znalazłem błąd w Operze, który został naprawiony przyszła pora na kolejne starcie. Nie wiem, czy po prostu w Operze jest tyle błędów, czy może ja mam jedynie takie szczęście ciągle na nie wpadać&#8230;
W każdym bądź razie do rzeczy: Wszystko ogranicza się do tego, że Opera nie wykonuje akcji onClick() na [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cyryl.wordpress.com&blog=577868&post=8&subd=cyryl&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Po tym jak już raz znalazłem błąd w Operze, który został naprawiony przyszła pora na kolejne starcie. Nie wiem, czy po prostu w Operze jest tyle błędów, czy może ja mam jedynie takie szczęście ciągle na nie wpadać&#8230;</p>
<p>W każdym bądź razie do rzeczy: Wszystko ogranicza się do tego, że Opera nie wykonuje akcji onClick() na ukrytych polach formularza.</p>
<p>Przykład jest trochę zakręcony, bo długo myślałem i kombinowałem jak go przedstawić <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  Całośc powinna działać tak:</p>
<ol>
<li>Klikam na któryś &lt;label&gt; i powinno się wybrać od razu właściwe pole radio.</li>
<li>Zaznaczenie pola radio powinno uruchomić akcję onClick, które wyświetla alert() z wartością zaznaczonego radio.</li>
</ol>
<p>W Firefoksie działa wszystko prawidłowo &#8211; pojawia się jak powinno pole alert. Natomiast w operze nic się nie dzieje. A gdy zlikwiduje się regułkę ukrywającą pola (display:none) &#8211; nagle wszystko zaczęło działać.<br />
Znalezienie tego błędu zajęło mi dwa dni &#8211; ciekawe ile jeszcze jest takich niespodzianek w Operze&#8230; Na szczęście działa chociaż onChange()&#8230;</p>
<p>Kod testowy:</p>
<pre> &lt;style&gt;
  input[type='radio'] {display:none}
&lt;/style&gt;

&lt;form id="f" action="#" method="get"&gt;
  &lt;input type="radio" name="r" id="r1" value="radio1"
     onClick="fsubmit()"/&gt;&lt;label for="r1"&gt;Radio 1&lt;/label&gt;&lt;br/&gt;
  &lt;input type="radio" name="r" id="r2" value="radio2"
     onClick="fsubmit()"/&gt;&lt;label for="r2"&gt;Radio 2&lt;/label&gt;&lt;br/&gt;
&lt;/form&gt;

&lt;script type="text/javascript"&gt;

function getCheckedValue(name)  {
  inputs = document.getElementsByTagName('input');
  for(i=0; i&lt;inputs.length; i++) {
    if(inputs[i].name==name &amp;&amp; inputs[i].checked == true) {
      return inputs[i].value;
    }
  }
  return 'none selected';
}

function $(o) {
  return document.getElementById(o);
}

function fsubmit() {
  alert('Radio value: '+getCheckedValue('r'));
}

&lt;/script&gt;</pre>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/cyryl.wordpress.com/8/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/cyryl.wordpress.com/8/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cyryl.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cyryl.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cyryl.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cyryl.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cyryl.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cyryl.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cyryl.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cyryl.wordpress.com/8/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cyryl.wordpress.com/8/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cyryl.wordpress.com/8/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cyryl.wordpress.com&blog=577868&post=8&subd=cyryl&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://cyryl.wordpress.com/2007/10/10/kolejna-wpadka-opery-czyli-opera-jest-zla-part-2/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/7e7ac9116f110a107086181f31521be7?s=96&#38;d=identicon" medium="image">
			<media:title type="html">cyryl</media:title>
		</media:content>
	</item>
		<item>
		<title>Opera jest zła.</title>
		<link>http://cyryl.wordpress.com/2007/02/23/opera-jest-zla/</link>
		<comments>http://cyryl.wordpress.com/2007/02/23/opera-jest-zla/#comments</comments>
		<pubDate>Fri, 23 Feb 2007 21:00:59 +0000</pubDate>
		<dc:creator>cyryl</dc:creator>
				<category><![CDATA[Firefox]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Opera]]></category>

		<guid isPermaLink="false">http://cyryl.wordpress.com/2007/02/23/opera-jest-zla/</guid>
		<description><![CDATA[I głupia.
Oto prosty przykład. Taki sobie malutki kod:
&#60;input type="text" name="field" value="input #1" /&#62;
&#60;input type="text" id="field" name="field" value="input #2" /&#62;
&#60;input type="button" onclick="alert(document.getElementById('field').value)" value="click me!" /&#62;
Każdy w miarę inteligenty człowiek powie, że wynikiem powinno być okienko z tekstem &#8220;input #2&#8220;. Firefox też tak powie. Ale bynajmniej nie Opera. Jej zdaniem powinno być &#8220;input #1&#8220;. W końcu czemu [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cyryl.wordpress.com&blog=577868&post=4&subd=cyryl&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>I głupia.</p>
<p>Oto prosty przykład. Taki sobie malutki kod:<br />
<code>&lt;input type="text" name="field" value="input #1" /&gt;<br />
&lt;input type="text" id="field" name="field" value="input #2" /&gt;<br />
&lt;input type="button" onclick="alert(document.getElementById('field').value)" value="click me!" /&gt;</code><br />
Każdy w miarę inteligenty człowiek powie, że wynikiem powinno być okienko z tekstem &#8220;<em>input #2</em>&#8220;. Firefox też tak powie. Ale bynajmniej nie Opera. Jej zdaniem powinno być &#8220;<em>input #1</em>&#8220;. W końcu czemu niby warto zwracać uwagę na atrybut id=&#8221;"?</p>
<p>Ten taki idiotyzm Opery właśnie mnie kosztował jakieś dwie godziny pracy i szukania błędu :-/</p>
<p>UPATE: No i się udało. Opera to poprawi <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/cyryl.wordpress.com/4/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/cyryl.wordpress.com/4/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/cyryl.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/cyryl.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/cyryl.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/cyryl.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/cyryl.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/cyryl.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/cyryl.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/cyryl.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/cyryl.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/cyryl.wordpress.com/4/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=cyryl.wordpress.com&blog=577868&post=4&subd=cyryl&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://cyryl.wordpress.com/2007/02/23/opera-jest-zla/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/7e7ac9116f110a107086181f31521be7?s=96&#38;d=identicon" medium="image">
			<media:title type="html">cyryl</media:title>
		</media:content>
	</item>
	</channel>
</rss>