Delete button backend (Pro-sites)

Hello guys,

I am trying to delete this button:

I think I found the string in the file gateway.php, but when I delete it, it's still there.
Here is the string that I found:

It make no sense to me. It is in perfect order regardin to the other stuff on the page, in the file. Do I have to delete more than just the string I marked on the picture?

Thanks

Nicolaj

  • Predrag Dubajic
    • Support

    Hey Nicolaj,

    Changing plugin core files is not suggested and it should be avoided whenever possible as changes will be overwritten when next update is released.

    My suggestion is to simply hide that with some CSS code like this:

    #psts-payment-info-received > [href*="wp-admin"].button {
        display: none;
    }

    If your theme doesn't have custom CSS field, then you may wish to use a child theme or a plugin like this one for this additional CSS. That way you're protected when you come to upgrade.

    Would this work for you?

    Best regards,
    Predrag

  • Nicolaj
    • Design Lord, Child of Thor

    Hi Pedrag,

    I downloaded the plugin you suggested and it works. THANK YOU! :slight_smile:

    But, if you say it's not recommended to delete code, maybe you can help me deactivate these strings too:

    `$content .= '<p>' . esc_html__( 'Your login details are:', 'psts' ) . '</p>';

    $content .= '<p>' . sprintf( esc_html__( 'Username: %s', 'psts' ), $username );

    $content .= '' . esc_html__( 'Admin URL: ', 'psts' ) . '' . esc_html__( $blog_admin_url ) . '</p>';

    I deleted then at first, and it works fine, but if you say they will appear again, I better do the same trick to them. :slight_smile:

    Just a screenshot if you want to see the sorrounding code:

    - Thank you

  • Adam Czajczyk
    • Support Gorilla

    Hello Nicolaj,

    I hope you're having a nice day!

    This CSS should remove these information:

    #psts-payment-info-received p:nth-of-type(2),
    #psts-payment-info-received p:nth-of-type(3),
    #psts-payment-info-received p:nth-of-type(4)
    {display:none;}

    Apply it to your site the same way as you previously did with code shared by my colleague Predrag and let me know please if it worked for you.

    Best regards,
    Adam

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.