• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Outreach Pro – add php in (non-existent) header.php?

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › Outreach Pro – add php in (non-existent) header.php?

This topic is: resolved

Tagged: header.php, outreach, script

  • This topic has 3 replies, 3 voices, and was last updated 8 years, 11 months ago by Brad Dalton.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • June 22, 2014 at 9:12 pm #111110
    styzer
    Participant

    Hi guys,

    I'm trying to insert a newsticker php code in the header of the theme. However... there is no "header.php" file for that theme. I tried to enter it in the Genesis settings in "Enter scripts or code you would like output to wp_head():" but unless I'm missing some tags, it's not showing.

    So I have two questions:

    1- where do I insert header bound php tags when there is no header.php?
    2- how do I control the location of that script on the page? I'd like it to show below the slider.

    Here is the site: http://thresholdpublications.com/ortzion3/

    I've searched but haven't found answers that I could apply. If you know where I should look, I'd be grateful!

    Regards,

    Andre

    http://thresholdpublications.com/ortzion3/
    June 22, 2014 at 9:42 pm #111114
    nutsandbolts
    Member

    If you need the script to be called before the closing </head> tag, the box in theme settings is the correct place.

    In most cases, you should have two pieces of code - one for the header, and one that actually outputs the ticker on the page. If that's the case, you would put the one in the header scripts box, and the other in a widget area below the slider (you may need to add a widget area if there isn't one there).


    Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
    I provide development and training services for designers • Find me on Twitter and Google+

    June 22, 2014 at 10:35 pm #111119
    styzer
    Participant

    Thank you Andrea!

    So I have this php code to insert: <?php jnewsticker_display( 0 ) ?> in the Genesis settings. Check.

    And you're correct, there is another step: insert the widget under the slider's widget. Check.

    Here is the ticker I'm using: http://codecanyon.net/item/jnewsticker-for-wordpress/2506620

    Thank you!!!

    Regards,

    Andre

    June 23, 2014 at 2:06 am #111123
    Brad Dalton
    Participant

    You control the position on the page using a genesis hook.

    Template tags are more efficient than shortcodes.

    Always include if ( function_exists() because the function won't try and execute if the plugin is deactivated or the function is removed.


    Tutorials for StudioPress Themes & WooCommerce.

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘General Discussion’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble