Announcement

Collapse
No announcement yet.

Need to remove EZ Feature Top widget from my custom page

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Need to remove EZ Feature Top widget from my custom page

    I am building a site which uses the OIO Publisher for ad management and ad sales. OIO provides templates to create a purchase page. My code for the main.tpl template is below. My purchase page mostly looks fine.. I was able to turn off the right header widget, but I can't seem to remove the EZ Feature Top widget (which should only be visible on the home page).

    I have already searched the forum and found these two posts.
    http://cobaltapps.club/forum/ma...emove-ez-areas
    http://cobaltapps.club/forum/ma...page-templates

    This code does not work:

    Code:
     <?php remove_action( 'wp_head', 'ez_feature_top_structure' ); ?>
    The page I'm working on is here: http://clientanamma.divawebdzgn.com/...t/purchase.php

    Here is my purchase page template code
    Code:
    <!DOCTYPE html>
    <html lang="en-US">
    <title>Purchase Ad Space Here</title>
    <?php wp_head(); ?>
    <link rel='stylesheet' id='dynamik_minified_stylesheet-css'  href='<?php echo esc_url( home_url( '/' ) ); ?>wp-content/uploads/dynamik-gen/theme/dynamik-min.css' type='text/css' media='all' />
    </head>
    <body class="page page-template-default content-sidebar windows ie11 feature-top-outside site-fluid override" itemscope="itemscope" itemtype="http://schema.org/WebPage">
    <?php unregister_sidebar( 'header-right' );?>
    
    <?php genesis_header() ?>
    
    <?php genesis_after_header() ?>
    
    <div class="site-inner">
    <link type="text/css" href="<?php echo $oiopub_set->plugin_url; ?>/libs/bubble/bubble.css" rel="stylesheet" />
    <script type="text/javascript" src="<?php echo $oiopub_set->plugin_url; ?>/libs/bubble/bubble.js"></script>
    <script type="text/javascript" src="<?php echo $oiopub_set->plugin_url; ?>/libs/misc/oiopub.js"></script>
    <script type="text/javascript">window.onload = function(){ enableTooltip('oiopub-container'); }</script>
    <div id="oiopub-container" style="padding:20px 0;">
    
    <?php
    //OIO content include
    $oio_inc = empty($templates['path']) ? $oiopub_set->folder_dir . "/templates/core" : $templates['path'];
    include_once($oio_inc . "/" . $templates['page'] . ".tpl");
    ?>
    
    <?php
    //javascript insert
    echo $templates['javascript'];
    $oiopub_hook->fire('content_end');
    ?>
    
    </div>
    </div><!-- end #site-inner -->
    
    <?php genesis_footer() ?>
    
    <?php wp_footer(); ?>
    </body>
    </html>
    Last edited by DivaVocals; 09-26-2014, 05:25 AM.

  • #2
    If I had the plugin, I would create the template with actions and hooks.

    Maybe you could create a label named Remove Feature Top and check the checkbox. Then, paste this into your custom functions:

    PHP Code:
    //* Remove feature top with label
    add_action('template_redirect','jr_remove_feature_top');
    function 
    jr_remove_feature_top() {
        
        if ( 
    dynamik_has_label('remove-feature-top') ) {
            
            
    remove_action'wp_head''ez_feature_top_structure' );
        
        }
        

    Comment


    • #3
      Originally posted by Junior Atoms View Post
      If I had the plugin, I would create the template with actions and hooks.
      And honestly if I understood HOW to do this I would.. Can you provide some insight.. Please..

      Originally posted by Junior Atoms View Post
      Maybe you could create a label named Remove Feature Top and check the checkbox. Then, paste this into your custom functions:

      PHP Code:
      //* Remove feature top with label
      add_action('template_redirect','jr_remove_feature_top');
      function 
      jr_remove_feature_top() {

      if ( 
      dynamik_has_label('remove-feature-top') ) {

      remove_action'wp_head''ez_feature_top_structure' );

      }


      Okay thanks for this.. Pardon my confusion.. Not sure I understand this solution.. I understand how to create a label in Dynamik.. I understand adding this code snippet into the custom functions in Dynamik.. What I am unclear about is what code do I put in my TPL file to make this work?? (the TPL is the file I need to modify to create my purchase page)

      Comment


      • #4
        I cannot provide any insight other than a Genesis page template is similar to a functions.php file. The code does not need to be put in your page template because it runs before WordPress decides what template to use to display your page. Can you select this page template in the page editor? If you can, you can scroll down and select the label also. No idea what your page template name is, so I had to do it this way.

        Comment


        • #5
          Originally posted by Junior Atoms View Post
          I cannot provide any insight other than a Genesis page template is similar to a functions.php file. The code does not need to be put in your page template because it runs before WordPress decides what template to use to display your page. Can you select this page template in the page editor?
          This is not a Genesis page template at all.. It's a template file for the OIO Publisher plugin. OIO Publisher has it's own templates for the ad purchasing pages, and the main.tpl file is the main template file that drives the look and feel of the rest of the purchase pages.

          The template will then generate an OIO Publisher page so that my client's ad customers can purchase the ad space for sale.. If you look at the URL for the purchase page for the OIO Publisher plugin you will see that TECHNICALLY it's an external page on my site. (http://clientanamma(dot)divawebdzgn(...rchase(dot)php) That's why I have to add in the Genesis code to the OIO Publisher template file so that this purchase page will look like the rest of my Genesis created site. The code I quoted in my original post is the code I'm using in my OIO Publisher template file.. It's nearly fine except I can't figure out how to not include the EZ Feature Top widget. I could use CSS and a "display:none;" declaration to hide the EZ Feature Top widget, but I would prefer that the EZ Feature Top widget not generate at all so I'm trying to figure out the right code to use in my OIO Publisher template file to do this. Hence my plea for assistance..

          Hope it makes sense what it is I'm trying to do here..


          Originally posted by Junior Atoms View Post
          If you can, you can scroll down and select the label also. No idea what your page template name is, so I had to do it this way.
          Understood, but I don't think I can use the label technique since this is not a Genesis page template..


          Last edited by DivaVocals; 09-26-2014, 06:41 PM.

          Comment


          • #6
            Add a body class of:

            no-ez-feature-top

            to your already existing body classes and then paste this into your custom css

            Code:
            .no-ez-feature-top #ez-feature-top-container-wrap {
                display: none;
            }

            Comment


            • #7
              Originally posted by Junior Atoms View Post
              Add a body class of:

              no-ez-feature-top

              to your already existing body classes and then paste this into your custom css

              Code:
              .no-ez-feature-top #ez-feature-top-container-wrap {
              display: none;
              }
              Thanks.. I already knew how to hide this using CSS.. What I'm trying to do is to prevent this widget from generating at all.. No worries though.. I'll keep poking at this.. thanks for responding..

              Comment


              • #8
                Delete

                PHP Code:
                <?php genesis_after_header() ?>

                Paste

                PHP Code:
                <?php genesis_do_nav() ?>

                Comment


                • #9
                  Originally posted by Junior Atoms View Post
                  Delete

                  PHP Code:
                  <?php genesis_after_header() ?>

                  Paste

                  PHP Code:
                  <?php genesis_do_nav() ?>
                  Thanks!!!!!

                  Well that's a HUGE "Doh" moment for me here!!!

                  **hangs head in shame**

                  Comment


                  • #10
                    I still have no idea what an OIOpublisher is. So weird.

                    Comment


                    • #11
                      Originally posted by Junior Atoms View Post
                      I still have no idea what an OIOpublisher is. So weird.
                      hehehehehehe.. Maybe this will help..

                      http://www.oiopublisher.com/
                      What is OIOpublisher?

                      OIO is an ad manager that enables you to maximise your revenue, save time, and keep you in complete control of your ad space.
                      Sell and serve ads on any website, using this php ad management script. It can even be used as a Wordpress plugin right out of the box!

                      What are the benefits?
                      • Complete control over your advertising, with fully automated sales
                      • Keep 100% of your revenue, forget middleman commission
                      • Run 3rd party ad networks alongside your own ads
                      • A single license covers all of your websites
                      Last edited by DivaVocals; 09-26-2014, 10:10 PM.

                      Comment


                      • #12
                        I checked it out but I don't understand if it is a plugin or script and why such a weird integration?

                        Comment


                        • #13
                          Originally posted by Junior Atoms View Post
                          I checked it out but I don't understand if it is a plugin or script and why such a weird integration?
                          It's kinda BOTH.. You can use the PHP code OR the widgets to create your ad zones.. You use the templates to create your ad sell pages.. You can use the code on BOTH WordPress and non WordPress sites.. Guess he wants the codebase to be together.. Dunno.. **shrugs**

                          Functionally OIO Publisher works fantastic as an ad manager.. what is NOT so fantastic is the WordPress theme integration part especially if one is using Genesis or Thesis as a framework..

                          I do hope the author has been fairly receptive to my critics on this matter namely that the current "templating" system is archaic and IMHO should done using pages with shortcodes like other plugins use.. The widgets included are messy with all of it's embedded CSS. Fortunately you can use the PHP code snippets since you can include or exclude the inline styling using the PHP code. IMHO, most folks are better off using the PHP code inside a text widget versus using the included widgets..

                          The one remaining Achilles heel is that even stripping out the inline styling, it's a BEAR to make this plugin responsive.. The author seems to be working on a solution which I have yet to try out yet, but I'm willing to put in the time to get this LOOKING correct because FUNCTIONALLY there is no other ad manager plugin that has ALL of the right ad/payment management features of OIO Publisher. (and YEP I've tried 3 others of the so-called "best of breed" in this class of plugins)
                          Last edited by DivaVocals; 09-26-2014, 11:16 PM.

                          Comment

                          Working...
                          X