1

I am a webmaster of a site which was made with WordPress. I don't know PHP. I changed PHP version from 5.6 to 7.2. Since this change, I have an error on my site :

Warning: Use of undefined constant bloginfo - assumed 'bloginfo' (this will throw an Error in a future version of PHP) in /homepages/44/d313626673/htdocs/fcq/wp-content/themes/athlete/header.php on line 20

I downloaded the file header.php from the site:

<div id="frame">
    <div id="description">
    <h1><a href="<?php echo get_option('home'); ?>/"><?php bloginfo; ?></a></h1>
    <p><?php bloginfo; ?></p>
    </div>
    <div id="menu">
        <ul>
           <ul id="nav">
           <li><a href="<?php bloginfo('url'); ?>/">Accueil</a></li>
            <?php wp_list_pages('title_li=&depth=0&sort_column=menu_order&exclude=56'); ?>
            </ul>
        </div>
    <div id="header"></div>

I don't know what the problem is. Can someone help me ?

4

This is incorrect:

<?php bloginfo; ?>

bloginfo() is a function, so you need to use parentheses ():

<?php bloginfo(); ?>
  • Thank for your answer. With your help, i have solved my problem. – illuch Mar 16 at 23:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.