Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • luismi Friend
    #683842

    Hey Guys,

    On the homepage in “Upcoming new events” module title, we have a “small font” first word and a second one bigger.

    I need to increase the number of characters in the first smaller word.

    Can you please tell me how to do this.

    Cheers,

    Ninja Lead Moderator
    #683984

    Hi,

    You will see that see style below into templates/ja_charity/css/template.css file to work with smaller word in “Upcoming new events” module title

    .mod-title .first-word {
    font-family: "Lato", Helvetica, Arial, sans-serif;
    display: block;
    font-weight: 400;
    line-height: 2;
    font-size: 22px !important;
    }

    and you need to create the custom templates/ja_charity/css/custom.css file and add new rule

    .mod-title .first-word {
    font-size: 22px !important;
    }

    Hope it helps

    Regards

    Ninja Lead Moderator
    #748579

    Hi,

    In this case, you have to customise it from JS file

    Below are my workaround:

    – Open the file: templates/ja_charity/js/script.js
    – Find and change:


    $('.mod-title').each(function(){
    var me = $(this);
    me.html(me.html().replace(/^(w+)/, '<small class="first-word">$1</small>'));
    });

    to

    $('.event-slider h2.mod-title').each(function(){
    var me = $(this);
    var string_replace = '';
    var matches = me.html().match(/b[^ds]+b/g);
    if (matches.length >= 2) {
    for (var i = 0; i < 2; i++) {
    string_replace = string_replace + matches + ' ';
    };
    me.html(me.html().replace(string_replace, '<small class="first-word">'+string_replace+'</small>'));
    }

    });

    You can change the value in red as above if you want to increase to number greater than 2

    Hope it helps

    Regards

    luismi Friend
    #684179

    It worked just fine.

    Thanks for your help

    luismi Friend
    #748643

    It worked just fine.

    Thanks for your help

Viewing 5 posts - 1 through 5 (of 5 total)

This topic contains 5 replies, has 2 voices, and was last updated by  luismi 9 years, 2 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum