Skip to content

Instantly share code, notes, and snippets.

@Preciousomonze
Last active January 26, 2023 21:41

Revisions

  1. Preciousomonze revised this gist Jan 26, 2023. 1 changed file with 4 additions and 7 deletions.
    11 changes: 4 additions & 7 deletions p.js
    Original file line number Diff line number Diff line change
    @@ -1,17 +1,14 @@
    jQuery( function($) {
    $( document ).ready( function() {

    $( document ).on( 'click', '.ola-section-readmore', function( event ) {
    event.preventDefault();
    console.log("workssss");
    // Get the clicked element section cover.
    $_ParentEL = $(this).closest( '.ola-section-cover' );

    // Now trigger the necessary for the clicked item.
    $_ParentEL.find( '.short_d' ).css( 'display', 'none' );
    $_ParentEL.find( '.full_d' ).css( 'display', 'block' );
    });
    $_ParentEl = $(this).closest( '.ola-section-cover' );

    // Now trigger the necessary for the clicked item.
    $_ParentEl.find( '.short-d' ).css( 'display', 'none' );
    $_ParentEl.find( '.full-d' ).css( 'display', 'block' );
    });

    });
  2. Preciousomonze revised this gist Jan 26, 2023. 1 changed file with 5 additions and 4 deletions.
    9 changes: 5 additions & 4 deletions p.js
    Original file line number Diff line number Diff line change
    @@ -1,15 +1,16 @@
    jQuery( function($) {
    $( document ).ready( function() {
    function showFullDesc(event, c) {

    $( document ).on( 'click', '.ola-section-readmore', function( event ) {
    event.preventDefault();

    console.log("workssss");
    // Get the clicked element section cover.
    $_ParentEL = $(this).closest( '.section_cover' );
    $_ParentEL = $(this).closest( '.ola-section-cover' );

    // Now trigger the necessary for the clicked item.
    $_ParentEL.find( '.short_d' ).css( 'display', 'none' );
    $_ParentEL.find( '.full_d' ).css( 'display', 'block' );
    }
    });

    });

  3. Preciousomonze revised this gist Jan 26, 2023. 1 changed file with 5 additions and 1 deletion.
    6 changes: 5 additions & 1 deletion p.js
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,6 @@
    jQuery( function($) {
    function showFullDesc(event) {
    $( document ).ready( function() {
    function showFullDesc(event, c) {
    event.preventDefault();

    // Get the clicked element section cover.
    @@ -9,4 +10,7 @@ jQuery( function($) {
    $_ParentEL.find( '.short_d' ).css( 'display', 'none' );
    $_ParentEL.find( '.full_d' ).css( 'display', 'block' );
    }

    });

    });
  4. Preciousomonze created this gist Jan 26, 2023.
    12 changes: 12 additions & 0 deletions p.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,12 @@
    jQuery( function($) {
    function showFullDesc(event) {
    event.preventDefault();

    // Get the clicked element section cover.
    $_ParentEL = $(this).closest( '.section_cover' );

    // Now trigger the necessary for the clicked item.
    $_ParentEL.find( '.short_d' ).css( 'display', 'none' );
    $_ParentEL.find( '.full_d' ).css( 'display', 'block' );
    }
    });