<?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/"
><channel><title>Eliseos.net &#187; CSS</title> <atom:link href="http://eliseos.net/tag/css/feed/" rel="self" type="application/rss+xml" /><link>http://eliseos.net</link> <description>Wordpress, Diseño, jQuery and Coffee</description> <lastBuildDate>Fri, 03 Sep 2010 00:07:36 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" /> <item><title>Griddy: Un sistema de guias para tabajar grillas en CSS</title><link>http://eliseos.net/griddy-sistema-guias-tabajar-grillas-css/</link> <comments>http://eliseos.net/griddy-sistema-guias-tabajar-grillas-css/#comments</comments> <pubDate>Tue, 11 May 2010 18:49:36 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[grid]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2960</guid> <description><![CDATA[Griddy es un pequeño plugin para jQuery que nos permite superponer un griila (grid) por sobre encima de todos los elementos para facilitarnos la tarea de medir, centrar y observar cuando trabajamos en sistema de grilla (grid system)]]></description> <content:encoded><![CDATA[<p
style="text-align: left;"><a
title="Griddy: Simple Grid Overlay Plugin for JQuery" href="http://devgrow.com/griddy-overlay/">Griddy</a> es un pequeño plugin para <strong>jQuery</strong> que nos permite superponer un <strong>griila</strong> (grid) por sobre encima de todos los elementos para facilitarnos la tarea de medir, centrar y observar cuando trabajamos en sistema de grilla (<strong>grid system</strong>).</p><p
style="text-align: center;"><a
href="http://devgrow.com/griddy-overlay/"><img
class="alignnone size-full wp-image-2961" title="Griddy: Simple Grid Overlay Plugin for JQuery" src="http://eliseos.net/wp-content/uploads/2010/05/Griddy.jpg" alt="Griddy Griddy: Un sistema de guias para tabajar grillas en CSS" width="600" height="250" /></a></p><p><span
id="more-2960"></span></p><p
style="text-align: left;">El plugin es lo bastante inteligente como para poder calcular automáticamente el alto y ancho de cada columna y mostrar, como así también podemos controlar cada aspecto de la grilla, la cantidad de columnas, ancho, gutter, cantidad de celdas y todo lo necesario para poder adaptar el sistema a nuestra grilla.</p><p
style="text-align: left;">Quizás habrás que en el site de <strong>960.gs</strong> se encuentra un sistema similar a este plugin, donde podemos superponer guiás para comprender la grilla. Si bien cada grid system suele traer sus propias guiás, estas dependen al final de una imagen y CSS; y debemos andar rotando clases para habilitarlas o deshabilitarlas. Este sistema pretende hacernos la tarea mucho mas sencilla, ya que solo tenemos que hacer un click para traer nuestra guiá.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/griddy-sistema-guias-tabajar-grillas-css/feed/</wfw:commentRss> <slash:comments>1</slash:comments> </item> <item><title>Mas soporte en HTML5 para Internet Explorer</title><link>http://eliseos.net/mas-soporte-en-html5-para-internet-explorer/</link> <comments>http://eliseos.net/mas-soporte-en-html5-para-internet-explorer/#comments</comments> <pubDate>Fri, 16 Apr 2010 02:59:17 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[General]]></category> <category><![CDATA[CSS]]></category> <category><![CDATA[html5]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2870</guid> <description><![CDATA[Creo que no habia mencionado en Eliseos.net al script creado por Remy Sharp que nos permite utilizar todos los nuevos elementos que HTML5 trae consigo. El punto es que a la hora de diseñar con esta nueva tecnología]]></description> <content:encoded><![CDATA[<p
style="text-align: left;">Creo que no habia mencionado en Eliseos.net al <a
title="html5.js" href="http://remysharp.com/2009/01/07/html5-enabling-script/">script</a> creado por Remy Sharp que nos permite utilizar todos los nuevos elementos que <strong>HTML5</strong> trae consigo. El punto es que a la hora de diseñar con esta nueva tecnología y hacer uso de este script logramos <strong>casi</strong> una compatibilidad perfecta teniendo en vista Internet Explorer 6, 7 y 8. Digo <strong>casi</strong>, ya que hay un pequeño detalle que nos falta: Brindar soporte para IE dentro de HTML5 pensando en la <span
style="text-decoration: underline;">impresión</span>.</p><p
style="text-align: center;"><a
href="http://www.iecss.com/print-protector"><img
class="alignnone size-full wp-image-2871" title="IE Print Protector" src="http://eliseos.net/wp-content/uploads/2010/04/IE-Print-Protector.jpg" alt="IE Print Protector Mas soporte en HTML5 para Internet Explorer" width="500" height="250" /></a></p><p><span
id="more-2870"></span></p><p
style="text-align: left;">Como IE directamente no reconoce estos nuevos elementos (EJ: <em><code>&lt;section&gt;</code></em> o <em><code>&lt;article&gt;</code></em> que se utilizan en <strong>HTML5</strong>, mejor dicho, los reconoce pero no es capaz de cerrar cada elemento, por lo cual siempre quedan <strong>&#8220;vacios&#8221;</strong>. <a
title="IE Print Protector" href="http://www.iecss.com/print-protector">IE Print Protector</a> brinda el soporte necesario para renderizar estos nuevos elementos tanto en la pantalla como cuando nos trasladamos al papel.</p><p
style="text-align: left;">Cuando estamos trabajando con la pantalla, IE Print Protector utiliza el script mencionado en el principio, ahora cuando se trata del papel el script comienza a hacer su trabajo. En lugar de utilizar los nuevos elementos, lo que hace es <strong>reemplazarlos</strong> por digamos, con un <em><code>DIV</code></em> o un <em><code>SPAM</code></em>; para lograr una impresión perfecta, creando una nueva hoja de estilos tomando como base la hoja original.</p><p
style="text-align: left;">Si todavía no estas muy seguro si vale la pena implementar este script, te sugiero que veas el Demo donde se compara una hoja de impresión con el script implementado y otra pagina sin la implementación. Las diferencias, por lo que aclare más arriba son abismales.</p><p
style="text-align: left;">Como siempre lo digo, cuando se habla de usabilidad se habla de diseñar y armar pensando en el usuario final, nosotros podemos navegar y disponer de un sistema moderno y que sigue los <strong>estándares</strong>, pero los usuarios, puede que no. En definitiva lo que se trata (y siempre tiene que se así) es hacer que la <strong>experiencia</strong> del usuario sea de lo mas <strong>amigable</strong> posible.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/mas-soporte-en-html5-para-internet-explorer/feed/</wfw:commentRss> <slash:comments>2</slash:comments> </item> <item><title>Soporte en Internet Explorer 6, 7 y 8 para CSS3</title><link>http://eliseos.net/soporte-internet-explorer-6-7-8-css3/</link> <comments>http://eliseos.net/soporte-internet-explorer-6-7-8-css3/#comments</comments> <pubDate>Mon, 12 Apr 2010 20:27:55 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[Diseño]]></category> <category><![CDATA[CSS]]></category> <category><![CDATA[CSS3]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2836</guid> <description><![CDATA[Si venís siguiendo mis ultimas entradas habrás notado que mencionado varias veces como lograr una aproximación a la hora de ofrecer soporte a Internet Explorer cuando nos toca trabajar con ]]></description> <content:encoded><![CDATA[<p
style="text-align: left;">Si venís siguiendo mis ultimas entradas habrás notado que mencionado varias veces como lograr una aproximación a la hora de ofrecer soporte a Internet Explorer cuando nos toca trabajar con <strong>CSS3</strong>, como por ejemplo cuando hable de como &#8220;<a
title="Aplicar la propiedad transform Cross Browser" href="http://eliseos.net/?p=2787">Aplicar la propiedad transform Cross Browser</a>&#8221; o como aplicar &#8220;<a
title="Esquinas redondeadas en todos los navegadores" href="http://eliseos.net/?p=2756">Esquinas redondeadas en todos los navegadores</a>&#8220;.</p><p
style="text-align: center;"><img
src="http://eliseos.net/wp-content/uploads/2010/04/soporte-CSS3-para-Internet-Explorer.jpg" alt="soporte CSS3 para Internet Explorer Soporte en Internet Explorer 6, 7 y 8 para CSS3" title="CSS3 support for Internet Explorer 6, 7, and 8" width="500" height="250" class="alignnone size-full wp-image-2839" /></p><p><span
id="more-2836"></span></p><p
style="text-align: left;">Como en ocasiones anteriores vamos a necesitar un <a
title="CSS3 support for Internet Explorer 6, 7, and 8" href="http://fetchak.com/ie-css3/">archivo <strong>HTC</strong> </a>que en definitiva es lo que permite a que Internet Explorer reconozca algunas de las nuevas implementaciones que trae <strong>CSS3</strong>.</p><p
style="text-align: left;">Pero que propiedades se puede emular de esta forma, puedes que te permites. Por el momento son solo tres:</p><ul><li>border-radius</li><li>border-shadow</li><li>text-shadow</li></ul><h2>Implementación</h2><p
style="text-align: left;">Dentro de nuestra hoja de estilo trabajaremos como de costumbre, solo debemos prestar atención a la ultima linea:</p><div
class="wp_syntax"><div
class="code"><pre class="css" style="font-family:monospace;"><span style="color: #6666ff;">.box</span> <span style="color: #00AA00;">&#123;</span>
  -moz-border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">15px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* Firefox */</span>
  -webkit-border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">15px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* Safari y Chrome */</span>
  border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">15px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* Opera 10.5+ futuros navegadores y también IE6+ con IE-CSS3 */</span>
&nbsp;
  -moz-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">10px</span> <span style="color: #933;">10px</span> <span style="color: #933;">20px</span> <span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* Firefox */</span>
  -webkit-box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">10px</span> <span style="color: #933;">10px</span> <span style="color: #933;">20px</span> <span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* Safari y Chrome */</span>
  box-shadow<span style="color: #00AA00;">:</span> <span style="color: #933;">10px</span> <span style="color: #933;">10px</span> <span style="color: #933;">20px</span> <span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* Opera 10.5+ futuros navegadores y también IE6+ con IE-CSS3 */</span>
&nbsp;
  behavior<span style="color: #00AA00;">:</span> <span style="color: #993333;">url</span><span style="color: #00AA00;">&#40;</span>ie-css3.htc<span style="color: #00AA00;">&#41;</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* Define el comportamiento de los nuevas propiedades para IE*/</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div><p
style="text-align: left;">Como lo podemos observar de esta forma cada elemento con la <em><code>class box</code></em> ahora lucirá algunas de las nuevas propiedades cuando se lo visualice en Internet Explorer.</p><h2>Limitaciones y Problemas</h2><p
style="text-align: left;">No todo es color de rosa cunado trabajamos con IE. Por el momento hay un problema que surge al aplicar este <strong>hack</strong> que implica a <em><code>z-index</code></em>, por lo que nuestro nuevo elemento puede lucir por encima o por debajo de otros si no se toman los recaudos posibles.</p><p
style="text-align: left;">Solo debemos darle a nuestro elemento un <em><code>z-index</code></em> mayor a los demás elementos o definir su posición como <em><code>position: relative</code></em> o <em><code>position: absolute</code></em></p><p
style="text-align: left;">También debemos tener en cuenta que hay ciertas reglas que no se comportan de manera uniforme. Por ejemplo, no podemos definir un <em><code>border radius</code></em> individualmente, es decir 5px arriba a la derecha, 20 abajo a la izquierda, etc. Tampoco podemos usar una sombra en <em><code>box-shadow</code></em> con un valor en #000 (negro).</p><p
style="text-align: left;">Sacando estas limitaciones, creo que es una buena de lograr una mejor aproximación a CSS3, por lo menos hasta que la nueva versión de Internet este disponible.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/soporte-internet-explorer-6-7-8-css3/feed/</wfw:commentRss> <slash:comments>5</slash:comments> </item> <item><title>Consejos para diseñar pensando en Ipad</title><link>http://eliseos.net/consejos-disenar-pensando-ipad/</link> <comments>http://eliseos.net/consejos-disenar-pensando-ipad/#comments</comments> <pubDate>Tue, 06 Apr 2010 23:51:56 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[Destacadas]]></category> <category><![CDATA[Diseño]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2826</guid> <description><![CDATA[Con la salida del Ipad a los diseñadores Web se nos ha encomendado otra tarea: Hacer un Site compatible para este nuevo dispositivo, como ya lo hicimos para Iphone y otros dispositivos]]></description> <content:encoded><![CDATA[<p
style="text-align: left;">Con la salida del <strong>Ipad</strong> a los diseñadores Web se nos ha encomendado otra tarea: Hacer un Site compatible para este nuevo dispositivo, como ya lo hicimos para <strong>Iphone</strong> y otros dispositivos. Seguramente te estarás preguntando, <strong>es realmente necesario adaptar el día de hoy mi sitio a este nuevo dispositivo?</strong> Las respuestas pueden ser variadas por el SÍ o por el NO.</p><p
style="text-align: center;"><img
class="alignnone size-full wp-image-2827" title="Ipad" src="http://eliseos.net/wp-content/uploads/2010/04/ipad.jpg" alt="ipad Consejos para diseñar pensando en Ipad" width="500" height="250" /></p><p
style="text-align: left;">Tengamos en cuenta que en el mercado hispano la incidencia del Ipad no sera notable hasta (me animaría a decir) en un par de años. Al día de hoy solo se han despachado cerca de 300.000 dispositivos, por lo que esta incidencia global es mínima.</p><p
style="text-align: left;">Por otro lado esta la <strong>usabilidad</strong>, esa palabrita que tanto molesta (a varios). No hay nada mas frustrante que entrar a una pagina con X navegador o dispositivo y tener que hacer malabares para poder leer una entrada. Es aquí donde diseñar <em>user-friendly</em> trae sus méritos: Brindar soporte para la mayoría de los navegadores y dispositivos (en este caso).</p><h2>Aspectos técnicos de Ipad</h2><p
style="text-align: left;">Ipad cuenta con una resolución de <strong>1024&#215;768</strong> en <em>landscape</em> y con su respectiva resolución al rotarlo. Lo cual es un punto a nuestro favor, ya que la mayoría diseñamos Sites teniendo en cuenta esta resolución de pantalla.</p><p
style="text-align: left;">Otra cosa muy importante que debemos saber, que Ipad, como su hermanito Iphone no soportan Flash. Se acuerdan cuando decía que teníamos que alejarnos lo más posible de esta tecnología? Bueno, si me hicieron caso, esto no nos demandara mayor esfuerzo alguno, ya que no usamos Flash. Pero si no me hiciste caso y estas trabajando en Flash, es un buen momento para que te hagas amigo de <em><code>HTML5</code></em> <em><code>CSS3</code></em> y <em><code>Javascript</code></em></p><h2>Primeros pasos</h2><p
style="text-align: left;">Si diseñaste tu sitio siguiendo las practicas modernas: <em><code>XHTML</code></em>, <em><code>CSS3</code></em>, <em><code>HTML5</code></em>,etc. probablemente no tengas que arreglar nada ya que tu sitio es perfectamente amigable. Lo único que debes tener en cuenta es el ancho de tu <em>container</em> principal, que no debe exceder el viewport de Ipad. Muchos de nosotros nos guiamos trabajando con un sistema de grilla, donde nuestro <em><code>container</code></em> es de <strong>960px</strong>, pixeles mas pixeles menos.</p><p
style="text-align: left;">Tambien tenemos que tener mucho cauidado al usar al propiedad <em><code>position:fixed</code></em> dado que no se comporta de manera <strong>uniforme</strong> dentro de Safari</p><h2>Ipad y la orientacion</h2><p
style="text-align: left;">Aquí es donde comienzan los primeros dolores de cabezas, son pequeños, pero dolores al fin. Al ser un dispositivo que permite rotación de pantalla, tenemos que tratar a Ipad como dos dispositivos completamente distintos, <strong>pero iguales</strong>. Como hacemos esto? Fácil, con lo que se llaman <strong>CSS3 media queries</strong>, para aplicar distintas reglas dentro de una misma hoja de estilo con <em><code>@media</code></em> o haciendo una llamada condicional dentro de nuestro header.</p><p
style="text-align: left;">Usando el método <em><code>@media</code></em>, dentro de nuestra hoja de estilo podemos hacer el siguiente markup</p><div
class="wp_syntax"><div
class="code"><pre class="css" style="font-family:monospace;"><span style="color: #a1a100;">@media only screen and (max-width: 999px) {</span>
  <span style="color: #808080; font-style: italic;">/* aquí reglas donde el ancho es menor a 1000px */</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #a1a100;">@media only screen and (device-width: 768px) and (orientation: landscape) {</span>
  <span style="color: #808080; font-style: italic;">/* reglas para Ipad en modo landscape (768px) */</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #a1a100;">@media only screen and (min-device-width: 320px) and (max-device-width: 480px) {</span>
  <span style="color: #808080; font-style: italic;">/* reglas iPhone, Android y otros dispositivos */</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div><p
style="text-align: left;">Estos condicionales indican que si se trata de un agente donde su viewport es menor a 1000px (Ipad en landscape) se aplique las reglas dentro de esta <em><code>querie</code></em>. De tratarse de un agente con un viewport de 768px (Ipad en su rotacion para este ejemplo), esas reglas, y el mismo procedimiento para dispositivos donde el width es igual o menor a 320px.</p><p
style="text-align: left;">De esta forma nos aseguramos de brindar un estilo determinado para cada viewport.</p><h2>Recursos</h2><p
style="text-align: left;">Si no dispones de Ipad tenemos un par de opciones para <strong>emular</strong> este dispositivo en nuestro escritorio. Una de las formas mas simple es dirigirnos a <strong><a
title="Ipadpeek" href="http://ipadpeek.com/">Ipadpeek</a></strong> e ingresar la dirección de nuestro sitio y tendremos una idea de como se ve nuestro sitios, junto con la opción de rotar el dispositivo.</p><p
style="text-align: left;">Otra forma más completa y recomendable a la hora de diseñar pensando en Ipad, es cambiar nuestro <em><code>user agent</code></em>, es decir que el navegador que estamos utilizando nos reconozca como si estuviéramos navegando con Ipad.</p><p
style="text-align: left;">El <em><code>user agent</code></em> para Ipad es el siguiente</pre><div
class="wp_syntax"><div
class="code"><pre class="text" style="font-family:monospace;">Mozilla/5.0 (iPad; U; CPU OS 3_2 like Mac OS X; en-us) AppleWebKit/531.21.10 (KHTML, like Gecko) Version/4.0.4 Mobile/7B334b Safari/531.21.10</pre></div></div><p
style="text-align: left;">Dentro de <strong>Safari</strong> solo tenemos que crear un nuevo <em>user agent</em> con los datos brindados mas arriba, desde la pestaña de Desarrollo. Y en el caso de <strong>Firefox</strong> podemos usar el plugin <strong><a
title="User Agent Switcher" href="https://addons.mozilla.org/es-ES/firefox/addon/59">User Agent Switcher</a></strong> para lograr la emulación.</p><h2>Links recomendados</h2><p>Si queres leer un poco sobre este tema, te dejo los siguientes links donde encontraras mucha información para desarrollar pensado en Ipad.</p><ul><li><a
title="Detecting device size &amp; orientation in CSS" href="http://mislav.uniqpath.com/2010/04/targeted-css/">Detecting device size &amp; orientation in CSS</a></li><li><a
title="Preparing Your Web Content for iPad" href="http://developer.apple.com/safari/library/technotes/tn2010/tn2262.html">Preparing Your Web Content for iPad</a></li><li><a
title="User Experience Coding How-To's for Safari on iPhone" href="http://developer.apple.com/safari/library/codinghowtos/Mobile/UserExperience/index.html">User Experience Coding How-To's for Safari on iPhone</a></li><li><a
title="iPad Orientation CSS" href="http://www.cloudfour.com/ipad-orientation-css/">iPad Orientation CSS </a></li></ul><p
style="text-align: left;">Espero que encuentren esta información útil y se animen a comenzar a diseñar pensando en las tecnologías del día de hoy</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/consejos-disenar-pensando-ipad/feed/</wfw:commentRss> <slash:comments>3</slash:comments> </item> <item><title>Condicionales para IE6/IE7 con solo 2 caracteres</title><link>http://eliseos.net/condicionales-internet-explorer-2-caracteres/</link> <comments>http://eliseos.net/condicionales-internet-explorer-2-caracteres/#comments</comments> <pubDate>Wed, 31 Mar 2010 22:58:24 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[hack]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2812</guid> <description><![CDATA[Todos sabemos lo doloroso que es diseñar teniendo en mente a Internet Explorer en todas sus aberraciones versiones. Al diseñar casi siempre tenemos que recurrir a un condicional para mostrar un estilo o hack]]></description> <content:encoded><![CDATA[<p
style="text-align: left;">Todos sabemos lo doloroso que es diseñar teniendo en mente a <strong>Internet Explorer</strong> en todas sus <span
style="text-decoration: line-through;">aberraciones</span> versiones. Al diseñar casi siempre tenemos que recurrir a un condicional para mostrar un estilo o <strong>hack</strong> predeterminado para cada versión de Internet Explorer.</p><p
style="text-align: left;">El siguiente es un pequeño <strong>hack</strong> que nos permite con tan solo dos caracteres extras indicar un condicional para Internet Explorer, tanto para su versión 6 y 7.<span
id="more-2812"></span></p><h2>En tu hoja de estilo podemos añadir:</h2><div
class="wp_syntax"><div
class="code"><pre class="css" style="font-family:monospace;"><span style="color: #cc00cc;">#mi_elemento</span> <span style="color: #00AA00;">&#123;</span>  
   <span style="color: #000000; font-weight: bold;">background</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">red</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* navegadores modernos */</span>  
   <span style="color: #00AA00;">*</span><span style="color: #000000; font-weight: bold;">background</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">green</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* IE 7 y anteriores */</span>  
   _background<span style="color: #00AA00;">:</span> <span style="color: #993333;">yellow</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* IE6 solamente */</span>  
<span style="color: #00AA00;">&#125;</span></pre></div></div><p
style="text-align: left;">Lo bueno de este método es que no es necesario generar otra hoja de estilo para Internet Explorer y usar un condicional. Lo malo, es que estos dos caracteres no permitirán validar tu hoja de estilo, por lo que queda en vos el utilizar esta forma o seguir trabajando de la manera clásica.</p><p
style="text-align: left;">Si bien este hack apareció en <a
title="Quick Tip: How to Target IE6 and IE7 with Only Two Characters" href="http://net.tutsplus.com/videos/screencasts/quick-tip-how-to-target-ie6-and-ie7-with-only-two-characters/">Nettus</a> hace unas cuantas semanas, siempre es bueno hacer un recordatorio.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/condicionales-internet-explorer-2-caracteres/feed/</wfw:commentRss> <slash:comments>4</slash:comments> </item> <item><title>Menu en el Footer al estilo Tumblr (Update)</title><link>http://eliseos.net/menu-footer-estilo-tumblr/</link> <comments>http://eliseos.net/menu-footer-estilo-tumblr/#comments</comments> <pubDate>Tue, 23 Mar 2010 07:04:48 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[jQuery]]></category> <category><![CDATA[hack]]></category> <category><![CDATA[menu]]></category> <category><![CDATA[Tumblr]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2792</guid> <description><![CDATA[Hoy quería compartir una técnica muy sencilla pero muy poco implementada. Asumo que alguno de ustedes son usuarios de esa Maravillosa plataforma, de Tumblr, por supuesto estoy hablando]]></description> <content:encoded><![CDATA[<p
style="text-align: left;">Hoy quería compartir una técnica muy sencilla pero muy poco implementada. Asumo que alguno de ustedes son usuarios de esa Maravillosa plataforma, de <strong>Tumblr</strong>, por supuesto estoy hablando. Cuando nos encontramos en el <strong>Dashboard</strong> en el <em>footer</em> se encuentra un menú que solo es visible cuando posicionamos el <strong>mouse</strong> sobre él.</p><p
style="text-align: center;"><a
href="http://eliseos.net/test/tumblr_footer/"><img
src="http://eliseos.net/wp-content/uploads/2010/03/tumblr_menu.jpg" alt="tumblr menu Menu en el Footer al estilo Tumblr (Update)" title="Menu en el Footer al estilo Tumblr" width="500" height="250" class="alignnone size-full wp-image-2796" /></a></p><p
style="text-align: left;">A mi entender es un técnica muy buena para cuando disponemos de muy poco espacio y queremos añadir un poco más de funcionalidad a nuestro diseño.</p><h2>Demo</h2><p
style="text-align: left;">Antes de empezar quizás quieras<a
href="http://eliseos.net/test/tumblr_footer/" title="Menu en el Footer al estilo Tumblr"> mirar un poco lo que vamos a crear</a>,  el demo para este ejemplo es bien sencillo y contundente.</p><h2>Introducción</h2><p
style="text-align: left;">Como ya lo remarque anteriormente esta es una técnica de lo mas sencilla que no te dará mayores complicaciones. Este footer al que hago referencia, se encuentra potenciado por jQuery (solo unas pocas lineas) y CSS.</p><h2>Markup</h2><p
style="text-align: left;">Para este ejemplo, me encuentro trabajando con una grilla, pero vos podes utilizarlo dentro de tu diseño sin problemas. La única parte que debe llamar tu atención es el footer que es lo que vamos a construir.  Para esto he creado el siguiente markup solo focalizandome en el footer</p><div
class="wp_syntax"><div
class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;footer&quot;</span>&gt;</span>
    <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;row container&quot;</span>&gt;</span>
      <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">ul</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;column grid_12&quot;</span>&gt;</span>
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">strong</span>&gt;</span><span style="color: #ddbb00;">&amp;copy;</span> Tumblr, Inc.<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">strong</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>Help<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>About<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">title</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;Tumblr Themes&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>Themes<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>Meetups<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>What's New<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>API<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>Content Policy<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>Terms of Service<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
&nbsp;
        <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>Privacy Policy<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
      <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">ul</span>&gt;</span>
    <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></div></div><p
style="text-align: left;">En este caso he decido llamar el <em><code>container</code></em> footer, esto queda en vos, lo único importante es que debe ser el ultimo bloque antes de la etiqueta <em><code>body</code></em> para que el efecto funcione correctamente.</p><h2>CSS</h2><p
style="text-align: left;">Daré por sentado que ya sabemos como trabajar con listas y como darles formato, y pasare al bloque más importante</p><div
class="wp_syntax"><div
class="code"><pre class="css" style="font-family:monospace;"><span style="color: #cc00cc;">#footer</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#fff</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">font</span><span style="color: #00AA00;">:</span><span style="color: #933;">11px</span> <span style="color: #ff0000;">'Lucida Grande'</span><span style="color: #00AA00;">,</span>Verdana<span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">font-weight</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">700</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-align</span><span style="color: #00AA00;">:</span><span style="color: #993333;">center</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">line-height</span><span style="color: #00AA00;">:</span><span style="color: #933;">80px</span><span style="color: #00AA00;">;</span><span style="color: #808080; font-style: italic;">/* centramos el texto verticalmente */</span>
<span style="color: #000000; font-weight: bold;">height</span><span style="color: #00AA00;">:</span><span style="color: #933;">56px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">background</span><span style="color: #00AA00;">:</span><span style="color: #993333;">url</span><span style="color: #00AA00;">&#40;</span><span style="color: #ff0000;">&quot;../images/gradient.png&quot;</span><span style="color: #00AA00;">&#41;</span> <span style="color: #993333;">repeat-x</span> <span style="color: #993333;">scroll</span> <span style="color: #993333;">center</span> <span style="color: #000000; font-weight: bold;">bottom</span> <span style="color: #993333;">transparent</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">background</span><span style="color: #00AA00;">:</span><span style="color: #993333;">url</span><span style="color: #00AA00;">&#40;</span><span style="color: #ff0000;">&quot;../images/gradient.png&quot;</span><span style="color: #00AA00;">&#41;</span> <span style="color: #993333;">repeat-x</span> <span style="color: #993333;">scroll</span> <span style="color: #993333;">center</span> <span style="color: #000000; font-weight: bold;">bottom</span> <span style="color: #cc00cc;">#fbfbfb</span>\<span style="color: #cc66cc;">9</span><span style="color: #00AA00;">;</span><span style="color: #808080; font-style: italic;">/* Hack para IE8 y below */</span>
<span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span><span style="color: #993333;">fixed</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* footer siempre visible */</span>
<span style="color: #000000; font-weight: bold;">bottom</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* footer siempre al pie */</span>
<span style="color: #000000; font-weight: bold;">width</span><span style="color: #00AA00;">:</span><span style="color: #933;"><span style="color: #cc66cc;">100</span>%</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* 100% del viewport */</span>
<span style="color: #000000; font-weight: bold;">text-shadow</span><span style="color: #00AA00;">:</span><span style="color: #933;">1px</span> <span style="color: #933;">1px</span> <span style="color: #933;">2px</span> <span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* sombras a modo de detalle */</span>
opacity<span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* nunca visible hasta activar el hover */</span>
filter<span style="color: #00AA00;">:</span>alpha<span style="color: #00AA00;">&#40;</span>opacity<span style="color: #00AA00;">=</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">&#41;</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* ocultar visibilidad en IE */</span>
<span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div><p
style="text-align: left;">Como veras el código esta fuertemente comentado, lo único relevante es que estamos usando la posición <em><code>fixed</code></em> para que nuestro bloque este siempre visible y <em><code>bottom</code></em> en 0 para que se ubique al pie siempre. Luego liberamos cualquier margin que podamos haber heredado.</p><h2>Update</h2><p
style="text-align: left;"> Con la nueva versión de jQuery este efecto comenzó a mostrar incompatibilidades con IE. He incluido dos pequeños hacks en el CSS:</p><ul><li> Tenemos que añadir un color de fondo en nuestro #footer para que IE pueda interpretar correctamente las transparencias.</li><li> Añadimos el filter:alpha() para que el DIV quede oculto en IE</li></ul><p
style="text-align: left;">Como siempre IE no reconoce las propiedades <em>text-shadow</em> por lo que vas a tener que usar al hack extra, ya he hablado aqui de como brindar <a
href="http://eliseos.net/?p=2836">soporte en Internet Explorer 6, 7 y 8 para CSS3</a></p><h2>jQuery</h2><p
style="text-align: left;">Como siempre la magia para el final. Lo que vamos a buscar es que el bloque este siempre oculto (anteriormente lo ocultamos en nuestro CSS) y que al posicionar el mouse sobre él este se muestre con un bonito efecto.</p><div
class="wp_syntax"><div
class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>$<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	$.<span style="color: #660066;">fn</span>.<span style="color: #660066;">customFadeOut</span> <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>speed<span style="color: #339933;">,</span> callback<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		$<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">fadeTo</span><span style="color: #009900;">&#40;</span>speed<span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>jQuery.<span style="color: #660066;">browser</span>.<span style="color: #660066;">msie</span><span style="color: #009900;">&#41;</span>
				$<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">get</span><span style="color: #009900;">&#40;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">style</span>.<span style="color: #660066;">removeAttribute</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'filter'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			<span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>callback <span style="color: #339933;">!=</span> undefined<span style="color: #009900;">&#41;</span>
				callback<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span><span style="color: #006600; font-style: italic;">// jQuery fadeIn/fadeOut IE cleartype glitch by Benjamin Michael Novakovic</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#40;</span>jQuery<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #006600; font-style: italic;">//estamos listos?.</span>
$<span style="color: #009900;">&#40;</span>document<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">ready</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
 $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;div#footer&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">mouseover</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
		$<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span><span style="color: #009900;">&#41;</span>.<span style="color: #000066;">stop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">fadeTo</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;slow&quot;</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">1.0</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">mouseout</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
		$<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span><span style="color: #009900;">&#41;</span>.<span style="color: #000066;">stop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">fadeTo</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;slow&quot;</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">0.0</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div><h2>Update</h2><p
style="text-align: left;">Por la misma discrepancia entre IE y Jquery, es necesario añadir una nueva funcion para IE pueda interpretar el <strong>fading</strong> que estamos añadiendo. Esta maravillosa función es una ocurrencia de <a
href="http://blog.bmn.name/2008/03/jquery-fadeinfadeout-ie-cleartype-glitch/">Benjamin Michael Novakovic</a>.</p><p
style="text-align: left;"> Cuando se hace <em><code>hover</code></em> la visibilidad del bloque se degrada desde 0 a 100 para lograr un lindo efecto. Esta es la pieza final de este pequeño rompecabezas</p><h2>Consideraciones Finales</h2><p
style="text-align: left;">EL contenido del bloque puede ser casi cualquiera, un guía de navegación, algunos anuncios de texto, lo que necesites incluir. Espero que este mini tutorial les sea de utilidad, cualquier duda no tienen mas que preguntar</p><h2> Descarga</h2><p
style="text-align: left;">Si lo necesitas pongo a tu disposición los archivos necesarios para que trabajes localmente: <a
class="downloadlink" href="http://eliseos.net/downloads/tumblr_footer.zip" title="Version1.1 downloaded 1 times" >Tumblr Footer (1)</a></p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/menu-footer-estilo-tumblr/feed/</wfw:commentRss> <slash:comments>9</slash:comments> </item> <item><title>Crea una barra para compartir tus entradas al estilo Mashable</title><link>http://eliseos.net/crea-barra-compartir-entradas-estilo-mashable/</link> <comments>http://eliseos.net/crea-barra-compartir-entradas-estilo-mashable/#comments</comments> <pubDate>Mon, 15 Mar 2010 20:16:31 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[Destacadas]]></category> <category><![CDATA[jQuery]]></category> <category><![CDATA[hack]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2761</guid> <description><![CDATA[Ayer me preguntaban si conocía algún plugin o al por estilo para poder emular el comportamiento de la barra horizontal que acompaña a los post en Mashable. Esta barra se "mueve" a lo largo de la entrada acompañando al scroll y en la que se encuentran botones para]]></description> <content:encoded><![CDATA[<p
style="text-align: left;">Ayer me preguntaban si conocía algún plugin o al por estilo para poder emular el comportamiento de la barra horizontal que acompaña a los post en <a
href="http://mashable.com/">Mashable</a>. Esta barra se &#8220;mueve&#8221; a lo largo de la entrada acompañando al scroll y en la que se encuentran botones para socializar contenido, como ser Tweetmeme, Facebook, etc.</p><p
style="text-align: center;"><img
src="http://eliseos.net/wp-content/uploads/2010/03/mashable.jpg" alt="mashable Crea una barra para compartir tus entradas al estilo Mashable" title="mashable" width="500" height="250" class="alignnone size-full wp-image-2763" /></p><p><span
id="more-2761"></span></p><p
style="text-align: left;">Sinceramente nunca le había prestado demasiada atención a esa barra, por la que me puse a investigar un poco mas sobre su comportamiento y como funciona. Después de mirar un poco pude recrear el efecto sin demasiadas complicaciones con un poco de CSS y jQuery.</p><p
style="text-align: left;">Surgieron dos alternativas, la replica exacta (solo me tome el trabajo de explicar el código) de Mashable y otro un poco mas simple.</p><p
style="text-align: center;"><img
src="http://eliseos.net/wp-content/uploads/2010/03/Social-bar-al-estilo-Mashable.png" alt="Social bar al estilo Mashable Crea una barra para compartir tus entradas al estilo Mashable" title="Social bar al estilo Mashable" width="500" height="250" class="alignnone size-full wp-image-2762" /></p><p
style="text-align: left;">Si entramos a cualquier post en Mashable, veremos que la barra se acompaña al Scroll sin animaciones. Al usar valores negativos en el <em><code>margin</code></em>, esta barra no es visible en resoluciones menores (1024), por lo cual mediante <strong>jQuery </strong>se transforma en otra barra horizontal para mostrar el contenido; lo mismo sucede si redimencionamos la ventana.</p><p
style="text-align: left;">La alternativa mas simple ofrece las mismas funcionalidades y un efecto en el <em>scroll</em>, pero si te excedes en el <strong>viewport</strong>, los visitantes que tengan una resolución de pantalla menor, no podrán apreciarla. A que me refiero con el exceso en el <strong>viewport</strong>? Simple, si tu <em><code>container</code> </em>es de <strong>960px</strong> de ancho y posicionamos la barra a unos <strong>-80px</strong>, <strong>nos excedimos en el viewport</strong> (960px + 80px = 1040) para resoluciones menores o iguales a 1024&#215;768; ya que el <strong>safe area</strong> para esta resolución es de <strong>975px</strong> de ancho.</p><p
style="text-align: left;">Cualquiera de las dos alternativas es válida y funcional, queda en vos utilizar la que creas que mejor se adapte.</p><h2>Replica de Mashable</h2><p
style="text-align: left;">Esta opción requiere un poco mas de código dada la complejidad. Al utilizar la posición <em><code>fixed</code></em>, esta opción no sera compatible con <strong>IE6 </strong>ya que este navegador desconoce esta propiedad.</p><h3><a
href="http://eliseos.net/test/easy/demo1.html">Demo Replica de Mashable</a></h3><p
style="text-align: left;">No te olvides de redimensionar la ventana para apreciar el efecto completo</p><h2>HTML</h2><p
style="text-align: left;">Como lo podemos apreciar en Mashable tenemos botones para sindicar contenido en Twitter, Google Buzz, Facebook y otras. Cada botón funciona por medio de un <em>script </em>para que les sea mas sencillo de integrar, podes usar e incluir los botones que necesitas por medio de algún plugin o simple código, eso queda en vos.</p><div
class="wp_syntax"><div
class="code"><pre class="html4strict" style="font-family:monospace;">			<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;social_bar&quot;</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;botones_grandes&quot;</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;gbuzz s_boton&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://button.njuice.com/buzz.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;tweetmeme s_boton&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
//<span style="color: #009900;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #009900;">tweetmeme_source <span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'baires'</span>; <span style="color: #66cc66;">//</span> Mi usuario en Twitter <span style="color: #66cc66;">//</span></span>
<span style="color: #009900;">tweetmeme_url <span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'&lt;?php the_permalink(); ?&gt;</span></span>'; // URL a socializar en este caso para Wordpress //
//]]&gt;
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://tweetmeme.com/i/scripts/button.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;faceboook s_boton&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://widgets.fbshare.me/files/fbshare.js&quot;</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;botones_chicos&quot;</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton_small gbuzz_small&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
//<span style="color: #009900;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #009900;">var njuice_buzz_size <span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'small'</span>;</span>
<span style="color: #009900;"><span style="color: #66cc66;">//</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://button.njuice.com/buzz.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton_small twwetmeme_small&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
//<span style="color: #009900;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #009900;">tweetmeme_style <span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'compact'</span>;</span>
<span style="color: #009900;"><span style="color: #66cc66;">//</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://tweetmeme.com/i/scripts/button.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton_small facebook_small&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
//<span style="color: #009900;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #009900;">var fbShare <span style="color: #66cc66;">=</span> <span style="color: #66cc66;">&#123;</span></span>
<span style="color: #009900;"><span style="color: #000066;">size</span>: <span style="color: #ff0000;">'small'</span>,</span>
<span style="color: #009900;"><span style="color: #66cc66;">&#125;</span></span>
<span style="color: #009900;"><span style="color: #66cc66;">//</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://widgets.fbshare.me/files/fbshare.js&quot;</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton_small&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">target</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;_blank&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://feedburner.google.com/fb/a/mailverify?uri=EliseosNet&amp;amp;loc=es_ES&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_email&quot;</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;social_sprites&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_email&quot;</span>&gt;</span>email<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton_small&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;a2a_dd social_sprites&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_share&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.addtoany.com/share_save?linkname=Eliseos%20Net&amp;amp;linkurl=eliseos.net&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_sharethis&quot;</span>&gt;</span>Share<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
//<span style="color: #009900;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #009900;">a2a_linkname<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;My Sitio&quot;</span>;a2a_linkurl<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;mi-url.com&quot;</span>;</span>
<span style="color: #009900;"><span style="color: #66cc66;">//</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://static.addtoany.com/menu/page.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton&quot;</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">target</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;_blank&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://feedburner.google.com/fb/a/mailverify?uri=EliseosNet&amp;amp;loc=es_ES&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_email&quot;</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;social_sprites&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_email&quot;</span>&gt;</span>email<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton&quot;</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;a2a_dd social_sprites&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_share&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.addtoany.com/share_save?linkname=My%20Sitio&amp;amp;linkurl=mi-url.com&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_sharethis&quot;</span>&gt;</span>Share<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
//<span style="color: #009900;">&lt;!<span style="color: #66cc66;">&#91;</span>CDATA<span style="color: #66cc66;">&#91;</span></span>
<span style="color: #009900;">a2a_linkname<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;My Sitio&quot;</span>;a2a_linkurl<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;mi-url.com&quot;</span>;</span>
<span style="color: #009900;"><span style="color: #66cc66;">//</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#93;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://static.addtoany.com/menu/page.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
			<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></div></div><p
style="text-align: left;">Nuestro <strong>markup </strong>es de lo mas sencillo, como se puede hay dos clases de botones: grandes y chicos. Los botones grandes son los que se aprecian a simple vista, los chicos se encuentran escondidos para las resoluciones inferiores o en caso de redimensioanarse la pantalla. Es necesario que edites los datos de cada botón para que coincida con los tuyos, en URL, Nombre del Sitio, etc.</p><p
style="text-align: left;">Recomiendo introducir la barra justo después del titulo y antes del contendido para poder desplazarnos sin problemas. Para el caso de WordPress dentro del archivo <em><code>single.php</code></em></p><h2>CSS</h2><p
style="text-align: left;">Esto es parte de la magia, otra vez es algo extremadamente simple de entender. Intente comentar lo mas posible el código para que sea de fácil entendimiento.</p><div
class="wp_syntax"><div
class="code"><pre class="css" style="font-family:monospace;">&nbsp;
<span style="color: #cc00cc;">#social_bar</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background</span><span style="color: #3333ff;">:<span style="color: #993333;">none</span> </span>repeat <span style="color: #993333;">scroll</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc00cc;">#FFFFFF</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">border</span><span style="color: #00AA00;">:</span><span style="color: #933;">1px</span> <span style="color: #993333;">solid</span> <span style="color: #cc00cc;">#DDDDDD</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">float</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">margin-left</span><span style="color: #00AA00;">:</span><span style="color: #933;">-80px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* // La distacia de la barra que queremos tener en relacion al post */</span>
<span style="color: #000000; font-weight: bold;">margin-right</span><span style="color: #00AA00;">:</span><span style="color: #933;">10px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span><span style="color: #993333;">relative</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #808080; font-style: italic;">/* // Formato de los Botones grandes */</span>
<span style="color: #6666ff;">.s_boton</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #933;">5px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">clear</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #808080; font-style: italic;">/* // Formato de los Botones chicos */</span>
.s_boton_small<span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">clear</span><span style="color: #00AA00;">:</span><span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">float</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #933;">5px</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #808080; font-style: italic;">/* // Ocultamos los botones chicos de momento */</span>
<span style="color: #6666ff;">.botones_chicos</span><span style="color: #00AA00;">&#123;</span><span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span><span style="color: #993333;">none</span><span style="color: #00AA00;">;</span><span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #808080; font-style: italic;">/* //Iconos para los links de Share y Email */</span>
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #cc00cc;">#s_email</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">2px</span> <span style="color: #933;">-32px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #3333ff;">:hover</span><span style="color: #cc00cc;">#s_email</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">2px</span> <span style="color: #933;">-50px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#4c545b</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #cc00cc;">#s_share</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">0px</span> <span style="color: #933;">4px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #3333ff;">:hover</span><span style="color: #cc00cc;">#s_share</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">0px</span> <span style="color: #933;">-14px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#4c545b</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
-moz-border-radius<span style="color: #00AA00;">:</span><span style="color: #933;">3px</span> <span style="color: #933;">3px</span> <span style="color: #933;">3px</span> <span style="color: #933;">3px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">background</span><span style="color: #00AA00;">:</span><span style="color: #993333;">url</span><span style="color: #00AA00;">&#40;</span><span style="color: #ff0000; font-style: italic;">../images/social_sprites.png</span><span style="color: #00AA00;">&#41;</span> <span style="color: #993333;">no-repeat</span> <span style="color: #993333;">scroll</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc00cc;">#FFFFFF</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">border</span><span style="color: #00AA00;">:</span><span style="color: #933;">1px</span> <span style="color: #993333;">solid</span> <span style="color: #cc00cc;">#E8E8E8</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#989898</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span><span style="color: #993333;">block</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">font</span><span style="color: #00AA00;">:</span><span style="color: #933;">9px</span>/<span style="color: #cc66cc;">1.625</span> verdana<span style="color: #00AA00;">,</span><span style="color: #993333;">sans-serif</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #933;">2px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-align</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">right</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">width</span><span style="color: #00AA00;">:</span><span style="color: #933;">44px</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div><p
style="text-align: left;">En caso que lo necesites <a
href="http://eliseos.net/wp-content/uploads/2010/03/social_sprites.png">esta es la imagen</a> que utilice en los links de <em>share </em>&amp; <em>e-mail</em>. Los iconos pertenecen al set <a
href="http://glyphish.com/">Glyphish</a>.</p><h2>jQuery</h2><p
style="text-align: left;">Y aquí viene la magia que hará que el comportamiento de la barra acompañe al <em>scroll </em>y diferencie las distintas resoluciones de pantalla.</p><div
class="wp_syntax"><table><tr><td
class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
</pre></td><td
class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>	
&nbsp;
    <span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#social_bar'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">length</span> <span style="color: #339933;">&gt;</span> <span style="color: #CC0000;">0</span> <span style="color: #339933;">&amp;&amp;</span> <span style="color: #339933;">!</span><span style="color: #009900;">&#40;</span>$.<span style="color: #660066;">browser</span>.<span style="color: #660066;">msie</span> <span style="color: #339933;">&amp;&amp;</span> parseInt<span style="color: #009900;">&#40;</span>$.<span style="color: #660066;">browser</span>.<span style="color: #660066;">version</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&lt;</span> <span style="color: #CC0000;">7</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #003366; font-weight: bold;">var</span> descripY <span style="color: #339933;">=</span> parseInt<span style="color: #009900;">&#40;</span>$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.main'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">offset</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">top</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">-</span> <span style="color: #CC0000;">20</span><span style="color: #339933;">;</span>
        <span style="color: #003366; font-weight: bold;">var</span> $postShare <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#social_bar'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #003366; font-weight: bold;">var</span> pullX <span style="color: #339933;">=</span> $postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'margin-left'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">data</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'scrollBound'</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">false</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
        <span style="color: #003366; font-weight: bold;">function</span> positionShareScroll<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
            <span style="color: #003366; font-weight: bold;">var</span> scrollY <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">scrollTop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
            <span style="color: #003366; font-weight: bold;">var</span> fixedShare <span style="color: #339933;">=</span> $postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'position'</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> <span style="color: #3366CC;">'fixed'</span><span style="color: #339933;">;</span>
            <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span> scrollY <span style="color: #339933;">&gt;</span> descripY <span style="color: #339933;">&amp;&amp;</span> <span style="color: #339933;">!</span>fixedShare <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                $postShare.<span style="color: #000066;">stop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>
                    position<span style="color: #339933;">:</span> <span style="color: #3366CC;">'fixed'</span><span style="color: #339933;">,</span>
                    left<span style="color: #339933;">:</span> <span style="color: #3366CC;">'50%'</span><span style="color: #339933;">,</span>
                    top<span style="color: #339933;">:</span> <span style="color: #CC0000;">20</span><span style="color: #339933;">,</span>
                    marginLeft<span style="color: #339933;">:</span> <span style="color: #339933;">-</span><span style="color: #CC0000;">540</span> <span style="color: #006600; font-style: italic;">// Este valor se debe ajustar ya que depende de cada diseño//</span>
                <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
            <span style="color: #009900;">&#125;</span> <span style="color: #000066; font-weight: bold;">else</span> <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span> scrollY <span style="color: #339933;">&lt;</span> descripY <span style="color: #339933;">&amp;&amp;</span> fixedShare <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                $postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>
                    position<span style="color: #339933;">:</span> <span style="color: #3366CC;">'relative'</span><span style="color: #339933;">,</span>
                    left<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span><span style="color: #339933;">,</span>
                    top<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span><span style="color: #339933;">,</span>
                    marginLeft<span style="color: #339933;">:</span> pullX
                <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
            <span style="color: #009900;">&#125;</span>
        <span style="color: #009900;">&#125;</span>
&nbsp;
&nbsp;
        $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">resize</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
            <span style="color: #003366; font-weight: bold;">var</span> windowW <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">width</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
            <span style="color: #003366; font-weight: bold;">var</span> pulledOutside <span style="color: #339933;">=</span> $postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'margin-left'</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> pullX<span style="color: #339933;">;</span>
            <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span> windowW <span style="color: #339933;">&gt;=</span> <span style="color: #CC0000;">1137</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #339933;">!</span>$<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">data</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'scrollBound'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                    <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #339933;">!</span>pulledOutside <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                        $postShare.<span style="color: #660066;">animate</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span> marginLeft<span style="color: #339933;">:</span> pullX <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						<span style="color: #006600; font-style: italic;">//Crear barra Vertical</span>
						$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.botones_chicos'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">hide</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.s_boton'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">show</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.botones_grandes'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">show</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						$postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'border-width'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'1px'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						$postShare.<span style="color: #660066;">width</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'auto'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						$postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>
							marginRight<span style="color: #339933;">:</span> <span style="color: #CC0000;">7</span><span style="color: #339933;">,</span>
							marginTop<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span>
						<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                    <span style="color: #009900;">&#125;</span>
                    $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>
                        .<span style="color: #660066;">data</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'scrollBound'</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #660066;">bind</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'scroll.positionShare'</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
                            positionShareScroll<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
                        <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span>
                    <span style="color: #339933;">;</span>
                    positionShareScroll<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                <span style="color: #009900;">&#125;</span>
            <span style="color: #009900;">&#125;</span> <span style="color: #000066; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span>
                <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span> pulledOutside <span style="color: #339933;">||</span> $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">data</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'scrollBound'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                    $postShare
                        .<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span> position<span style="color: #339933;">:</span> <span style="color: #3366CC;">'relative'</span><span style="color: #339933;">,</span> left<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span><span style="color: #339933;">,</span> top<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span> <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #660066;">animate</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>marginLeft<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span>
                    <span style="color: #339933;">;</span>
					<span style="color: #006600; font-style: italic;">//Crear barra Horizontal</span>
					<span style="color: #006600; font-style: italic;">//$postShare.append(smallButtons);</span>
					<span style="color: #006600; font-style: italic;">//smallButtons = '';</span>
					$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.botones_grandes'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">hide</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.s_boton'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">hide</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
					$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.botones_chicos'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">show</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					$postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>
						marginTop<span style="color: #339933;">:</span> <span style="color: #CC0000;">5</span><span style="color: #339933;">,</span>
						marginBottom<span style="color: #339933;">:</span> <span style="color: #CC0000;">5</span>
					<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					$postShare.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'border-width'</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
					<span style="color: #003366; font-weight: bold;">var</span> content_width <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.main'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">width</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>content_width <span style="color: #339933;">==</span> <span style="color: #3366CC;">'undefined'</span><span style="color: #009900;">&#41;</span> content_width <span style="color: #339933;">=</span> <span style="color: #CC0000;">600</span><span style="color: #339933;">;</span>
					<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span> $postShare.<span style="color: #660066;">attr</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'_width'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
						$postShare.<span style="color: #660066;">width</span><span style="color: #009900;">&#40;</span>$postShare.<span style="color: #660066;">attr</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'_width'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						<span style="color: #003366; font-weight: bold;">var</span> block_width <span style="color: #339933;">=</span> $postShare.<span style="color: #660066;">attr</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'_width'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					<span style="color: #009900;">&#125;</span> <span style="color: #000066; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span>
						$postShare.<span style="color: #660066;">attr</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'_width'</span><span style="color: #339933;">,</span> $postShare.<span style="color: #660066;">width</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
						<span style="color: #003366; font-weight: bold;">var</span> block_width <span style="color: #339933;">=</span> $postShare.<span style="color: #660066;">width</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					<span style="color: #009900;">&#125;</span>
					$postShare.<span style="color: #660066;">width</span><span style="color: #009900;">&#40;</span>content_width<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					<span style="color: #003366; font-weight: bold;">var</span> add_padding <span style="color: #339933;">=</span> <span style="color: #009900;">&#40;</span> <span style="color: #009900;">&#40;</span>content_width <span style="color: #339933;">-</span> block_width<span style="color: #009900;">&#41;</span> <span style="color: #339933;">/</span> <span style="color: #009900;">&#40;</span>$postShare.<span style="color: #660066;">find</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.s_boton_small'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">length</span> <span style="color: #339933;">*</span> <span style="color: #CC0000;">2</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> <span style="color: #CC0000;">4</span><span style="color: #339933;">;</span>
&nbsp;
					<span style="color: #006600; font-style: italic;">//var add_padding = (642 - (88 + 120 * (buttons_count - 2) )) / (buttons_count * 2);</span>
					<span style="color: #006600; font-style: italic;">//var add_padding = ( ( 642 - ( 88 * buttons_count ) ) / (buttons_count * 2) ) + 5;</span>
					$postShare.<span style="color: #660066;">find</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.s_boton_small'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>
						paddingLeft<span style="color: #339933;">:</span> add_padding<span style="color: #339933;">,</span>
						paddingRight<span style="color: #339933;">:</span> add_padding
					<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
&nbsp;
                    $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>
                        .<span style="color: #660066;">data</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'scrollBound'</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">false</span><span style="color: #009900;">&#41;</span>
                        .<span style="color: #660066;">unbind</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'scroll.positionShare'</span><span style="color: #009900;">&#41;</span>
                    <span style="color: #339933;">;</span>
                <span style="color: #009900;">&#125;</span>
            <span style="color: #009900;">&#125;</span>
        <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">resize</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div><p
style="text-align: left;">Solamente dos cosas debemos tener presentes, la primera es definir en la linea 4 cual sera nuestro valor de referencia para el comportamiento de la barra, es decir el ancho; generalmente corresponde al <em><code>container</code> </em>en el que se encuentra el post. En mi caso he utilizado la clase <em><code>main</code></em>, que se vuelve a utilizar en la linea <strong>76 </strong>y en la <strong>77 </strong>con su ancho.</p><p
style="text-align: left;">Luego procederemos a adaptar la distancia a la que se posicionara la barra cuando nos desplacemos, al utilizar la posición <em><code>fixed</code></em>, el valor difiere de los 80px originales. Este ejemplo muestra la barra posicionada a unos -540px (linea 18). Este valor tenes que ajustarlo vos ya que depende de tu diseño. Una aproximación a este numero responde a: <strong>Ancho del container (en este ejemplo: main) &#8211;  80px</strong></p><p
style="text-align: left;">Una vez presentadas todas las partes solo tenemos que integrarlas en nuestro Site, dependiendo de la plataforma con lo que estemos trabajando pude variar algún detalle, pero este código sirve tanto para WordPress como para cualquier otro <strong>CMS</strong>.</p><h2>Replica de Mashable Simple</h2><p
style="text-align: left;">A diferencia de la opción anterior esta barra es <strong>compatible </strong>con <strong>IE6</strong>, pero no podrá ser apreciada en resoluciones menores. El <em>scroll </em>para este caso es una animación del <em><code>padding</code> </em>que produce un simpático efecto final.</p><h3><a
href="http://eliseos.net/test/easy/demo2.html">Demo Replica de Mashable</a></h3><h2>HTML</h2><p
style="text-align: left;">Es casi el mismo <em>markup </em>de la primera opción pero sin incluir los botones pequeños ya que no son necesarios.</p><div
class="wp_syntax"><div
class="code"><pre class="html4strict" style="font-family:monospace;">	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;social_bar_wrapper&quot;</span>&gt;</span>
			<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;social_bar&quot;</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;botones_contenedor&quot;</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;gbuzz s_boton&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://button.njuice.com/buzz.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;tweetmeme s_boton&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
tweetmeme_source = 'baires';
tweetmeme_url = '<span style="color: #009900;">&lt;?php the_permalink<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>; ?&gt;</span>';
&nbsp;
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://tweetmeme.com/i/scripts/button.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;faceboook s_boton&quot;</span>&gt;</span>
						<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://widgets.fbshare.me/files/fbshare.js&quot;</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton&quot;</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">target</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;_blank&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://feedburner.google.com/fb/a/mailverify?uri=EliseosNet&amp;amp;loc=es_ES&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_email&quot;</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;social_sprites&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_email&quot;</span>&gt;</span>email<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_boton&quot;</span>&gt;</span>
					<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;a2a_dd social_sprites&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_share&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.addtoany.com/share_save?linkname=My%20Sitio&amp;amp;linkurl=mi-url.com&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;s_sharethis&quot;</span>&gt;</span>Share<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
a2a_linkname=&quot;My Sitio&quot;;a2a_linkurl=&quot;mi-url.com&quot;;
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://static.addtoany.com/menu/page.js&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
				<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
			<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
		<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></div></div><p
style="text-align: left;">También se ha añadido un <em><code>wrapper</code></em>a la barra para poder controlar el <em><code>margin</code></em>.</p><h2>CSS</h2><p
style="text-align: left;">Es exactamente el mismo de la primera opción, con el adicional de <em><code>wrapper</code> </em> y sin los botones pequeños.</p><div
class="wp_syntax"><div
class="code"><pre class="css" style="font-family:monospace;"><span style="color: #cc00cc;">#social_bar_wrapper</span><span style="color: #00AA00;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">absolute</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">margin-top</span><span style="color: #00AA00;">:</span><span style="color: #933;">20px</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background</span><span style="color: #3333ff;">:<span style="color: #993333;">none</span> </span>repeat <span style="color: #993333;">scroll</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc00cc;">#FFFFFF</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">border</span><span style="color: #00AA00;">:</span><span style="color: #933;">1px</span> <span style="color: #993333;">solid</span> <span style="color: #cc00cc;">#DDDDDD</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">float</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">margin-left</span><span style="color: #00AA00;">:</span><span style="color: #933;">-80px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* // La distancia de la barra que queremos tener en relacion al post */</span>
<span style="color: #000000; font-weight: bold;">margin-right</span><span style="color: #00AA00;">:</span><span style="color: #933;">10px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span><span style="color: #993333;">relative</span><span style="color: #00AA00;">;</span>
&nbsp;
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #808080; font-style: italic;">/* // Formato de los Botones grandes */</span>
<span style="color: #6666ff;">.s_boton</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #933;">5px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">clear</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #808080; font-style: italic;">/* //Iconos para los links de Share y Email */</span>
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #cc00cc;">#s_email</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">2px</span> <span style="color: #933;">-32px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #3333ff;">:hover</span><span style="color: #cc00cc;">#s_email</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">2px</span> <span style="color: #933;">-50px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#4c545b</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #cc00cc;">#s_share</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">0px</span> <span style="color: #933;">4px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #3333ff;">:hover</span><span style="color: #cc00cc;">#s_share</span><span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
<span style="color: #000000; font-weight: bold;">background-position</span><span style="color: #00AA00;">:</span><span style="color: #933;">0px</span> <span style="color: #933;">-14px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#4c545b</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-decoration</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#social_bar</span> a<span style="color: #6666ff;">.social_sprites</span> <span style="color: #00AA00;">&#123;</span>
-moz-border-radius<span style="color: #00AA00;">:</span><span style="color: #933;">3px</span> <span style="color: #933;">3px</span> <span style="color: #933;">3px</span> <span style="color: #933;">3px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">background</span><span style="color: #00AA00;">:</span><span style="color: #993333;">url</span><span style="color: #00AA00;">&#40;</span><span style="color: #ff0000; font-style: italic;">../images/social_sprites.png</span><span style="color: #00AA00;">&#41;</span> <span style="color: #993333;">no-repeat</span> <span style="color: #993333;">scroll</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc66cc;">0</span> <span style="color: #cc00cc;">#FFFFFF</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">border</span><span style="color: #00AA00;">:</span><span style="color: #933;">1px</span> <span style="color: #993333;">solid</span> <span style="color: #cc00cc;">#E8E8E8</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#989898</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span><span style="color: #993333;">block</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">font</span><span style="color: #00AA00;">:</span><span style="color: #933;">9px</span>/<span style="color: #cc66cc;">1.625</span> verdana<span style="color: #00AA00;">,</span><span style="color: #993333;">sans-serif</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #933;">2px</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">text-align</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">right</span><span style="color: #00AA00;">;</span>
<span style="color: #000000; font-weight: bold;">width</span><span style="color: #00AA00;">:</span><span style="color: #933;">44px</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div><p
style="text-align: left;">Quizás lo único que tengas que modificar es la distancia a la que se encuentra la barra con respecto del contenido, para este ejemplo es -80px (dentro de <em><code>#social_bar</code></em>). No te excedas en mas de <strong>-100px </strong>o no sera visible en varias resoluciones.</p><h2>jQuery</h2><p
style="text-align: left;">Como te lo adelante anteriormente solamente animamos el <em><code>padding</code> </em>(gracias <a
href="http://css-tricks.com/scrollfollow-sidebar/">CSS Tricks</a>), no es necesario modificar este código a no ser que sepas lo que estas haciendo.</p><div
class="wp_syntax"><table><tr><td
class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
</pre></td><td
class="code"><pre class="javascript" style="font-family:monospace;">	$<span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #003366; font-weight: bold;">var</span> $sidebar   <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;#social_bar&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
        $window    <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
        offset     <span style="color: #339933;">=</span> $sidebar.<span style="color: #660066;">offset</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
        topPadding <span style="color: #339933;">=</span> <span style="color: #CC0000;">15</span><span style="color: #339933;">;</span>
&nbsp;
    $window.<span style="color: #000066;">scroll</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>$window.<span style="color: #660066;">scrollTop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&gt;</span> offset.<span style="color: #660066;">top</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
            $sidebar.<span style="color: #000066;">stop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">animate</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>
                marginTop<span style="color: #339933;">:</span> $window.<span style="color: #660066;">scrollTop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">-</span> offset.<span style="color: #660066;">top</span> <span style="color: #339933;">+</span> topPadding
            <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span> <span style="color: #000066; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span>
            $sidebar.<span style="color: #000066;">stop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">animate</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>
                marginTop<span style="color: #339933;">:</span> <span style="color: #CC0000;">0</span>
            <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span>
    <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div><h2> Bug encontrado</h2><p
style="text-align: left;">No la había notado la semana pasada, pero me lo remarcan en un e-mail, al contar con un contenido &#8220;muy&#8221; largo; la barra empuja ciertas secciones dentro del container en el que introducimos la barra. Una opción es cambiar a un container mas &#8220;chico&#8221; (poco practico) o para esas secciones problemáticas que se desplazan tenes que usar la regla: <em><code>display: inline-block</code></em></p><p
style="text-align: left;"> Al añadir esta nueva regla, veras que todos los problemas se solucionan, el único inconveniente que se genera, es que <em><code>display: inline-block</code></em> no se comporta de manera homogénea en IE por lo que tendríamos que trabajar un poco más. Pero eso es tema para cortar otra tela, por ahora lo dejo como un pendiente.</p><h2>Consideraciones finales</h2><p
style="text-align: left;">Por ultimo solo resta presentar todo en nuestro diseño y tendremos otra alternativa a a barra de Mashable.</p><p
style="text-align: left;">Cualquier duda que tengas, hacémelo saber.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/crea-barra-compartir-entradas-estilo-mashable/feed/</wfw:commentRss> <slash:comments>9</slash:comments> </item> <item><title>Speech bubbles con CSS solamente</title><link>http://eliseos.net/speech-bubbles-css-solamente/</link> <comments>http://eliseos.net/speech-bubbles-css-solamente/#comments</comments> <pubDate>Wed, 10 Mar 2010 01:02:32 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[CSS3]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2747</guid> <description><![CDATA[Nicolas Gallagher ha creado una serie de Speech bubbles solamente con CSS2.1 y condimentados con CSS3, logrando asi algo que solo se podría obtener mediante javascript]]></description> <content:encoded><![CDATA[<p
style="text-align: left;"><a
title="Pure CSS speech bubbles" href="http://nicolasgallagher.com/progressive-enhancement-pure-css-speech-bubbles/">Nicolas Gallagher</a> ha creado una serie de Speech bubbles solamente con <strong>CSS2.1</strong> y condimentados con <strong>CSS3</strong>, logrando así algo que solo se podria obtener mediante <strong>javascript</strong>. Usando un HTML semántico y cero imágenes se pueden lograr resultados como el siguiente:</p><p><span
id="more-2747"></span></p><p
style="text-align: center;"><a
href="http://nicolasgallagher.com/progressive-enhancement-pure-css-speech-bubbles/"><img
class="alignnone size-full wp-image-2748" title="CSS Speech bubbles" src="http://eliseos.net/wp-content/uploads/2010/03/CSS-Speech-bubbles.jpg" alt="CSS Speech bubbles Speech bubbles con CSS solamente" width="500" height="250" /></a></p><p
style="text-align: left;">El HTML del que les hablaba es muy simple, solamente podemos escribir <em><code>&lt;div&gt;Content&lt;/div&gt;</code></em> o <em><code>&lt;p&gt;Content&lt;/p&gt;</code></em> y la magia de CSS se hará cargo de ahí en mas.</p><p
style="text-align: left;">La mención honorifica se la llevan los <strong>pseudo-elements</strong> <em><code>:before</code></em> y/o <em><code>:after</code></em> que crearan nuestras formas (Speech bubbles) y las propiedades <em><code>border-radius</code></em> y <em><code>transform</code></em> son los condimentos.</p><p
style="text-align: left;">Si nos ponemos a trabajar con los <strong>pseudo-elements</strong> y las propiedades arriba mencionadas podemos lograr resultado muy interesantes.</p><p
style="text-align: left;">Un ejemplo de esto, puede ser este CSS donde se creara un Speech Bubble con un triangulo isoceles en la parte inferior</p><div
class="wp_syntax"><div
class="code"><pre class="css" style="font-family:monospace;"><span style="color: #808080; font-style: italic;">/* Bubble con triangulo isósceles
------------------------------------------ */</span>
&nbsp;
<span style="color: #6666ff;">.triangle-isosceles</span> <span style="color: #00AA00;">&#123;</span>
   <span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span><span style="color: #993333;">relative</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #933;">15px</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #933;">1em</span> <span style="color: #cc66cc;">0</span> <span style="color: #933;">3em</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">background</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#f3961c</span><span style="color: #00AA00;">;</span>
&nbsp;
   <span style="color: #808080; font-style: italic;">/* css3 */</span>
   -moz-border-radius<span style="color: #00AA00;">:</span><span style="color: #933;">10px</span><span style="color: #00AA00;">;</span>
   -webkit-border-radius<span style="color: #00AA00;">:</span><span style="color: #933;">10px</span><span style="color: #00AA00;">;</span>
   border-radius<span style="color: #00AA00;">:</span><span style="color: #933;">10px</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">background</span><span style="color: #3333ff;">:-moz-linear-</span>gradient<span style="color: #00AA00;">&#40;</span><span style="color: #000000; font-weight: bold;">top</span><span style="color: #00AA00;">,</span> <span style="color: #cc00cc;">#f9d835</span><span style="color: #00AA00;">,</span> <span style="color: #cc00cc;">#f3961c</span><span style="color: #00AA00;">&#41;</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">background</span><span style="color: #3333ff;">:linear-</span>gradient<span style="color: #00AA00;">&#40;</span><span style="color: #000000; font-weight: bold;">top</span><span style="color: #00AA00;">,</span> <span style="color: #cc00cc;">#f9d835</span><span style="color: #00AA00;">,</span> <span style="color: #cc00cc;">#f3961c</span><span style="color: #00AA00;">&#41;</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #808080; font-style: italic;">/* crear triangulo */</span>
<span style="color: #6666ff;">.triangle-isosceles</span><span style="color: #3333ff;">:after </span><span style="color: #00AA00;">&#123;</span>
   <span style="color: #000000; font-weight: bold;">content</span><span style="color: #00AA00;">:</span><span style="color: #ff0000;">&quot;<span style="color: #000099; font-weight: bold;">\0</span>0a0&quot;</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span><span style="color: #993333;">block</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* reduce the damage in FF3.0 */</span>
   <span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span><span style="color: #993333;">absolute</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">z-index</span><span style="color: #00AA00;">:</span>-<span style="color: #cc66cc;">1</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">bottom</span><span style="color: #00AA00;">:</span><span style="color: #933;">-30px</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">:</span><span style="color: #933;">50px</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">width</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">height</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">border-width</span><span style="color: #00AA00;">:</span><span style="color: #933;">15px</span> <span style="color: #933;">15px</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">border-style</span><span style="color: #00AA00;">:</span><span style="color: #993333;">solid</span><span style="color: #00AA00;">;</span>
   <span style="color: #000000; font-weight: bold;">border-color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#f3961c</span> <span style="color: #993333;">transparent</span> <span style="color: #993333;">transparent</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div><p
style="text-align: left;">Dentro del demo podras observar el comportamiento y acceder a todo el CSS necesario para que puedas ver en detalle como funciona cada shape y así poder implementarlas o crear shapes propias.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/speech-bubbles-css-solamente/feed/</wfw:commentRss> <slash:comments>8</slash:comments> </item> <item><title>CSS personalizado para cada entrada en WordPress</title><link>http://eliseos.net/css-personalizado-entrada-wordpress/</link> <comments>http://eliseos.net/css-personalizado-entrada-wordpress/#comments</comments> <pubDate>Mon, 08 Feb 2010 22:39:41 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[Wordpress]]></category> <category><![CDATA[CSS]]></category> <category><![CDATA[hack]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2655</guid> <description><![CDATA[Como todos lo sabemos Wordpress es muy flexible y con él podemos hacer casi cualquier cosa, en esta ocasión en particular vamos a crear un Box para poder estilizar nuestras entradas por medio de ]]></description> <content:encoded><![CDATA[<p
style="text-align: left;">Como todos lo sabemos WordPress es muy flexible y con él podemos hacer casi cualquier cosa, en esta ocasión en particular vamos a crear un Box para poder estilizar nuestras entradas por medio de CSS.</p><p
style="text-align: center;"><img
class="alignnone size-full wp-image-2656" title="Custom CSS en Wordpess" src="http://eliseos.net/wp-content/uploads/2010/02/Custom-CSS.jpg" alt="Custom CSS CSS personalizado para cada entrada en Wordpress" width="500" height="250" /></p><p><span
id="more-2655"></span></p><p
style="text-align: left;">Como lo sabrás cada Theme tiene su propia hoja de estilos que es lo que le formato en definitiva. Si necesitáramos personalizar nuestras entradas, tendríamos que editar la hoja de estilos del Theme; cosa que puede ser algo molesto si solo necesitamos personalizar una entrada en concreto.</p><p
style="text-align: left;">Con esta pequeña función, estaremos añadiendo un Box para que la hora de crear un Post o Pagina podamos insertar un estilo para cada entrada/pagina en concreto.</p><p
style="text-align: left;">Por medio de filtros y acciones esta función insertar en el header de nuestro Theme, el estilo que le hayamos aplicados. Solo tenes que cerciorarte que Theme cuente con <em><code>wp_head();</code></em> dentro del Header.</p><h2>Uso</h2><p
style="text-align: left;">En tu archivo <em><code>functions.php</code></em> inserta lo siguiente:</p><div
class="wp_syntax"><div
class="code"><pre class="php" style="font-family:monospace;"> <span style="color: #666666; font-style: italic;">//Custom CSS </span>
add_action<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'admin_menu'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'custom_css_hooks'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
add_action<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'save_post'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'save_custom_css'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
add_action<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'wp_head'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'insert_custom_css'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">function</span> custom_css_hooks<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	add_meta_box<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'custom_css'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'Custom CSS'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'custom_css_input'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'post'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'normal'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'high'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	add_meta_box<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'custom_css'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'Custom CSS'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'custom_css_input'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'page'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'normal'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'high'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">function</span> custom_css_input<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$post</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'&lt;input type=&quot;hidden&quot; name=&quot;custom_css_noncename&quot; id=&quot;custom_css_noncename&quot; value=&quot;'</span><span style="color: #339933;">.</span>wp_create_nonce<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'custom-css'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&quot; /&gt;'</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'&lt;textarea name=&quot;custom_css&quot; id=&quot;custom_css&quot; rows=&quot;5&quot; cols=&quot;30&quot; style=&quot;width:100%;&quot;&gt;'</span><span style="color: #339933;">.</span>get_post_meta<span style="color: #009900;">&#40;</span><span style="color: #000088;">$post</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ID</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'_custom_css'</span><span style="color: #339933;">,</span><span style="color: #009900; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/textarea&gt;'</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">function</span> save_custom_css<span style="color: #009900;">&#40;</span><span style="color: #000088;">$post_id</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span>wp_verify_nonce<span style="color: #009900;">&#40;</span><span style="color: #000088;">$_POST</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'custom_css_noncename'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'custom-css'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #000088;">$post_id</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">defined</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'DOING_AUTOSAVE'</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&amp;&amp;</span> DOING_AUTOSAVE<span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #000088;">$post_id</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$custom_css</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_POST</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'custom_css'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
	update_post_meta<span style="color: #009900;">&#40;</span><span style="color: #000088;">$post_id</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'_custom_css'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$custom_css</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">function</span> insert_custom_css<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>is_page<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">||</span> is_single<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>have_posts<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> <span style="color: #b1b100;">while</span> <span style="color: #009900;">&#40;</span>have_posts<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> the_post<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'&lt;style type=&quot;text/css&quot;&gt;'</span><span style="color: #339933;">.</span>get_post_meta<span style="color: #009900;">&#40;</span>get_the_ID<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'_custom_css'</span><span style="color: #339933;">,</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/style&gt;'</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">endwhile</span><span style="color: #339933;">;</span> <span style="color: #b1b100;">endif</span><span style="color: #339933;">;</span>
		rewind_posts<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">//End Custom CSS</span></pre></div></div><p
style="text-align: left;">Ahora cada vez que escribas una entrada/pagina encontraras este box para insertar tus estilos:</p><p
style="text-align: center;"><img
class="alignnone size-full wp-image-2657" title="Custom CSS Box en WordPress" src="http://eliseos.net/wp-content/uploads/2010/02/Custom-CSS-Box.jpg" alt="Custom CSS Box CSS personalizado para cada entrada en Wordpress" width="500" height="250" /></p><p
style="text-align: left;">Como lo veras esta función es bastante flexible por lo sera posible adaptarla, para por ejemplo también poder incluir <em><code>scripts</code></em> en nuestro Header.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/css-personalizado-entrada-wordpress/feed/</wfw:commentRss> <slash:comments>4</slash:comments> </item> <item><title>Markercss: un potente Framework para maquetar CSS</title><link>http://eliseos.net/markercss-potente-framework-maquetar-css/</link> <comments>http://eliseos.net/markercss-potente-framework-maquetar-css/#comments</comments> <pubDate>Mon, 25 Jan 2010 22:58:54 +0000</pubDate> <dc:creator>Alexis</dc:creator> <category><![CDATA[CSS]]></category> <category><![CDATA[framework]]></category><guid
isPermaLink="false">http://eliseos.net/?p=2613</guid> <description><![CDATA[Markercss es una forma de maquetar Diseños ganando tiempo al usar este Framework. Cuando se maqueta un sitio tenemos que crear y recordar todos nuestros estilos]]></description> <content:encoded><![CDATA[<p
style="text-align: left;"><a
title="Markercss" href="http://www.markercss.com/">Markercss</a> es una forma de maquetar Diseños ganando tiempo al usar este Framework. Cuando se maqueta un sitio tenemos que crear y recordar todos nuestros estilos. Aquí es cuando Markercss entra en accion.</p><p
style="text-align: center;"><a
href="http://www.markercss.com/"><img
src="http://eliseos.net/wp-content/uploads/2010/01/Markercss.jpg" alt="Markercss Markercss: un potente Framework para maquetar CSS" title="Markercss" width="500" height="250" class="alignnone size-full wp-image-2614" /></a></p><p><span
id="more-2613"></span></p><p
style="text-align: left;">Este Framework utiliza referencias simples de recordar y lógicas, por ejemplo; si necesitáramos crear un <em><code>DIV</em></code> de un height de 700px y un width de 500px, solo haríamos referencia a esta clase:</p><div
class="wp_syntax"><div
class="code"><pre class="html" style="font-family:monospace;">&lt;div class=”rl w500 h700”&gt;
    &lt;div class=”rl w50 h70”&gt;&lt;/div&gt;
&lt;/div&gt;</pre></div></div><p
style="text-align: left;">Otro punto fuerte es el hecho de que Markercss se encuentra sub-dividido en distintos temas para una mejor compresión y aplicación: bordes, fondos, links, etc.</p><p
style="text-align: left;">Como lo habrás notado los CSS Framework son cada vez mas comunes y potentes, hay opiniones encontradas a favor y en contra de ellos, pero en definitiva están aquí para quedarse.</p> ]]></content:encoded> <wfw:commentRss>http://eliseos.net/markercss-potente-framework-maquetar-css/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> </channel> </rss>
<!-- Served from: eliseos.net @ 2010-09-03 15:36:36 by W3 Total Cache -->