-
AuthorPosts
-
August 10, 2014 at 11:07 pm #81959
SEVEROParticipantHi there
Have looked through the forum and have tried a couple of things but haven’t found a solution.
Where do I find this file or what do I need to add to change this?
Cheers
August 10, 2014 at 11:19 pm #81963
Paula SMemberHi Severo,
This is possible by adding a snippet of code onto your child theme’s function.php file. What text would you like it to say? More information can be found here : http://codex.wordpress.org/Customizing_the_Read_More
Let us know if you need further help and we’ll be happy to assist you (as long as it’s within support bounds) Have a nice weekend!
August 10, 2014 at 11:29 pm #81967
SEVEROParticipantHi there
Thanks for the quick reply. I did see this link but couldn’t get it to work.
This is function.php as it stands:
<?php
function x_excerpt_string( $more ) {
$stack = x_get_stack();
if ( $stack == ‘integrity’ ) {
return ‘ … <div>Read More</div>’;
} else if ( $stack == ‘renew’ ) {
return ‘ … Read More‘;
} else if ( $stack == ‘icon’ ) {
return ‘ …’;
}}
add_filter( ‘excerpt_more’, ‘x_excerpt_string’ );And would like to add this:
<?php the_content(‘ Read on…’); ?>
Not too sure where to place it though 🙁
August 11, 2014 at 12:22 am #81975
ChristianModeratorHey Severo,
Please try changing the Read More texts in content.php located at wp-content\themes\x\framework\functions\global\.
Thanks.
August 11, 2014 at 4:15 am #82033
SEVEROParticipantHi there
Yes, tried that with no success 🙁
August 11, 2014 at 4:47 am #82039
ChristopherModeratorHi Severo,
Lets do another thing.
Please go to x/framework/lang/default.poOpen up the po file with poedit software. Search for ‘Read More’ and replace it with desired phrase.
You can find out more about this HERE.
Thank you.
August 11, 2014 at 5:26 am #82050
SEVEROParticipantHi there
Not having a lot of luck. Quick question, why am I getting a ‘Read More’ button here and not on my home page?
http://www.mad-daily.com/?s=CRM
Cheers
August 11, 2014 at 5:37 am #82051
ChristopherModeratorHi Severo,
Would you please tell us what was the problem?
Did you follow the instructions and updated your po file using poedit and still you can not change the read more text?
ThanksAugust 11, 2014 at 5:46 am #82054
SEVEROParticipantPoedit Error
warning: header field ‘Language’ missing in header1 issue with the translation found.
Entries with errors were marked in red in the list. Details of the error will be shown when you select such an entry.
The file was saved safely and compiled into the MO format, but it will probably not work correctly.August 11, 2014 at 5:49 am #82057
ChristopherModeratorWould you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:
– Link to your site
– WordPress Admin username / password
– FTP credentialsDon’t forget to select Set as private reply. This ensures your information is only visible to our staff.
Thank you.
August 11, 2014 at 5:58 am #82064
SEVEROParticipantThis reply has been marked as private.August 11, 2014 at 6:55 am #82091
CousettMemberChanged up some of the php in your function file and I think we got it working.
Changed the PHP to:
<?php function x_child_theme_setup() { // override parent theme's 'more' text for excerpts remove_filter( 'excerpt_more', 'x_excerpt_string' ); remove_filter( 'the_content_more_link', 'x_content_string' ); } add_action( 'after_setup_theme', 'x_child_theme_setup' ); function x_child_excerpt_string( $more ) { $stack = x_get_stack(); if ( $stack == 'integrity' ) { return '<div><a href="' . get_permalink() . '" class="x-btn">Read On ...</a></div>'; } else if ( $stack == 'renew' ) { return ' ... <a href="' . get_permalink() . '" class="x-btn">Read More</a>'; } else if ( $stack == 'icon' ) { return ' ...'; } } add_filter( 'the_content_more_link', 'x_child_excerpt_string' ); ?>Hope this helps.
August 11, 2014 at 7:45 am #82114
SEVEROParticipantWOW!!! Thank you very much 🙂
One last thing which I cam’t seem to figure out. How would I drop the button down about 20px?
Cheers
August 11, 2014 at 7:48 am #82115
ZeshanMemberHi Servo,
Thank you for writing in!
Please add the following CSS:
.x-btn { margin-top: 20px; }Cheers!
August 11, 2014 at 7:53 am #82121
SEVEROParticipantLEGEND!!
Thank you very much:)
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-81959 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
