Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Contributor Chris Dillon

    (@cdillon27)

    No, it does not pre-populate. It is not member-aware.

    Warning Google translator !!!
    Hello!

    I made for myself that something like this:

    <?php
      global $current_user;
    get_currentuserinfo();
    
    if( is_user_logged_in() ){ // check authorization
    echo ""
     . '<script type="text/javascript">jQuery(document).ready(function(){
    $("#wpmtst-submission-form").addClass("invizfeld");
    }); </script>' . ""; } // add the class to hide form
    
    ?>
    <script type="text/javascript">
    jQuery(document).ready(function(){
      var n = "<?php echo $current_user->user_lastname;  echo ' ' . $current_user->user_firstname; ?>", e = "<?php echo $current_user->user_email ?>"; // add variables to the data of the current user
      $("#wpmtst_client_name").val(n); // filling the user name field
      $("#wpmtst_email").val(e); // filling the fields email
    });
    </script>

    I inserted it in the file: strong-testimonials/includes/shortcode-form.php
    between lines 416 and 417

    styles to hide the blocks:

    .invizfeld p:nth-of-type(1) { display: none; }
    .invizfeld p:nth-of-type(2) { display: none; }

    I wrote them a file of styles of the current theme.

    It remains as something to add photos.

    p/s: I almost did not understand all this, if someone will make it better, I’ll be glad.

    Plugin Contributor Chris Dillon

    (@cdillon27)

    Beware, I publish frequent updates.

    I have added this feature request here:
    https://www.wpmission.com/project/strong-testimonials/populate-form-fields-if-member-is-logged-in/

    I invite you to join WP Mission and vote for it.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Already Registered Users’ is closed to new replies.