Autor Zpráva
juraj
Profil
Zdravím
ako mám zobraziť hodnotu idfotky pod galériou,ktorá je kombinovaná s jquery?
dakujem za rady

  <script type="text/javascript">
 
  $(function() {

    var galleries = $('.ad-gallery').adGallery();
    $('#switch-effect').change(
      function() {
        galleries[0].settings.effect = $(this).val();
        return false;
      }
    );
    $('#toggle-slideshow').click(
      function() {

        galleries[0].slideshow.toggle();
        return false;
      }
    );
    galleries[0].addAnimation('wild',
      function(img_container, direction, desc) {
        var current_left = parseInt(img_container.css('left'), 10);
        var current_top = parseInt(img_container.css('top'), 10);
        if(direction == 'left') {
          var old_image_left = '-'+ this.image_wrapper_width +'px';
          img_container.css('left',this.image_wrapper_width +'px');
          var old_image_top = '-'+ this.image_wrapper_height +'px';
          img_container.css('top', this.image_wrapper_height +'px');
        } else {
          var old_image_left = this.image_wrapper_width +'px';
          img_container.css('left','-'+ this.image_wrapper_width +'px');
          var old_image_top = this.image_wrapper_height +'px';
          img_container.css('top', '-'+ this.image_wrapper_height +'px');
        };
        if(desc) {
          desc.css('bottom', '-'+ desc[0].offsetHeight +'px');
          desc.animate({bottom: 0}, this.settings.animation_speed * 2);
        };
        img_container.css('opacity', 0);
        return {old_image: {left: old_image_left, top: old_image_top, opacity: 0},
                new_image: {left: current_left, top: current_top, opacity: 1},
                easing: 'easeInBounce',
                speed: 2500};
      }
    );
  });
  function debug(str) {
    if(window.console && window.console.log && jQuery.browser.mozilla) {
      console.log(str);
    } else {
      $('#debug').show().val($('#debug').val() + str +'\n');

    }
  }

  </script>
  <div id="gallery" class="ad-gallery">
      <div class="ad-image-wrapper">

      </div>
      <div class="ad-controls">
      </div>
      <div class="ad-nav">
        <div class="ad-thumbs">
 
          <ul class="ad-thumb-list">
                   <?php
$path = "uploads"; // Upload directory
     $sql = "select idfotky,nazovfotky,nahodnynazovfotky from fotkym order by kedynahrata desc";
  $resulte = mysql_query($sql);
            $num = mysql_num_rows($resulte);
?>
<?

  while(list($idfotky,$nazovfotky,$nahodnynazovfotky) = mysql_fetch_row($resulte)) {

      $cesta="$path/$nahodnynazovfotky";//nova cesta k obrazku
     $newwidth  =100;/*576*/
     $newheight =75;/*1000*/
     $cesta="$path/$nahodnynazovfotky";//nova cesta k obrazku
list($width, $height, $type) = getimagesize($cesta);
    $imageheight = floor(($height/$width)*$newwidth);
  $imagewidth  = $newwidth;
    $imagewidth  = floor(($width/$height)*$newheight);
  $imageheight = $newheight;

    

          ?>   

 <li>   
<a href="uploads/<?php echo $nahodnynazovfotky;?>">
  <img src="uploads/<?php echo $nahodnynazovfotky;?>" longdesc="<?php echo $nahodnynazovfotky;?><?php echo $idfotky;?>" 
    width="<? echo $imagewidth;?>" height=" <? echo $imageheight;?>"  style="border:3px solid black"></a>

           </li>    


  <?}?> 
        </ul>    
        </div>
      </div>

       </div>
idfotky<?php echo $idfotky = $_GET[idfotky];  ?>

Vaše odpověď

Mohlo by se hodit

Neumíte-li správně určit příčinu chyby, vkládejte odkazy na živé ukázky.
Užíváte-li nějakou cizí knihovnu, ukažte odpovídajícím, kde jste ji vzali.

Užitečné odkazy:

Prosím používejte diakritiku a interpunkci.

Ochrana proti spamu. Napište prosím číslo dvě-sta čtyřicet-sedm:

0