﻿
{"id":2890,"date":"2014-07-14T23:41:36","date_gmt":"2014-07-14T23:41:36","guid":{"rendered":"http:\/\/www.gencayyildiz.com\/blog\/?p=2890"},"modified":"2014-07-14T23:41:36","modified_gmt":"2014-07-14T23:41:36","slug":"jquery-bir-classin-style-yapisina-mudahale","status":"publish","type":"post","link":"https:\/\/www.gencayyildiz.com\/blog\/jquery-bir-classin-style-yapisina-mudahale\/","title":{"rendered":"jQuery &#8211; Bir Class&#8217;\u0131n Style Yap\u0131s\u0131na M\u00fcdahale"},"content":{"rendered":"<div id=\"fb-root\"><\/div>\n<p>\u00d6nceki yaz\u0131lar\u0131mda bir id ve tag\u0131n jQuery ile style yap\u0131s\u0131n\u0131n nas\u0131l de\u011fi\u015ftirildi\u011fini incelemi\u015ftik.\u015eimdi ise bir Class yap\u0131s\u0131n\u0131n style yap\u0131s\u0131n\u0131 de\u011fi\u015ftirmeyi inceleyece\u011fiz.<br \/>\n<!--more--><br \/>\nYaz\u0131m\u0131z\u0131n ana konusunu \u015fekillendirirken a\u015fa\u011f\u0131daki HTML yap\u0131dan yararlanaca\u011f\u0131z.<\/p>\n<pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\r\n&lt;html&gt;\r\n&lt;head&gt;\r\n&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text\/html; charset=utf-8&quot; \/&gt;\r\n&lt;\/head&gt;\r\n&lt;body&gt;\r\n&lt;div class=&quot;gorunumclass&quot;&gt;Merhaba, J\u00fcpiter&lt;\/div&gt;\r\n&lt;input type=&quot;submit&quot; value=&quot;De\u011fi\u015ftir&quot; \/&gt;\r\n&lt;\/body&gt;\r\n&lt;\/html&gt;\r\n<\/pre>\n<p>Burada g\u00f6rd\u00fc\u011f\u00fcn\u00fcz gibi &#8220;gorunumclass&#8221; isminde bir Class yap\u0131s\u0131na sahip bir &#8220;&lt;div&gt;&#8221; nesnemiz ve bir adette &#8220;De\u011fi\u015ftir&#8221; isminde butonumuz mevcut.Butonumuza t\u0131kland\u0131\u011f\u0131 zaman jQuery ile &#8220;gorunumclass&#8221; Class de\u011ferine sahip HTML nesnelerin style yap\u0131lar\u0131n\u0131 de\u011fi\u015ftirece\u011fiz.<\/p>\n<pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\r\n&lt;html&gt;\r\n&lt;head&gt;\r\n&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text\/html; charset=utf-8&quot; \/&gt;\r\n&lt;script type=&quot;text\/javascript&quot; src=&quot;js\/jquery-2.0.2.min.js&quot;&gt;&lt;\/script&gt;\r\n&lt;script type=&quot;text\/javascript&quot;&gt;\r\nfunction Degistir()\r\n{\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;width&quot;,&quot;355px&quot;);\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;color&quot;,&quot;#C03&quot;);\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;border-style&quot;,&quot;ridge&quot;);\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;font-size&quot;,&quot;24px&quot;);\r\n\t}\r\n&lt;\/script&gt;\r\n&lt;\/head&gt;\r\n&lt;body&gt;\r\n&lt;div class=&quot;gorunumclass&quot;&gt;Merhaba, J\u00fcpiter&lt;\/div&gt;\r\n&lt;input type=&quot;submit&quot; value=&quot;De\u011fi\u015ftir&quot; onclick=&quot;Degistir();&quot; \/&gt;\r\n&lt;\/body&gt;\r\n&lt;\/html&gt;\r\n<\/pre>\n<p>Yukar\u0131daki kod par\u00e7ac\u0131\u011f\u0131nda &#8220;gorunumclass&#8221; Class de\u011ferine sahip HTML nesnelerinin style yap\u0131lar\u0131na jQuery ile m\u00fcdahale etmi\u015f olduk.\u015eimdide a\u015fa\u011f\u0131daki kod par\u00e7ac\u0131\u011f\u0131n\u0131 inceleyelim.<\/p>\n<pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\r\n&lt;html&gt;\r\n&lt;head&gt;\r\n&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text\/html; charset=utf-8&quot; \/&gt;\r\n&lt;script type=&quot;text\/javascript&quot; src=&quot;js\/jquery-2.0.2.min.js&quot;&gt;&lt;\/script&gt;\r\n&lt;script type=&quot;text\/javascript&quot;&gt;\r\nfunction Degistir()\r\n{\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;width&quot;,&quot;355px&quot;);\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;color&quot;,&quot;#C03&quot;);\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;border-style&quot;,&quot;ridge&quot;);\r\n\t\t$(&quot;.gorunumclass&quot;).css(&quot;font-size&quot;,&quot;24px&quot;);\r\n\t}\r\n&lt;\/script&gt;\r\n&lt;\/head&gt;\r\n&lt;body&gt;\r\n&lt;div class=&quot;gorunumclass&quot;&gt;Merhaba, J\u00fcpiter&lt;\/div&gt;\r\n&lt;span class=&quot;gorunumclass&quot;&gt;Merhaba, Sat\u00fcrn&lt;\/span&gt;\r\n&lt;div class=&quot;gorunumclass&quot;&gt;Merhaba, Uran\u00fcs&lt;\/div&gt;\r\n&lt;p class=&quot;gorunumclass&quot;&gt;Merhaba, Neett\u00fcn&lt;\/p&gt;\r\n&lt;input type=&quot;submit&quot; value=&quot;De\u011fi\u015ftir&quot; onclick=&quot;Degistir();&quot; \/&gt;\r\n&lt;\/body&gt;\r\n&lt;\/html&gt;\r\n<\/pre>\n<p>Burada da g\u00f6rd\u00fc\u011f\u00fcn\u00fcz gibi birden fazla &#8220;gorunumclass&#8221; Class de\u011ferine sahip nesnemiz mevcuttur.jQuery ile Class yap\u0131lar\u0131na m\u00fcdahale etti\u011fimiz i\u00e7in &#8220;Degistir&#8221; isimli fonksiyonumuz tetiklendi\u011fi zaman t\u00fcm &#8220;gorunumclass&#8221; Class de\u011ferine sahip HTML nesneleri(farkl\u0131 nesnelerde olsa) bu m\u00fcdahaleden etkileneceklerdir.<\/p>\n<p><a href=\"http:\/\/www.gencayyildiz.com\/blog\/jquery-bir-idnin-style-yapisina-mudahale\/\" target=\"_blank\">jQuery &#8211; Bir ID&#8217;nin Style Yap\u0131s\u0131na M\u00fcdahale<\/a> ba\u015fl\u0131kl\u0131 makalemizden hat\u0131rlarsan\u0131z e\u011fer, birden fazla ayn\u0131 id de\u011ferine sahip HTML nesneleri teknik olarak m\u00fcmk\u00fcn olamad\u0131\u011f\u0131ndan dolay\u0131 jQuery mimarisi ilk e\u015fle\u015fen id de\u011ferinin style yap\u0131s\u0131na m\u00fcdahale ediyordu.Anlatmak istedi\u011fim Class yap\u0131s\u0131nda b\u00f6yle bir durum s\u00f6z konusu de\u011fildir, bilakis t\u00fcm nesneler style de\u011fi\u015fikli\u011finden etkilenecektir.<\/p>\n<p>\u0130yi \u00e7al\u0131\u015fmalar dilerim&#8230;<\/p>\n<!-- AddThis Advanced Settings generic via filter on the_content --><!-- AddThis Share Buttons generic via filter on the_content -->","protected":false},"excerpt":{"rendered":"<p>\u00d6nceki yaz\u0131lar\u0131mda bir id ve tag\u0131n jQuery ile style yap\u0131s\u0131n\u0131n nas\u0131l de\u011fi\u015ftirildi\u011fini incelemi\u015ftik.\u015eimdi ise bir Class yap\u0131s\u0131n\u0131n style yap\u0131s\u0131n\u0131 de\u011fi\u015ftirmeyi inceleyece\u011fiz.<!-- AddThis Advanced Settings generic via filter on get_the_excerpt --><!-- AddThis Share Buttons generic via filter on get_the_excerpt --><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19],"tags":[68,748,595],"class_list":["post-2890","post","type-post","status-publish","format-standard","hentry","category-jquery","tag-class","tag-jquery","tag-style"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/posts\/2890","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/comments?post=2890"}],"version-history":[{"count":0,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/posts\/2890\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/media?parent=2890"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/categories?post=2890"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.gencayyildiz.com\/blog\/wp-json\/wp\/v2\/tags?post=2890"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}