[Resolved] Woocommerce Stripe input fields not working at all.

Home Forums Support [Resolved] Woocommerce Stripe input fields not working at all.

Home Forums Support Woocommerce Stripe input fields not working at all.

Viewing 15 posts - 1 through 15 (of 20 total)
  • Author
    Posts
  • #680349
    Brad

    I’m not sure if this is a bug with Stripe. I’ve gone over my Woocommerce settings and made sure to add the url api endpoint within the stripe admin testing panel. My woocommerce settings (api testing keys) are correct

    Any fix for this? There’s no way to even “click inside” the box to input one’s information.

    I’ve searched the forum. Most issues appear to be css / viewport related.

    I found this related on github, an understrap issue.

    https://github.com/understrap/understrap/issues/682

    Thanks in advance for assistance.

    Brad

    #680631
    David
    Staff
    Customer Support

    Hi there,

    you have a couple of errors showing in the browser dev console. 1st is 403 on your child theme, second is a jQuery error which looks to be related to the payment function.

    #681061
    Brad

    Huh. Not good. Didn’t see this. Should of checked. Any ideas? It’s a bit beyond my skill set to be honest. I’ve been pushing my limits pushing this theme by adding foundation framework which has been a pain. I could try commenting it out.

    I also have autoptiizer running which I’ve had to troubleshoot, not load certain scripts to get things to work work in the past. Not sure how to solve this threads current problem. Any help sincerely appreciated.

    Below is my functions.php

    <?php
    /**
    * GeneratePress child theme functions and definitions.
    *
    * Add your custom PHP in this file.
    * Only edit this file if you have direct access to it on your server (to fix errors if they happen).
    *
    * YES – CHILD THEME – FUNCTIONS.PHP FILE – gpdonebox-child
    *
    */

    function generatepress_child_enqueue_scripts() {
    if ( is_rtl() ) {
    wp_enqueue_style( ‘generatepress-rtl’, trailingslashit( get_template_directory_uri() ) . ‘rtl.css’ );
    }
    }
    add_action( ‘wp_enqueue_scripts’, ‘generatepress_child_enqueue_scripts’, 100 );

    // disable admin bar
    add_filter(‘show_admin_bar’, ‘__return_false’);

    /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    //
    // This is the CHILD THEME’s main – FUNCTIONS.php
    // This code is to INCLUDE ALL SUB-FUNCTION FILES
    //
    //
    //
    ////////////////////////////////////////////////////
    ////////////////////////////////////////////////////

    // j66 enqueue scripts frameworks code – foundation 6.4
    require( get_stylesheet_directory() . ‘/includes/functions/functions-j66-scripts.php’);

    // woocommerce customizations
    require( get_stylesheet_directory() . ‘/includes/functions/functions-j66-woocommerce.php’);

    // shortcodes conditional
    require( get_stylesheet_directory() . ‘/includes/functions/functions-j66-shortcodes-conditional.php’);

    // new shortcodes
    // require( get_stylesheet_directory() . ‘/includes/functions/functions-j66-shortcodes.php’); NOT NEEDED – NOW IN ABOVE –

    // new widgets
    require( get_stylesheet_directory() . ‘/includes/functions/functions-j66-widgets.php’);

    // wp site snippets
    require( get_stylesheet_directory() . ‘/includes/functions/functions-j66-snippits.php’);

    // j66 development code
    // require( get_stylesheet_directory() . ‘/includes/functions/functions-j66-development.php’);

    // doneyt admin customizations
    require( get_stylesheet_directory() . ‘/includes/functions/functions-doneyt-admin-dashboard.php’);

    // doneyt merchant web app snippits
    // require( get_stylesheet_directory() . ‘/includes/functions/functions-doneyt-merchant-web-app.php’);

    #681064
    Brad

    functions-j66-scripts.php

    Note
    I’ve had lots a problems with this and could ditch this whole foundation framework for flexbox

    ___________________________________________

    <?php
    /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    //
    // J66 SITE FRAMEWORKS
    //
    //
    //
    //
    ////////////////////////////////////////////////////
    ////////////////////////////////////////////////////

    /** Adding Foundation 6.4 xy grid
    *
    *
    */

    // Adding Foundation 6.4 xy grid – custom – 180810
    // Enqueue scripts and styles
    //
    // Plugin API/Action Reference/wp enqueue scripts- WordPress Codex
    // https://codex.wordpress.org/Plugin_API/Action_Reference/wp_enqueue_scripts
    //
    // https://developer.wordpress.org/reference/functions/wp_enqueue_style/
    //

    function j66gpdonebox_enqueue_style() {
    if ( is_child_theme() ) {
    // load parent stylesheet first if this is a child theme
    wp_enqueue_style( ‘parent-stylesheet’, trailingslashit( get_template_directory_uri() ) . ‘style.css’, false );
    }
    // load active theme stylesheet in both cases
    wp_enqueue_style( ‘child-theme-stylesheet’, get_stylesheet_directory_uri(), false );
    wp_enqueue_style( ‘foundation-app-style’, get_stylesheet_directory_uri() . ‘/foundation/css/app.css’ );
    wp_enqueue_style( ‘foundation-style’, get_stylesheet_directory_uri() . ‘/foundation/css/foundation.css’ );
    wp_enqueue_style( ‘foundation-min-style’, get_stylesheet_directory_uri() . ‘/foundation/css/foundation.min.css’ );
    // wp_enqueue_style( ‘fontawesome-style’, get_stylesheet_directory_uri() . ‘/styles/font-awesome.css’ );

    // https://sridharkatakam.com/load-font-awesome-5-wordpress/
    // wp_enqueue_style( ‘font-awesome-free-all’, ‘//use.fontawesome.com/releases/v5.2.0/css/all.css’ );

    }

    function j66gpdonebox_enqueue_script() {
    /* true loads js in footer */
    /* Add Foundation JS */
    /* wp_enqueue_script( ‘foundation-app-js’, get_template_directory_uri() . ‘/foundation/js/app.js’, array( ‘jquery’ ), ‘1’, true ); */
    /* wp_enqueue_script( ‘foundation-js’, get_template_directory_uri() . ‘/foundation/js/vendor/foundation.min.js’, array( ‘jquery’ ), ‘1’, true ); */
    wp_enqueue_script( ‘foundation-app-js’, get_stylesheet_directory_uri() . ‘/foundation/js/app.js’, array( ‘jquery’ ), ‘1’, true );
    wp_enqueue_script( ‘foundation-js’, get_stylesheet_directory_uri() . ‘/foundation/js/vendor/foundation.min.js’, array( ‘jquery’ ), ‘1’, true );

    /* Foundation Init JS */
    /* wp_enqueue_script( ‘foundation-init-js’, get_template_directory_uri() . ‘/foundation/js/vendor/foundation.js’, array( ‘jquery’ ), ‘1’, true ); */
    wp_enqueue_script( ‘foundation-init-js’, get_stylesheet_directory_uri() . ‘/foundation/js/vendor/foundation.js’, array( ‘jquery’ ), ‘1’, true );

    /* Foundation Jquery – Foundation Vendor */
    /* wp_enqueue_script( ‘foundation-jquery-js’, get_template_directory_uri() . ‘/foundation/js/vendor/jquery.js’, array( ‘jquery’ ), ‘1’, true ); */
    /* wp_enqueue_script( ‘foundation-whatinput-js’, get_template_directory_uri() . ‘/foundation/js/vendor/what-input.js’, array( ‘jquery’ ), ‘1’, true ); */
    wp_enqueue_script( ‘foundation-jquery-js’, get_stylesheet_directory_uri() . ‘/foundation/js/vendor/jquery.js’, array( ‘jquery’ ), ‘1’, true );
    wp_enqueue_script( ‘foundation-whatinput-js’, get_stylesheet_directory_uri() . ‘/foundation/js/vendor/what-input.js’, array( ‘jquery’ ), ‘1’, true );

    wp_enqueue_script( ‘j66-custom-js’, get_stylesheet_directory_uri() . ‘/scripts/j66-custom.js’, array( ‘jquery’ ), ‘1’, false );

    if ( is_singular() && comments_open() && get_option( ‘thread_comments’ ) ) {
    wp_enqueue_script( ‘comment-reply’ );
    }
    }

    add_action( ‘wp_enqueue_scripts’, ‘j66gpdonebox_enqueue_style’ );
    add_action( ‘wp_enqueue_scripts’, ‘j66gpdonebox_enqueue_script’ );

    #681113
    Brad

    Just posted this question on a forum as well.
    Insecure content blocked. Site loaded over HTTPS but requested an insecure stylesheet HTTP.

    Anyone have a tip how to track this down. My child theme stylesheet is represented in the site. I’m assuming this is a plugins stylesheet??

    My urls are relative when possible.

    I found a few search and replace plugin suggestions articles online but this doesn’t seem to be the ideal solution to me. Thank in advance for any suggestions.

    https://managewp.com/blog/wordpress-ssl-settings-and-how-to-resolve-mixed-content-warnings

    Chrome Console Error Message:

    Mixed Content: The page at ‘https://staging-site.test/&#8217; was loaded over HTTPS, but requested an insecure stylesheet ‘http://staging-site.test/wp-content/themes/child-theme/?ver=4.9.8&#8217;. This request has been blocked; the content must be served over HTTPS.

    JQMIGRATE: Migrate is installed, version 1.4.1 autoptimize_5290f58f1f6def3bb1ba7350abfdb0e1.js:2

    #681304
    Tom
    Lead Developer
    Lead Developer

    Does the Stripe issue go away if you activate the parent theme?

    #681321
    Brad

    Update:

    This is odd. Made changes. Tried a few different variation. Originally I was using get_sytlesheet_directory_uri (line 37) which should work I would think w/o throwing errors.

    When I either removed all reference to enqueue the child theme’s stylesheet OR used get_stylesheet_uri (line 35) the mixed content error vanished. Hence, it’s not throwing the insecure http stylesheet error with get_stylesheet_uri.

    Still getting all the js / jquery errors and stripe issue still present. Thoughts?

    https://www.dropbox.com/s/p9tz6zz0618fzhe/Screen%20Shot%202018-09-19%20at%208.52.17%20AM.png?dl=0

    #681325
    Brad

    I activated Parent theme and got a huge amount of errors. Now I’m getting all these errors when trying to reverse back to child theme. Just tried to download twenty sixteen and everything is messed up.

    #681340
    Brad

    I’m working on local right now. Just restored from All in One backup from 17 hrs ago. I’ve built a lot of into the child theme (widgets, functions, etc, created a new footer.php — I’ll open another support ticket for that; couldn’t figure out how to shove my custom hook into a GP hook).. widgets, etc got wiped when switching themes to parent / twenty-sixteen which hopefully is why things looked the way they did when I activated child theme again.

    I would think I wouldn’t get errors when switching to parent or twenty sixteen though.

    #681629
    Tom
    Lead Developer
    Lead Developer

    get_stylesheet_uri should grab the URL you have set in “Settings > General”. Are those URLs set to https?

    #682073
    Brad

    Yes it’s correct in wp-admin settings. Thoughts on myself clone the
    staging-site . com to
    xdebug-site . com

    Using that to try to figure out what’s happening? On a FB group forum I got some chrome dev tool console tips I’m going to try this morning. I’m turn off autopitimizer and then take things from there.

    It is disturbing not being able to switch to parent or twenty sixteen. Something’s not right.

    Question:
    Thoughts on myself clone the site for debugging?
    Would you mind taking a look at the cloned site? I can set up credentials and send them via email.

    Possibly I can try deactivating Stripe and activating Paypal. See if text fields to input credit cards work?

    #682096
    Brad

    Ok one of the errors I’m getting have to do with the add number of items in cart custom code found on the GP forum.

    https://generatepress.com/forums/topic/adding-a-cart-icon-with-number-of-items-and-total-cost-in-nav-menu/page/2/

    I did find this reference to the error on github (a different plugin / theme). He explains ‘in’ error and how to fix it. I don’t see an ‘in’ in your code. I did find an extra space on line 380 between “fa-shopping-cart” AND aria-hidden=”true

    I was hoping that would fix the second problem.

    https://www.dropbox.com/s/7k7d1dmmo6rqztk/Screen%20Shot%202018-09-20%20at%206.57.17%20AM.png?dl=0

    https://www.dropbox.com/s/vjn3kgxqyvfl2a0/Screen%20Shot%202018-09-20%20at%206.51.02%20AM.png?dl=0

    #682138
    Brad

    Exiting News!!

    Ditched enqueueing Foundation framework, commented out functions i wrote but weren’t using yet as I could get them to work as planned, turned off Ultimate Member Woocommerce Paid plugin (which I’m not thrilled about turning it off but at least Stripe is working now).

    I am a bit afraid to find out if switching themes to the parent theme of twenty sixteen will break site.

    I’m still getting the code error with the shopping cart script in the menu bar from your previous post. Any ideas?

    Thanks in advance for your patience and help!

    Brad

    https://www.dropbox.com/s/eil66c5ms0nj7b5/Screen%20Shot%202018-09-20%20at%207.39.10%20AM.png?dl=0

    #682698
    Tom
    Lead Developer
    Lead Developer

    That’s really strange.

    What happens if you use this as your link function (just to test)?:

    function j66_custom_wc_cart_link() {
    	// Kept for backward compatibility.
    	$icon = apply_filters( 'generate_woocommerce_menu_cart_icon', '' );
    
    	// Get the icon type.
    	$icon_type = generatepress_wc_get_setting( 'cart_menu_item_icon' );
    
    	ob_start();
    	?>
    	<a href="<?php echo esc_url( wc_get_cart_url() ); ?>" class="cart-contents <?php echo esc_attr( $icon_type ); ?>" title="<?php esc_attr_e( 'View your shopping cart', 'gp-premium' ); ?>"><?php echo $icon; ?><span class="amount"><?php if ( WC()->cart->subtotal > 0 ) { echo wp_kses_data( WC()->cart->get_cart_subtotal() ); } ?></span></a>
    	<?php
    	return ob_get_clean();
    }
    #684919
    Brad

    Thanks for the reply. I was at Wordcamp Los Angeles this weekend. My apologies on the delay reply. I just tried amending the function with the snippet changes above. Unfortunately the same results:

    https://www.dropbox.com/s/1wq6wcerxbay88y/Screen%20Shot%202018-09-24%20at%205.13.29%20AM.png?dl=0

Viewing 15 posts - 1 through 15 (of 20 total)
  • You must be logged in to reply to this topic.