Forum Replies Created

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter mirandarma

    (@mirandarma)

    @loganless

    I am sorry I don’t know what you are asking.

    I posted kind of pain in the butt manual delete instructions up a few posts if that what is what you are asking.

    Thread Starter mirandarma

    (@mirandarma)

    A temp fix.

    So this will change obviously depending on what you named your DB. Log in to your DB manager and run this query from the **_posts table.

    DELETE FROM wp_2posts
    WHERE post_status='flamingo-spam';

    Replace “wp_2posts” with whatever you have named your DB but those are the tables you want to drop.

    The same should work for trash although I only tested the spam one. It is probably a good idea to run a quick backup on your DB before running these.

    DELETE FROM wp_2posts
    WHERE post_status='trash';
    Thread Starter mirandarma

    (@mirandarma)

    I am pretty new at wordpress so I don’t really know how to accomplish it but we could make a plugin that runs along side flamingo and overwrites that section.

    This seems like a good starting point.
    https://iandunn.name/the-right-way-to-customize-a-wordpress-plugin/

    It seems you can override a function if it is the same function name in your child themes functions.php

    I am not sure on that one though either. Sorry I can’t be more of a help.

    Quick Edit: So I was thinking, if we could make a plugin to load a custom “admin/includes/meta-boxes.php” page instead of the normal one that should do it. I will look into it.

    Thread Starter mirandarma

    (@mirandarma)

    Update: I think I have found a little bit cleaner way of doing this.

    <tbody>
    <?php foreach ( (array) $post->fields as $key => $value ) : $alt = 0; ?>
    <?php $cleaner = str_replace(array('_', '-')," ","$key"); ?>
    <tr<?php $alt = 1 - $alt; echo $alt ? ' class="alt"' : ''; ?>>
    <td class="field-title"><?php echo preg_replace('/\d/', '', $cleaner ); ?></td>
    <td class="field-value"><?php echo flamingo_htmlize( $value ); ?></td>
    </tr>
    <?php endforeach; ?>
    
    </tbody>

    This removes “-” and “_” and numbers from the inbound message titles.

    Thread Starter mirandarma

    (@mirandarma)

    So I believe I solved the problem.

    Edit line 167 in “admin/includes/meta-boxes.php”

    From
    <td class="field-title"><?php echo esc_html( $key ); ?></td>

    To
    <td class="field-title"><?php echo str_replace("_"," ","$key"); ?></td>

    So when creating the questions for your form only use underscores.

    Thread Starter mirandarma

    (@mirandarma)

    So after looking into another plugin called “Contact Form 7 Modules” I see they use a script that changes the formatting of the email sent to remove extra “_” and “-” characters.

    I was hoping maybe someone a little more experienced with PHP could help me modify the code to suit flamingos use.

    _____________________________________________________

    // Make the fields easier to read. Thanks, @hitolonen
    $k = apply_filters( ‘wpcf7_send_all_fields_format_key’, true ) ? ucwords(str_replace(“-“, ” “, str_replace(“_”, ” “, $k))) : $k;

    This is pulled from the plugin.

Viewing 6 replies - 1 through 6 (of 6 total)