Visualizzazione dei risultati da 1 a 3 su 3
  1. #1
    Utente di HTML.it
    Registrato dal
    Sep 2006
    Messaggi
    703

    [WP] MOdifica plugin - ziczac

    allora mi serve un aiuto non conoscendo il php...
    questo è il sources del plugin che ho montato su wordpress:
    codice:
    <?
    /*
    Plugin Name: ZicZac.it Plugin!
    Version: 1.0
    Plugin URI: http://ziczac.it/extra/wordpress-plugin/
    Description: Aggiungi il pulsante di ZicZac per far votare i tuoi post.
    Author: mic
    Author URI: http://simplyeng.com/
    */
    
    function add_ziczac()
    {
        global $post;
        if(is_page())return;
        return '<div class="ziczacp"><script type="text/javascript">zz_url=\''.get_permalink($post->ID).'\';zz_title=\''.get_the_title($post->ID).'\';</script><script src="http://ziczac.it/a/e/zz.js" type="text/javascript"></script></div>';
    }
    
    function insert_ziczac_button($content)
    {
    echo add_ziczac();
    return $content;
    }
    
    add_action('the_content', 'insert_ziczac_button');
    ?>

    Iil mio problema è che si vede 2volte, x rendere meglio l'idea..


    che devo modificare??

    mmm...ci deve essere qlc che non va, xkè se apro poi l'articolo completo, il zig zag è uno solo come è giusto che sia, solo in homepage restano 2..vi posto anche:

    testata

    codice:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    
    <head profile="http://gmpg.org/xfn/11">
    <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
    
    <title><?php bloginfo('name'); ?> <?php if ( is_single() ) { ?> &raquo; Blog Archive <?php } ?> <?php wp_title(); ?></title>
    
    <meta name="generator" content="WordPress <?php bloginfo('version'); ?>" /> 
    <script type="text/javascript" src="http://shots.snap.com/snap_shots.js?ap=1&amp;key=215378dcb1eba0fd6c8f6321e4b890b9&amp;sb=1&amp;th=silver&amp;cl=0&amp;si=0&amp;po=0&amp;df=0&amp;oi=0&amp;link_icon=on&amp;shots_trigger=both&amp;lang=en-us&amp;domain=lineguides.netsons.org/wordpress"></script>
    <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="all" />
    <link rel="stylesheet" href="<?php bloginfo('stylesheet_directory'); ?>/print.css" type="text/css" media="print" />
    <link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> RSS Feed" href="<?php bloginfo('rss2_url'); ?>" />
    <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
    
    <?php wp_head(); ?>
    </head>
    <body>
    <div id="page">
      <div id="header">
        <div id="headerimg">
    	  <h1><?php bloginfo('name'); ?></h1>
    	  <div class="description"><?php bloginfo('description'); ?></div>
    	</div>
    	<ul id="nav">
    	  <li class="page_item">Home
    	  <?php wp_list_pages('sort_column=menu_order&depth=1&title_li=');?>
    	[/list]
      </div>


    template indice

    codice:
    <?php get_header(); ?>
      <div id="content">
      
      <?php if (have_posts()) : ?>
      
      	<?php while (have_posts()) : the_post(); ?>
      
        <div class="post" id="post-<?php the_ID(); ?>">
    	  <div class="post-date"><span class="post-month"><?php the_time('M') ?></span> <span class="post-day"><?php the_time('d') ?></span></div>
    	  <div class="post-title">
    	  <h2>"><?php the_title(); ?></h2>
    		<span class="post-cat"><?php the_category(', ') ?></span> <span class="post-comments"><?php comments_popup_link('No Comments »', '1 Comment »', '% Comments »'); ?></span>
    	  </div>
    	  <div class="entry">
    		<?php the_content('Read the rest of this entry &raquo;'); ?>
    	  </div>
    	</div>
    	
    	<?php endwhile; ?>
    	
    	<div class="navigation">
    	  <span class="previous-entries"><?php next_posts_link('Previous Entries') ?></span> <span class="next-entries"><?php previous_posts_link('Next Entries') ?></span>
    	</div>
    	
    	<?php else : ?>
    	
    		<h2>Not Found</h2>
    		
    
    Sorry, but you are looking for something that isn't here.</p>
    		
      <?php endif; ?>
    	
      </div>
      
    <?php get_sidebar(); ?>
    
    <?php get_footer(); ?>




    :master:

  2. #2
    Utente di HTML.it
    Registrato dal
    Sep 2006
    Messaggi
    703
    ah, mi sono dimenticato di aggiungere che si vede correttamente solo se apro l'articolo per intero..addirittura se uso la barra di ricerca l'articolo mi appare con 3 zig zag helppppppppp pleaseee

  3. #3
    Utente di HTML.it
    Registrato dal
    Sep 2006
    Messaggi
    703
    up up

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.