Ver Mensaje Individual
  #12 (permalink)  
Antiguo 09/11/2011, 11:34
Avatar de rogertm
rogertm
Mod->Cuba
 
Fecha de Ingreso: julio-2005
Ubicación: /home/Cuba/Habana/rogertm/
Mensajes: 2.922
Antigüedad: 18 años, 9 meses
Puntos: 638
Respuesta: Asignar ID a Thumbnails

A ver, yo dije eso porque tú lo quieres poner allí:
Cita:
Este es el Orbit original:

<div id="featured">
<img src="overflow.jpg" alt="Overflow: Hidden No More" />
<img src="captions.jpg" alt="HTML Captions" data-caption="#htmlCaption" />
<img src="features.jpg" alt="and more features" />
</div>
<!-- Captions for Orbit -->
<span class="orbit-caption" id="htmlCaption">I'm A Badass Caption</span>

----------------------------------------
Revisando caí en cuenta y NO es el atributo id sino:

data-caption="#Aquí si el id del post"

(Anteponiéndole el signo numeral dentro de comillas...)

Ejemplo:

data-caption="#Aquí si el id del post"
Pero luego me di cuenta que estás usando un plugin, y es mejor no tocar ese código, a no ser que sepas bien lo que estás haciendo, en este caso, creo que lo que tienes que hacer es lo que te dijo AlZu desde el inicio, pero con el cambio que yo te dije luego:
Código PHP:
Ver original
  1. <div id="featured">
  2. <?php if (have_posts()) :
  3.     while (have_posts()) : the_post();
  4.         // Este es el codigo que necesitas cambiar (CREO)
  5.         if ( has_post_thumbnail() ) {
  6.             $attr = array('id' => 'img-' . the_ID());        
  7.         the_post_thumbnail($attr);
  8.         }
  9. ?>
  10. <!-- Captions for Orbit -->
  11.     <span class="orbit-caption" id="<?php the_ID(); ?>" style="color:#F00;">
  12.  
  13.     <a href="<?php the_permalink() ?>"><?php the_title(); ?></a>
  14.     <?php include (TEMPLATEPATH . '/inc/meta.php' ); ?>
  15.     <?php the_excerpt(); ?>
  16.  
  17.     </span>
  18.  
  19. <?php
  20.     endwhile; // Cierre del while() linea 3
  21.     else; // Este else no se de donde sale :/
  22. endif; // Cierre del if() linea 2
  23. ?>
  24.  
  25.     <script type="text/javascript">
  26.     $(window).load(function() {
  27.     $('#featured').orbit({
  28.     bullets: true,
  29.     captions: true,
  30.     captionAnimation: 'fade',
  31.     captionAnimationSpeed: 800,
  32.     });
  33.     });
  34.     </script>
  35. </div><!-- #featured -->
Te indenté el código para que entiendas un poco mejor la cosa.

Saludos, seguimos intentando
__________________
Friki y Blogger por Cuenta Propia:213
Twenty'em: Theming is Prose