Jump to content

Archived

This topic is now archived and is closed to further replies.

alecnoriegagmailcom

Error in Hooker

Recommended Posts

alecnoriegagmailcom    0
alecnoriegagmailcom

Hello I have this error in hooker

 

Warning: array_merge(): Argument #2 is not an array in /www/alternativa3.org/htdocs/wp-content/plugins/hooker/hooker.php on line 340
Warning: Invalid argument supplied for foreach() in /www/alternativa3.org/htdocs/wp-content/plugins/hooker/hooker.php on line 340

 

Any idea what i am doing wrong (the 3 hooks i have are HTML)

 

Thanks!

Share this post


Link to post
Share on other sites
Danny    1,327
Danny
Hi, Can you provide the code you're using and also what hooks you're using too please.

Please search our forums, before posting!

Share this post


Link to post
Share on other sites
alecnoriegagmailcom    0
alecnoriegagmailcom

Hello Danny, Thanks for the fast response!!

 

Here are the hooks / code

 

Hook #1
pagelines_inside_bottom_morefoot

Code:
<table width="900" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <th width="624" scope="col"><div align="left">
      <p class="parrafo_footer">FUNDACION ALTERNATIVA 3 ESTRATEGIAS DE DESARROLLO COMUNITARIO<br />
        25 de mayo 985 - B1613FNG - Los Polvorines - ARGENTINA<br />
        Tel.: +54 (11) 4660-4304 / Tel. - Fax: +54 (11) 4663-6237<br />
        Inscripción en IGJ N° 1724312/36501/2003</p>
    </div></th>
    <th width="276" align="right" scope="col"><a href="http://www.alternativa3.org/banners/Carta_proteccion_donante.pdf" class="parrafo_footer">LEY DE PROTECCIÓN AL DONANTE</a></th>
  </tr>
  <tr>
    <th colspan="2" bgcolor="#EEEEEF" scope="col"><a href="http://www.alternativa3.org/banners/Carta_proteccion_donante.pdf" class="parrafo_footer"></a></th>
  </tr>
</table>

Hook #2
wp_footer

Code:
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Documento sin título</title>
<style type="text/css">
body {
    background-color: #C9C9C9;
}
</style>
</head>

<body>
</body>
</html>

Hook #3
pagelines_after_features

Code:
<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <th align="center" scope="col"><img src="http://www.alternativa3.org/banners/barra.jpg" alt="Acceso Rápido" width="1000" height="65" usemap="#Map" longdesc="Acceso Rápido" border="0" /></th>
  </tr>
</table>

<map name="Map">
  <area shape="rect" coords="61,1,269,52" href="http://alternativa3.org/modelo-de-intervencion‎" target="_self" alt="Modelo de Intervecion">
  <area shape="rect" coords="279,1,488,50" href="http://alternativa3.org/donde-estamos/" target="_self" alt="Dónde Estamos">
  <area shape="rect" coords="498,-8,708,50" href="http://alternativa3.org/para-quienes-trabajamos/" target="_self" alt="Para Quienes Trabajamos">
  <area shape="rect" coords="716,3,925,48" href="http://alternativa3.org/canal-multimedia/" target="_self" alt="Canal Multimedia">
</map>
 

 

THANKS!!

Share this post


Link to post
Share on other sites
gingerdezine    0
gingerdezine

I am getting the same errors in Hooker as well.

 

Hooker was working great for me before the hack/server switch/DMS launch. Now I get the error and I cannot access, add, edit or change my Hooks. I have a feeling it may be connected to the Store and account login within the website issues which is not working yet?

Share this post


Link to post
Share on other sites
gingerdezine    0
gingerdezine

Any ideas with this? I get this message within Hooker.

 

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home2/cmplive/public_html/wp-content/plugins/hooker/hooker.php on line 340

Warning: Invalid argument supplied for foreach() in /home2/cmplive/public_html/wp-content/plugins/hooker/hooker.php on line 340

 

I can choose a Hook from the dropdown, but it does not open an editing window to add code into.

Plug in is activated and I am logged into my Pagelines account. It worked great before, but now I get the message.

Share this post


Link to post
Share on other sites
Rob    547
Rob

First, you should never, ever add anything with <head> or <body> tags into a hook. That's creating a new page, so bad code will break things, including hooker.  It seems you're not adding a hook as much as trying incorrectly to embed a full page within a page.  That's not what Hooker does. For that you need an iframe.

 

To add a table within a hook is fine, but not with the layout of an entire HTML page.


Former PageLines Moderator, Food Expert and Raconteur

Share this post


Link to post
Share on other sites

  • Similar Content

    • webmktco
      By webmktco+
      I'm getting the following errors when trying to add hooks:

      Here's the debug info: http://www.stackdental.com/?pldebug=1
      Core, themes, and plugins are up to date.
       
       
       
    • art23130
      By art23130+
      We had a very nice shortcodes library and hooker in the previous version of the platform. But in the version 5 they are missing. 
      So are you going to improve it again in future or no they are not supported anymore? 
      and one more question, what do you suggest for sharing bar which we had in DMS2 ?
      Thanks for your effort 
    • dreamsight
      By dreamsight+
      We add phone number to the top right of sites using hooker (example http://hub.theasap.org.uk/) but it's not responsive. Is there a better way to add here, which would be responsive?
    • kellid
      By kellid
      Hello, 
      I'm in a dramatic situation.  I have a live site that is totally screwed up and I'm in desperate need to fix it asap.  The site was originally build with Pagelines but have made several upgrades through the years.  With the latest WP upgrade, somehow the action loop I was using on my homepage came through dramatically wrong and not sure how to fix the problem.  I have the Hooker plugin and in need of finding the action map to figure out where to implement the loop and fix the problem.  I found the action map plugin stored on an old hardrive but when activated, I got an error so I quickly deleted it.  I can't find a download or instructions on this anywhere, only broken links and no documentation.   
      Can you please direct me to the action map to use the hooker that I already have or show me the documentation to use this product?  
      Thank you
    • ipitts
      By ipitts+
      To whom it may concern:
      I am developing a website for a client using the PageLines DMS2 theme and am having an issue getting a custom jQuery function to work using your Hooker plugin. I have used Hooker to add HTML and PHP to the wp_head hook successfully, so I do not understand where the issue exists – I am using the pageslines_after_footer hook to place my jQuery at the bottom of the document (alongside the many other scripts that come with the theme and various other plugins). I checked the document HEAD section and know that jQuery is enabled, and after enabling my custom hook saw that my script was loaded into the footer (as hoped for), but it is not working.
      I am trying to make a simple, custom back-to-top button that appears after a user has scrolled the page a certain distance, as calculated in jQuery. After an hour, I decided to troubleshoot my script on a test WordPress site on my localhost (using jQuery version 1.11.3) and it works exactly as intended. I would like to avoid writing any code within the DMS2 theme files if possible.
      I have also tried the wp_head, wp_footer and pagelines_before_footer hooks to no avail. Am I using the wrong hook(s)? What else can I try?
      My code:
      HTML
      <a href="#"><div id="bttb-cont" style="">Hello</div></a>
       
      jQuery (within the Hooker plugin)
      <script type="text/javascript">
                      $(document).scroll(function() {
                                      var windowHeight = $(window).height() / 7;
                                      var scroll = $(window).scrollTop();
                                      
                                      if (scroll > windowHeight) {
                                                      $('#bttb-cont').fadeIn();
                                      } else {
                                                      $('#bttb-cont').fadeOut();
                                      };
                      });
      </script>
       
      As you can see, it is a very simple script.. Any help on this matter will be greatly appreciated.
       
×