Support » Plugins » Hacks » Automatic Phone Number Rotation works everywhere but header.

  • MethodMan


    I built a script that automatically rotates phone number depending on business hours, nights/weekends. The script works great, and I have inserted this code into many pages in the site.

    However, I am having a little trouble with the homepage header. The page stops building at the end of the header code, so the rest of the page does not get built.

    This is how it works for the pages that do work. I call the script RotatePhoneNumbers.php which only does the logic of checking the time of day and deciding which phone number to use. I created a function which is called PhoneNumberPrint(#number); which prints the number after the logic is done.

    All of this works great on other pages, each of these pages are built successfully. And the logic is working to change and print the numbers. It’s just an anomaly that changing the header page prevents the rest of the page of being built.

Viewing 1 replies (of 1 total)
  • Moderator bcworkz


    Sounds like the header page is causing an error severe enough that execution stops. Define WP_DEBUG as true on your config.php file. You should then get some indication of the nature of the error and where it happened in code.

Viewing 1 replies (of 1 total)
  • The topic ‘Automatic Phone Number Rotation works everywhere but header.’ is closed to new replies.