custom field


  • mohammadreza
    Newbie 13 points
    March 4, 2020 at 12:50 pm

    hello

    in “Custom Field” section
    I create “mobile”

    i want to show this field content in “widget-call” section

    I add below code to widget-call.php

    <?php echo $custom[mobile]; ?>

    but this is ((custom[mobile])) not a right name.
    please help me, what is the right name of the Custom Field?


  • mohammadreza
    Newbie 13 points
    March 5, 2020 at 4:13 pm

    ?

  • Adnan
    Adnan
    Elite Member 542 points
    March 5, 2020 at 4:45 pm

    Hi Medi,

    try to use this shortcode:

    <?php echo do_shortcode(‘[CUSTOMFIELD field=”mobile”]’); ?>


  • mohammadreza
    Newbie 13 points
    March 6, 2020 at 1:10 pm

    hi
    thank you very much

  • Adnan
    Adnan
    Elite Member 542 points
    March 6, 2020 at 1:32 pm

    no problem. did it work?


  • mohammadreza
    Newbie 13 points
    March 6, 2020 at 9:57 pm

    yes.
    i used.
    thanks for your help.

  • Mark Fail
    Mark Fail
    Super Guru 13,013 points
    March 8, 2020 at 5:59 am

    Thanks @Adnan

Viewing 7 posts - 1 through 7 (of 7 total)

New Business Themes for WordPress 2020

Start your new website today!

View Business Themes