WordPress.org

Support

Support » Plugins and Hacks » WP-Newsticker » php code not work

php code not work

Viewing 6 replies - 1 through 6 (of 6 total)
  • masmax,

    Where did you insert this code? Did you insert it into the page content, or did you use an editor to insert it into the page template’s source? The latter is what you do if you are editing the template.

    If you just want the news ticker to show up in your page’s content, then place the shortcode [newsticker] in your page content where you want it displayed.

    DS

    I DS

    I tried adn also put it on other pages. php site but not seen

    if I insert the shortcode [ticker] in my page content, you see.

    I do not understand why it’s so … and yet there must be a solution

    i insert the code in this page index.php

    <div id="banner-bg" class="cf">
      	<div id="banner" class="row">
                <script type="text/javascript"><!--
    google_ad_client = "ca-pub-2171832733352315";
    /* headernonavevodubbi */
    google_ad_slot = "5766175822";
    google_ad_width = 468;
    google_ad_height = 60;
    //-->
    </script>
    <script type="text/javascript"
    src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
    </script>
                	<div id="logo-area" class="col5">
            <!--file logo-->
                  <a href="http://www.nonavevodubbi.it"><img src="http://www.nonavevodubbi.it/wp-content/themes/montezuma/images/logo.png" title="nonavevodubbi.it" alt=" Non Avevo Dubbi"/>
    			<!--<<?php bfa_if_front_else( 'h1', 'h3' ); ?> id="sitetitle">
    				<a href="<?php echo home_url(); ?>"><?php bloginfo( 'name' ); ?></a>
    			</<?php bfa_if_front_else( 'h1', 'h3' ); ?>>
    			<p id="tagline"><?php bloginfo( 'description' ); ?></p>-->
    		</div>
    		<?php wp_nav_menu( array(
    			'container' => 'nav',
    			'container_class' => 'menu-wrapper col7',
    			'container_id' => 'menu1-wrapper',
    			'menu_id' => 'menu1',
    			'menu_class' => 'cf menu',
    			'theme_location' => 'menu1',
    			'fallback_cb' => 'bfa_page_menu'
    		) ); ?>
    	</div>
    </div>
    
    <a href="<?php bloginfo( 'rss2_url' ); ?>" class="rsslink" title="<?php _e( 'Subscribe to RSS Feed', 'montezuma' ); ?>"></a>
    
    <div id="breadcrumbs1-bg">
    	<nav id="breadcrumbs1" class="breadcrumbs lw">
    		<?php bfa_breadcrumbs( 'breadcrumbs1' ); ?>
          	</nav>
        </div>
      <?php include ('/wp-content/plugins/wp-newsticker/news.php');?>

    regards
    max

    what theme are you using?

    I added the file to the head.php file and it displayed.
    So where exactly do you want it displayed?

    The best approach is to create a physical file and put your code in it.
    The theme works on a virtual templating system and the documentation says You cannot use arbitrary PHP code.

    I created a php file, I put in the code, then I called the
    <? php include ("namefile.php") /?>

    but does not work

    please, can you explain me with an example?

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘php code not work’ is closed to new replies.
Skip to toolbar