Lütfen bilgilerinizi girin
E-Posta Adresi ya da Takma Ad
Parola
Parolamı Unuttum
Beni Hatırla
ANASAYFA
SORU SOR
SORULAR
UZMANLAR
‹
Sorduğum Sorular
›
‹
Takip Ettiğim Sorular
›
‹
Verdiğim Cevaplar
›
‹
Arşivimdeki Sorular
›
‹
İlgilendiğim Alanlardaki Sorular
›
Kodları lütfen aşağıdaki butonları kullanarak renklendirin.
Örnek:
<php> echo "Selam Dünya"; </php>
Soruyu takip et
karakter kaldı
solaxay
3 cevap
–
17 soru
Profili
|
Mesaj At
|
Takip Et
Tweet
Kategoriler
CSS - HTML
PHP
JavaScript
jQuery
Wordpress
İstatistikler
12 yıl önce
yazılmış
35 üye
izlemiş
1 cevap
verilmiş
Javascript: OnMousOver
merhaba arkadaslar.... böyle bir js icerisinde fonksiyonumuz var.
function mansetSagDegis(id)
{
if(id != currentMSag)
{
$("#mansetSagLinkk" + currentMSag).removeClass("red12").addClass("gray");
$("#mansetSagLinkk" + id).removeClass("gray").addClass("red12");
$("div.mansetSagKutuYeni").html($("div.mansetSagGizli:eq(" + id + ")").html());
$("img.mansetSagOk:eq(" + currentMSag + ")").attr({ src: "/image/manset/griOk.jpg" });
$("img.mansetSagOk:eq(" + id + ")").attr({ src: "/image/manset/redOk.jpg" });
currentMSag = id;
}
}
Şimdi bunu döngüde böyle kullanarak haber başlıklarını sıralıyorum ama
onmouseover="javascript:mansetSagDegis( ???????????? ); parantez içerisinde ne yazmam lazım ? onu bulamadim :( yardım edin lutfen.
anlayacağınız şöyle olması lazım her haber başlığına a++ gibi id lerini kendi otomotik artirmasi lazim ama yapmiyor.
Kod burada:
<div id="ctl00_ortayer_mansetSagHaberler" class="mansetSagHaberlerYeni">
<?php query_posts('cat=3&showposts=5'); ?>
<?php if (have_posts()) : ?>
<?php $count = 0; ?>
<?php while (have_posts()) : the_post(); ?>
<?php $count++; ?>
<?php if ($count == 1) : ?>
<div class="mansetSagSatirYeni">
<img src="
http://yeniufuq.com/wp-content/themes/zenko/manset_sag_img/griOk.jpg"
class="mansetSagOk" />
<a id="mansetSagLinkk" href="<?php the_permalink(); ?>" class="gray" onmouseover="javascript:mansetSagDegis();"> <?php the_title(); ?></a>
</div>
<div class="mansetSagAra"><!---->
</div><div class="mansetSagGizli"><a href="<?php the_permalink(); ?>" class="gray11" ><img src=" <?php echo get_permalink($_post->ID); ?>">
<?php unset($photo);
if ( current_theme_supports( 'post-thumbnails' ) && has_post_thumbnail() ) {
the_post_thumbnail(array(9999,240, true));
}
else{
if (!$photo)
{
$photo = catch_that_image($post->ID);
}
} // if CF not used
if ($photo)
{
?>
<a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><img src="<?php bloginfo('template_directory'); ?>/scripts/timthumb.php?w=200&h=240&zc=1&src=<?php echo $photo; ?>" alt="<?php the_title(); ?>" /></a>
<?php
}
else
{
echo"<img src=\""; bloginfo('template_directory'); echo"/images/blank.jpg\" />";
} // if $photo still does not exist
?> " style="margin-bottom: 1px; border: solid 1px #ddd; padding: 2px" alt="" />
<div class="mansetSagOzet"><?php the_content_rss('', TRUE, '', 7); ?></div></a></div>
<?php else : ?>
<?php endif; ?>
<?php endwhile; ?>
<?php else : ?>
<p>Sorry, no posts matched your criteria.</p>
<?php endif; ?>
<?php if (have_posts()) : ?><?php $count = 0; ?><?php while (have_posts()) : the_post(); ?><?php $count++; ?>
<?php if ($count == 0) : ?>
<?php elseif ($count == 1) : ?>
<?php else : ?>
<div class="mansetSagSatirYeni">
<img src="
http://yeniufuq.com/wp-content/themes/zenko/manset_sag_img/griOk.jpg"
class="mansetSagOk" />
<a id="mansetSagLinkk" href="<?php the_permalink(); ?>" class="gray" onmouseover="javascript:mansetSagDegis();"> <?php the_title(); ?></a></div>
<div class="mansetSagAra"><!----></div>
<div class="mansetSagGizli"><a href="<?php the_permalink(); ?>" class="gray11" ><img src=" <?php echo get_permalink($_post->ID); ?>">
<?php unset($photo);
if ( current_theme_supports( 'post-thumbnails' ) && has_post_thumbnail() ) {
the_post_thumbnail(array(9999,240, true));
}
else{
if (!$photo)
{
$photo = catch_that_image($post->ID);
}
} // if CF not used
if ($photo)
{
?>
<a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><img src="<?php bloginfo('template_directory'); ?>/scripts/timthumb.php?w=200&h=240&zc=1&src=<?php echo $photo; ?>" alt="<?php the_title(); ?>" /></a>
<?php
}
else
{
echo"<img src=\""; bloginfo('template_directory'); echo"/images/blank.jpg\" />";
} // if $photo still does not exist
?> " style="margin-bottom: 1px; border: solid 1px #ddd; padding: 2px" alt="" />
<div class="mansetSagOzet"><?php the_content_rss('', TRUE, '', 7); ?></div></a></div>
<?php endif; ?>
<?php endwhile; ?>
<?php else : ?>
<p>Sorry, no posts matched your criteria.</p>
<?php endif; ?>
</div>
<div style="float: left;" >
<div class="mansetSagKutuYeni" >
</div>
</div>
</div>
+0
-0
Cevaplar
12 yıl önce yazılmış
Supervisor
107 cevap - 0 soru
mansetSagLinkk i vermelisin