• Resolved tommytomato

    (@tommytomato)


    Hi all

    I’m uisng the theme HostingPlatino on my word press, HostingPlatino has a frame.php that loads in the front page, its shows latest post and latest links

    I worked out how to limit the number of links shown by using smooth-scrolling-links-ssl plugin, to which it works great.

    How can I limit the number of lastest post shown in the frame.php, is this set to show 10 only? or will it grow to a long list ?

    <?php $my_query = new WP_Query('showposts=10');	?>
    					<?php while ($my_query->have_posts()) : $my_query->the_post(); $shorttitle = substr(the_title('','',FALSE),0,39); ?>
                             <li><a title="<?php echo the_title() ?>" href="<?php the_permalink() ?>">

    Question what does FALSE),0,39); Mean ?

    Hope someone can shed some light please

    TT

    `

Viewing 5 replies - 1 through 5 (of 5 total)
  • Can’t help with your plugin/theme specific issues, but the FALSE),0,39) bits mean …

    false , so the value can be stored (echo=false)..
    0 = the position in the string to start storing data from
    39 = the ending position of a string to store data from

    The values represent arguments for the functions being called, in this case, substr (a php function), and the_title (a wordpress specific function).

    Thread Starter tommytomato

    (@tommytomato)

    Thank you, so it has nothing to do with the amount of post

    I’ve got the site sitting on local host ( personal PC ) its not live yet

    but i will show it off very soon

    TT

    This area represents the amount of posts to show.

    showposts=10

    Thread Starter tommytomato

    (@tommytomato)

    Thanks

    I was wondering because when it shows all latest post under my frame.php it didn’t stop at 10 post, it kept listing them ???

    Since then I replace that area with a login box ( sidebar-login.2.2.7 )

    but now the latest post shown on the bottom have stop showing new post ???

    take a look here http://www.rockinghamgateway.com/?page_id=70 last post i did was party plus

    looking on the home page at the bottom it doesn’t show the latest post for party plus ???

    Is this because I replaced the <?php $my_query = new WP_Query(‘showposts=10’); ?>

    for ( sidebar-login.2.2.7 ) in my frame.php

    TT

    Possibly, but sorry i’m not familiar with either the theme nor the plugin.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Limit the amount of latest post’ is closed to new replies.