This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //author csa | |
| jQuery.fn.equalHeight = function(tab){ | |
| try{ | |
| var elemHeight = new Array(); | |
| $(this).each(function() { | |
| altura = $(this).outerHeight(true); | |
| elemHeight.push(altura); | |
| }); | |
| var maior = elemHeight.sort(function(a,b){return a - b}).slice(-1); | |
| $(this).css({height: maior + "px"}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $.getQuerystring = function(key, default_) { | |
| if (default_ == null) default_ = ""; | |
| key = key.replace(/[\[]/, "\\\[").replace(/[\]]/, "\\\]"); | |
| var regex = new RegExp("[\\?&]" + key + "=([^&#]*)"); | |
| var qs = regex.exec(decodeURIComponent(window.location.href)); | |
| if (qs == null) | |
| return default_; | |
| else | |
| return qs[1]; | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // from http://lasnv.net/ | |
| <script type="text/javascript"> | |
| function youtube_parser(url){ | |
| var regExp = /^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/; | |
| var match = url.match(regExp); | |
| if (match&&match[7].length==11){ | |
| return match[7]; | |
| }else{ | |
| alert("Url incorrecta"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var zoomOri = document.documentElement.clientWidth / window.innerWidth; | |
| var zoomCurrent = zoomOri; | |
| $(window).resize(function() { | |
| var zoomNew = document.documentElement.clientWidth / window.innerWidth; | |
| if (zoomOri != zoomNew && zoomNew != zoomCurrent) { | |
| $('.yourclass').hide(); | |
| } else if (zoomOri == zoomNew && zoomNew != zoomCurrent) { | |
| $('.yourclass').show(); | |
| } | |
| zoomCurrent = zoomNew |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # The following will allow you to use URLs such as the following: | |
| # | |
| # example.com/link | |
| # example.com/link/ | |
| # | |
| # Which will actually serve files such as the following: | |
| # | |
| # example.com/link.html | |
| # example.com/link.php | |
| # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*! normalize.css 2012-02-07T12:37 UTC - http://github.com/necolas/normalize.css */article,aside,details,figcaption,figure,footer,header,hgroup,nav,section,summary{display:block}audio,canvas,video{display:inline-block;*display:inline;*zoom:1}audio:not([controls]){display:none}[hidden]{display:none}html{font-size:100%;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}html,button,input,select,textarea{font-family:sans-serif}body{margin:0}a:focus{outline:thin dotted}a:hover,a:active{outline:0}h1{font-size:2em;margin:.67em 0}h2{font-size:1.5em;margin:.83em 0}h3{font-size:1.17em;margin:1em 0}h4{font-size:1em;margin:1.33em 0}h5{font-size:.83em;margin:1.67em 0}h6{font-size:.75em;margin:2.33em 0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:bold}blockquote{margin:1em 40px}dfn{font-style:italic}mark{background:#ff0;color:#000}p,pre{margin:1em 0}pre,code,kbd,samp{font-family:monospace,serif;_font-family:'courier new',monospace;font-size:1em}pre{white-space:pre;white-space:pre-wrap;word-wrap:break-word |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $('.el').each(function() { | |
| var string = $(this).html(); | |
| $(this).html(string.replace(/,/g , ', ')); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //add_filter( 'media_send_to_editor', 'inserted_image_titles', 15, 2 ); | |
| function featured_image_titles($attr, $attachment = null){ | |
| $attr['title'] = get_post($attachment->ID)->post_title; | |
| return $attr; | |
| } | |
| add_filter('wp_get_attachment_image_attributes', 'featured_image_titles', 10, 2); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php get_header(); ?> | |
| <?php | |
| query_posts('post_type=page'); | |
| while(have_posts() ) : the_post(); | |
| endwhile; | |
| ?> | |
| <?php | |
| $className = 'section1'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(document).click(function(e){ | |
| if ($(e.target).parents('.el').length === 0) { | |
| $('.el').fadeOut(); | |
| } | |
| }); |
OlderNewer