Wanna modify VIEW FULL POST

  • ellianpol

    #2161

    Hi, I’m newbie to the forum; I’m Italian and I love Graphene Theme, but I’d like to modify the “VIEW FULL POST” on the homepage slider into ITALIAN WORDS… such as LEGGI TUTTO… where do I have to modify the php code? Thanks in advance, Gianluca

    Anonymous

    #19112

    This is located in the functions.php file. However, it’s not wise to edit core codes. So, I’ll provide a temporary solution… but the PHP Code Wizard will probably have a better alternative using a child theme.

    In the meantime, in your functions.php file… find this line:

    <a class="block-button" href="<?php the_permalink(); ?>"><?php _e( 'View full post', 'graphene' ); ?></a>

    You may change the text ‘View full post’, to whatever you like.

    busgia

    #19113

    Wonderful, it works 🙂 Do you know if is it possible to have the slider in every page too, not only in the home page?

    Anonymous

    #19114

    I believe you can show the same slider on all pages… however, if you want to add different content to each slider, I would recommend a plugin.

    Which are you trying to do?

    busgia

    #19115

    No I wanna show the same slider, but I don’t how. Here it doesn’t run: http://www.aloevera-gel.it

    Anonymous

    #19116

    By “run”, do you mean it’s not sliding?

    It’s running fine for me. What browser are you using?

    busgia

    #19117

    No, I mean that when I go away from home page, for example http://www.aloevera-gel.it/perche-scegliere-forever-living/ the slider doesn’t appear

    Mod

    Kenneth John Odle

    #19118

    Yes, the slider is only meant to work on the front page. But see this post:

    https://forum.graphene-theme.com/graphene-support/displaying-pages-in-the-slider-and-displaying-the-slider-on-all-pages#post-9850

    It may have the answer you are looking for.

    Ken

    Anonymous

    #19119

    Thanks Ken. I couldn’t find that post for the life of me!

    raindance

    #19120

    Syahir helped me with this one and suggested I do the following, which worked perfectly.

    Add this to your child function.php file:

    <?php
    function graphene_filter_gettext( $translated, $original, $domain ) {
    $strings = array(
    'View full post' => 'Read More',
    );
    if ( ! empty( $strings[$original] ) ) {
    $translations = &get_translations_for_domain( $domain );
    $translated = $translations->translate( $strings[$original] );
    }
    return $translated;
    }
    add_filter( 'gettext', 'graphene_filter_gettext', 10, 3 );
    function laura_sharethis (){
    if(!(is_front_page())){
    ?>

    Make the Read More be whatever you want it to be.

Viewing 10 posts - 1 through 10 (of 12 total)

  • 1
  • 2
  • You must be logged in to reply to this topic.