Support » Developing with WordPress » In search of a lost text string (or variable)

  • Resolved lukefive


    I inherited a site with a custom theme based on Underscores. The client wants me to change the text in the main headline in the header on ea page. I can’t find that text anywhere in Customize, or the database, or any of the files; PHP, JS, JSON, CSS. The original developer did a lot of his work with the ACF Pro plugin, where I think the headline was defined, but I can’t find this in any of the plugin files either.

    The closest I can get are the lines in header.php where this is called…

    // Make db calls
    $header_title = get_field('header_title', $post->ID);
    // Check and set default
    $header_title = ($header_title) ? $header_title : get_field('header_title', $frontpage);

    Any tips?

Viewing 4 replies - 1 through 4 (of 4 total)
  • lukefive


    OK I finally found this after several more searches of the database. For some reason the “Better Search and Replace” plugin didn’t find it. I found it in _postmeta, but even that required me placing % on either side of my search term. I used SQL to update it.
    Maybe the plugin doesn’t search some tables?

    • This reply was modified 7 months ago by  lukefive.


    Resolved unless someone has a comment.

    Moderator bcworkz


    I don’t have experience with that search plugin, but using SQL wildcard % in searches is always a good idea just in case what you are looking for is in a serialized array. I don’t know if the plugin adds those or not.

    You’ll appreciate this, I had a very similar experience of not finding theme data. Couldn’t find a particular string anywhere, even with wildcards. Searched every table. Turns out the theme base64 encoded its non-senstive data! The way the encoding works, to find a fragment, one needs to encode the search string 4 different ways in order to find one fragment. Sheesh!

    @bcworkz that sounds like even more of a headache than what I encountered. I have only used base64 to simplify handling of certain small images. Never thought it might be used to encode other things.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘In search of a lost text string (or variable)’ is closed to new replies.