Support » Theme: Gazette » change text – “Older Posts”

  • How do I change the text of “older Posts” and “newer Posts” for navigation?

    I tried line 31 of template-tags.php

    <div class="nav-next"><?php previous_posts_link( __( 'Newer posts', 'gazette' ) ); ?></div>

    to

    <div class="nav-next"><?php previous_posts_link( __( 'Earlier Thoughts', 'gazette' ) ); ?></div>

    but that did not seem to have any affect. I saw there was a bunch of mentions of “older posts” in some .po files – I’m really hoping there is an easier way than going through all that.

    info appreciated,
    Steve

Viewing 6 replies - 1 through 6 (of 6 total)
  • sacredpath

    (@sacredpath)

    Automattic Happiness Engineer

    Hi Steve, what language are you writing in? The .po files are only for language translations, so no need to mess with those.

    Also, if your site is live, can we have a link to it?

    just doing English.

    Site is live, but it is of an adult nature, and I’ve had mixed results with asking for help with links to such via the automattic forums over the years, I get the feeling that they are shunned and brushed off into a kind of quasi-censoring, so I try not to post links to them. Of course if someone is willing to help and really wants to take a look as to what is going on, then I am okay with sharing and even doing a screen share with something like together.js or zoom or something..

    If you know how the grid thing works with this theme, I would love to get some input on that too! I tried changing some of n3 + 3 things, as I made the containers super wide, but the grid just gets all mixed up when I try the n4 +4 and clear right and stuff..

    this theme has some great structure, but some parts could really use a tutorial or something, a lot of thinking went into this I can tell!

    thanks,
    Steve

    sacredpath

    (@sacredpath)

    Automattic Happiness Engineer

    It can be a bit tricky changing the number of posts per row in the grid. Are you talking about in the grid of posts below the featured area?

    sacredpath

    (@sacredpath)

    Automattic Happiness Engineer

    Oh, and I understand on the url and nature of your site. If I need to work off your site, I’ll give you a way to get that URL to me. I can work off the demo site for Gazette typically as long as I know for sure what you are wanting to change.

    “talking about in the grid of posts below the featured area”
    – yes the regular posts – when I have 100 posts I get the Older Posts (left) on bottom of front page to paginate that way, then on the second /page/2 or whatever it’s like Newer Psots to the right..
    “Posts” is not really the best descriptive language for this – so finding a way to change that would be awesome!
    (I found the plugin WP-PageNavi helpful for doing something similar)

    Also moving to 4 columns with the rows would be awesome – I love the way the pinblack theme pulls this off (https://wordpress.org/themes/pinblack/) the amount of rows auto fill or carry over to the next row based on browser size.

    After modding bits here and there with the gazeete and expecting (ahem, assuming) that filling a wide view on 1900 pix screen would be easy, I am scrathing my head on how to add to margin on the left, as I have expanded the container, but the three thumbs are squished to the left and tons of whitespace on the right.

    Help is definitely appreciated, I trust the automattic done themes much more than old ones from unknown folks, and love the commenting in the style.css and stuff a whole lot, lots of appreciation for the not just using this but learning from it.

    sacredpath

    (@sacredpath)

    Automattic Happiness Engineer

    Steve, I worked this out off of the demo site. I’ve limited the 4 column change to screens/windows 1080px and wider since below that width, the posts get too narrow with 4 columns. Give it a try and see what you think and let me know if there are any problems.

    @media screen and (min-width: 1080px) {
      .archive .hentry, .blog .hentry, .search .hentry {
        width: 18% !important;
      }
      .content-area .hentry:nth-of-type(2n+1) {
        clear: none !important;
    		margin-right: 30px;
      }
      .content-area .hentry:nth-of-type(3n+1) {
        clear: none !important;
        margin-left: 30px !important;
        margin-right: 30px !important;
      }
      .content-area .hentry:nth-of-type(4n+1) {
        clear: left !important;
        margin-right: 30px !important;
      }
    	.content-area .hentry:nth-of-type(4n+4) {
    		margin-right: 0 !important;
    	}
    	.content-area .hentry:nth-of-type(3n+3) {
    		margin-left: 30px !important;
    		margin-right: 30px !important;
    	}
    }

    On the Previous and Next buttons, those don’t appear on the demo site. Sometimes we can use custom CSS and a pseudo selector and hide the existing text and add new text with the pseudo selector. The best way to do this though would be with a Child Theme and then copy over and edit the relevant section of the template-tags.php file.

    This is short, but good information on template-tags.php in Child Themes

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘change text – “Older Posts”’ is closed to new replies.