Viewing 18 posts - 1 through 18 (of 18 total)
  • Author
    Posts
  • #853373

    Hi,
    http://www.newyorkhotellbokning.se
    I added this code to the functions.php
    function new_excerpt_more( $more ) {
    return ‘ ‘ . __(‘Read More’, ‘your-text-domain’) . ‘‘;
    }
    add_filter( ‘excerpt_more’, ‘new_excerpt_more’ );

    and then it came out like this
    functions

    What is wrong with the code?
    I got it from this page: https://codex.wordpress.org/Excerpt

    Thanks
    Charlotte

    #853701

    Hey Charlotte,

    It looks like you removed a lot of the return text, try this instead:

    function new_excerpt_more( $more ) {
    	return ' <a class="read-more" href="'. get_permalink( get_the_ID() ) . '">' . __('Read More', 'your-text-domain') . '</a>';
    }
    add_filter( 'excerpt_more', 'new_excerpt_more' );

    Best regards,
    Rikard

    #853789

    Thanks Rikard but it looks the same
    functions

    I have delete the code, maybe you can login and try, thanks.
    Charlotte

    #854373

    Hi Charlotte!

    Can you please post FTP logins here privately as well? I was adding the code to functions.php file but noticed one more issue right after i saved the file. Sorry about that!

    Best regards,
    Yigit

    #854382

    Hi Yigit.

    Here comes the ftp login
    Thanks
    Charlotte

    #854389

    Hey!

    Folder shows up empty when i access via FTP. Can you please check accounts path and permissions once again?

    Cheers!
    Yigit

    #854391

    Ah… sorry. Now it is working!

    #854399

    Hey

    I corrected the issue and added the code to functions.php file. Please review your website :)

    Regards,
    Yigit

    #854401

    Thanks Yigit :)

    But the link for Read more is still not visible.. is because I have added the excerpt manually?

    #855183

    Hi,

    I’m sorry but I can’t access the site because of the following error.

    Parse error: syntax error, unexpected ‘<' in /home/d8737/newyorkhotellbokning.se/wp-content/themes/enfold-child/functions.php on line 16

    Please revert the functions.php file back to default. Please don’t forget to wrap the php codes inside the opening and closing php tags. This is the same issue with your other thread.

    <?php
    
    // codes here
    
    ?>
    

    Best regards,
    Ismael

    #855281

    Hi Ismael,

    can you login to the server then?
    Thanks

    #855654

    Hi,

    I can’t access the file server. Is it limited to a certain IP address or country?

    // https://kriesi.at/support/topic/excerpt-4/

    Best regards,
    Ismael

    #860600

    Hello,

    I have tried fixing an error on the site following the instructions found on this support forum. The error said:
    “Warning: mysql_real_escape_string(): Access denied for user ‘swaneven’@’localhost’ (using password: NO) in /home/swaneven/public_html/wp-content/themes/replete/framework/php/class-framework-widgets.php on line 1322

    Warning: mysql_real_escape_string(): A link to the server could not be established in /home/swaneven/public_html/wp-content/themes/replete/framework/php/class-framework-widgets.php on line 1322”

    It didn’t work and I’ve encountered a bigger issue which doesn’t let me access the site anymore:
    “Parse error: syntax error, unexpected ‘\’ (T_NS_SEPARATOR), expecting ‘)’ in /home/terenuri/public_html/wp-content/themes/enfold/functions.php on line 23”

    Now the website is not available at all. Could you please help me?
    Thanks
    Adrian

    #860881

    Hi Adrian,

    Could you try updating the theme to the latest version (4.1.2) to see if that helps please? http://kriesi.at/documentation/enfold/updating-your-theme-files/

    Best regards,
    Rikard

    #861339

    Hello Rikard,
    Thank you for your reply.
    Unfortunately I cannot access the platform anymore and can’t update or edit anything because I cannot enter it…
    Thanks again,
    A.

    #861514

    Hi,

    Ok, thanks for the feedback. The only option for you then is to overwrite the theme via FTP, you will find instructions on how to do that in the link I sent. Under the Update Manually via FTP header.

    Best regards,
    Rikard

    #861645

    Hi,

    this is already solved when I reinstalled the theme.

    thanks Charlotte

    #861816

    Hi Charlotte,

    Thanks for the feedback, I’ll go ahead and close the thread then.

    Best regards,
    Rikard

Viewing 18 posts - 1 through 18 (of 18 total)
  • The topic ‘Error in functions.ph’ is closed to new replies.