1

I'm going to create a php file with 2 loan calculators inside. This file should be included as a panel like [panel name="calculator-main"]. On the Home Page, file should display both calculator interfaces. On other pages - just a single calculator.

I'm thinking to display appropriate calculator on the page with the following way:

switch ($display) {
case  "calculator 1":

First calculator content

break;
case "calculator 2": 

Second calculator content

break;
default:

here come 2 combined calculators for the Home Page

}

I would much appreciate if anybody will guide me how to call $display parameter in the panel.

Thanks!

Besik
  • 43
  • 7
  • 1
    Have you read the shortcode API docs? That should get you going. https://codex.wordpress.org/Shortcode_API – wbdlc Apr 11 '15 at 15:13

0 Answers0