WP-Sticky New Ideas

I was thinking of not using the wp_postmeta table to tell where a post is sticky or not. Instead, I will use a new table called wp_poststicky to denotes all posts sticky status. Whenever you create a new post, a new row will be created in the wp_poststicky table.

0 will denote normal posts
1 will denote sticky posts
2 will denote announcement post.

Now I need to explain what is the difference between sticky posts and announcements posts.

Currently sticky posts are posts which will appear at the top of the page, I will change that name to be called announcement posts instead.

Now sticky posts will be referred as posts that will only stay on top of all the posts which is posted on the same day as the sticky post. My command of English is not that good, hope you are understand what I mean with the following example:

Announcement
- Post 5 (Announcement Post)

29th March 2007
- Post 6
- Post 7
- Post 8

28th March 2007
- Post 4 (Sticky Post)
- Post 1
- Post 2
- Post 3

As you can see, Post 4 is a sticky post and it will stay on top of all posts that is posted on 28th March 2007 ONLY, posts that are posted after 28th March 2007 (eg. 29th March 2007) will still be on top of the sticky post that is posted on 28th March 2007.

But for Post 5, which is an announcement post, it will stay on top of all posts.

Think of it as a feature in forum softwares in which announcement will appear in all forums and sticky topics will only appear in a particular forum.

This feature will be in the final version of WP-Sticky 1.00. Other features planned for future versions include auto un-announce, auto un-sticky posts after a certain number of days of date.

*UPDATED* 3rd December 2007
Uncle Bubba wrote:
When you login and write/manage a post you’ll see “Post Sticky Status” down in the lower right hand corner. There are three options “Announcement”, “Sticky”, and “None”. Announcement makes a post always on top no matter what. Sticky keeps it at the top of that day’s posts. So, say you made 4 posts on Wednesday and made one sticky, the sticky one would stay on top of Wednesday’s posts. If you then make a post on Thursday it will appear on top of all of Wednesday’s posts but underneath the Announcement post.

Email This Post Email This Post Print This Post Print This Post

1 Star2 Stars3 Stars4 Stars5 Stars (140 votes, average: 3.98 out of 5)
Loading ... Loading ...

 

93 Responses to “WP-Sticky New Ideas”

  1. Giovanni Putignano's Avatar
    Giovanni Putignano Says:

    So it could be better to have many sticky post and one only announcement post. What do you think?

    Giovanni Putignano did not rate this post.
  2. GaMerZ's Avatar
    GaMerZ Says:

    it is unlimited and up to you to decide =D

    GaMerZ did not rate this post.
  3. Mosey's Avatar
    Mosey Says:

    I like the new idea :) But because I get confused easily…so just wanted to clarify: if someone wanted a post to stay for aperiod between 26th-29th March 2007, they would just change the post date to the 29th March 2007?
    Thanks :D

    Mosey did not rate this post.
  4. GaMerZ's Avatar
    GaMerZ Says:

    he should post that under Announcment Post instead of sticky post. Sticky post I think should not have date range.

    GaMerZ did not rate this post.
  5. Dax Desai's Avatar
    Dax Desai Says:

    Nice. So this is more of a daily announcement. Useful for regularly updated sites. What about setting an expiration?

    ie I only want the announcement to expire after 1 week?

    Dax Desai did not rate this post.
  6. GaMerZ's Avatar
    GaMerZ Says:

    yea I intend to have X amount of days or a specific date

    GaMerZ did not rate this post.
  7. GaMerZ.WordPress » Blog Archive » This Is An Announcement's Avatar
    GaMerZ.WordPress » Blog Archive » This Is An Announcement Says:

    [...] Want to know what is the difference between Announcement Posts and Sticky post? Check it out here. [...]

  8. milko's Avatar
    milko Says:

    What do you think about a Sticky-Picture before the post-name? Like:

    *picture* Sticky post name

    sticky post text…..

    milko did not rate this post.
  9. GaMerZ's Avatar
    GaMerZ Says:

    hmmm possible but need some hack

    GaMerZ did not rate this post.
  10. KA's Avatar
    KA Says:

    Excellent… Have been looking for something like this since upgrading to 2.1. Used to use Adhesive but it is no longer updated so this is a life-saver.

    KA did not rate this post.
  11. Nicole's Avatar
    Nicole Says:

    Cool :D

    Nicole did not rate this post.
  12. Gabriel's Avatar
    Gabriel Says:

    teste

    Gabriel did not rate this post.
  13. SQKIKI’s DisneyPlan » Blog Archive » Sticky Post Plugin For Wordpress's Avatar
    SQKIKI’s DisneyPlan » Blog Archive » Sticky Post Plugin For Wordpress Says:

    [...] New features have been added in this plugin, read more on what is the difference between sticky posts and announcements posts from here. [...]

  14. Noryakam's Avatar
    Noryakam Says:

    Maybe the user should be able to decide the sitcky posts scope. It could be category instead of date, for example. It would be very good if the user could choose among some options (category, day, week, month, author,etc).

    Think about it!!

    Noryakam did not rate this post.
  15. GaMerZ's Avatar
    GaMerZ Says:

    I don’t get you

    GaMerZ did not rate this post.
  16. David's Avatar
    David Says:

    Hello –

    How in the world do I use this plug in? Where do I tell Wordpress to make it sticky? I’m using the Connections theme; will it work with that?

    I’ve installed the plugin and activated it, but don’t see any changes on my “Write” or “Manage” posts screens.

    Thanks for the plug-in, David

    David did not rate this post.
  17. GaMerZ's Avatar
    GaMerZ Says:

    Did u read the readme.html?

    GaMerZ did not rate this post.
  18. Web Latam's Avatar
    Web Latam Says:

    Excellent.!

    Web Latam did not rate this post.
  19. sai's Avatar
    sai Says:

    Good Info. Thank you!

    sai did not rate this post.
  20. Thomas Clausen's Avatar
    Thomas Clausen Says:

    It would be cool if one could choose a different background for the sticky and announcement posts. Then people could see that this post was different, as in not chronological.

    Thomas Clausen did not rate this post.
  21. GaMerZ's Avatar
    GaMerZ Says:

    in the final version there is 2 condition statement called is_announcement() and is_sticky(), you can use that to determine if a post is sticky or not =D

    GaMerZ did not rate this post.
  22. Usayd's Avatar
    Usayd Says:

    Thank you very much for sorting this plugin out. Using a combination of if statements I’ve got this going pretty well. Thanks.

    Usayd did not rate this post.
  23. GaMerZ's Avatar
    GaMerZ Says:

    no problem =D

    GaMerZ did not rate this post.
  24. ovidiu's Avatar
    ovidiu Says:

    hello,

    I need some help and info with this plugin.
    I am currently planning to make a wordpress based site for a small local newspaper. They would need the ability to choose which articles get shown on the frontpage when they publish them.

    So as they do publish twice a week your plugin with the new sticky feature would be great, right? but how would I have to use the loop to get 1 post from each category shown on the frontpage? I mean if I get 1 psot from every category shown on the frontpage, the sticky one will always be shown, right?

    Or do you have any other ideas how I could make this?

    I thought of using a plugin which shows the latest post from each category on the frontpage, but they don’t like this idea. They need to specify which psot is shown from each vategory, as they would choose the most important and best article for the frontpage…

    ovidiu did not rate this post.
  25. GaMerZ's Avatar
    GaMerZ Says:

    Easy, on the front page you can use a if(is_sticky()) then show the post, else do not show it.

    GaMerZ did not rate this post.
  26. ovidiu's Avatar
    ovidiu Says:

    could you please elaborate a little more? I am not sure I understood you right :-)

    did you mean I have to make a loop that shows the latest post from every category and then filter out the sticky ones? how would I only get the latest sticky post from each category?

    imagine this: the newspaper has one author for each category, so this guy has to somehow be able to determine which post from the lets say 5 posts per edition he wants shown o nthe frontend. would it be enough if he just made one of them sticky?
    what would happen when he writest the next batch of articles, a week later and marks another post as sticky?

    what kind of loop would I need on the main page exactly?

    ovidiu did not rate this post.
  27. GaMerZ's Avatar
    GaMerZ Says:

    You almost got it. You need a loop that perhaps loop through 2 weeks worth of post (the option can be set in wp-admin) and then use the is_sticky() to check out which are the sticky post and display it.

    GaMerZ did not rate this post.
  28. Huan's Avatar
    Huan Says:

    Good post.

    Huan did not rate this post.
  29. John Derrick's Avatar
    John Derrick Says:

    This is exactly what I was looking for. I will have to play with this and see how it is best to integrate it.

    Thanks,
    John Derrick

    John Derrick did not rate this post.
  30. matteo's Avatar
    matteo Says:

    nice plugin, Thanks!

    matteo did not rate this post.
  31. dua's Avatar
    dua Says:

    Hey whats up

    dua did not rate this post.
  32. Vinicius Ruoso's Avatar
    Vinicius Ruoso Says:

    Nice plugin. Keep the good work. Thanks a lot.

    Vinicius Ruoso did not rate this post.
  33. Hilton's Avatar
    Hilton Says:

    Thank you so much.. that information is great and im just teaching some of my work mates how to implement that plugin… love you man
    from Johannesburg, South Africa

    Hilton did not rate this post.
  34. GaMerZ's Avatar
    GaMerZ Says:

    thanks guys =)

    GaMerZ did not rate this post.
  35. rey's Avatar
    rey Says:

    what plug-in you used in this comment…? where you can display country and the os and browser?

    rey did not rate this post.
  36. GaMerZ's Avatar
    GaMerZ Says:

    it is call firestats

    GaMerZ did not rate this post.
  37. ??? - ??'s Avatar
    ??? - ?? Says:

    [...] Want to know what is the difference between Announcement Posts and Sticky Posts? Check it out here. [...]

  38. BigadicMania's Avatar
    BigadicMania Says:

    Thank you!

    BigadicMania did not rate this post.
  39. FallenMax's Avatar
    FallenMax Says:

    Why no one use Opera?

    FallenMax did not rate this post.
  40. GaMerZ's Avatar
    GaMerZ Says:

    i got opera, ie and FF =D

    GaMerZ did not rate this post.
  41. fatbastard's Avatar
    fatbastard Says:

    props gamerz. have recently run into your wp tools and can’t believe the selection and quality. you crank these things out! so thanks. if my blogs ever turn a profit it will in no small part be because of these scripts. donations will follow. :)

    fatbastard ratings for this post: fatbastard gives a rating of 5fatbastard gives a rating of 5fatbastard gives a rating of 5fatbastard gives a rating of 5fatbastard gives a rating of 5
  42. GaMerZ's Avatar
    GaMerZ Says:

    thanks =D

    GaMerZ did not rate this post.
  43. DogWings's Avatar
    DogWings Says:

    I’m using two of your plugins, and they work very well. I pulled out my credit card and was all set to donate $5. Then I saw that for some reason you have a minimum of $10. Since I can’t give you the $5, I’ll just say thank you for the great plugins.

    DogWings did not rate this post.
  44. GaMerZ's Avatar
    GaMerZ Says:

    Oh, you can give me $5 if you go to paypal direct =) my paypal email is gamerz84 AT hotmail DOT com =D

    GaMerZ did not rate this post.
  45. Awkvart's Avatar
    Awkvart Says:

    Hi, I may have a weird question but I can’t find how this plugin is working… What is the function we call (php get_sticky…) to make the announcement appear exactly where I want it to? I’ve read the readme files, plus all the topics in the forum and I might be dumb but I really don’t get it. I can check the post as a sticky/announcement but it doesn’t appear anywhere in the page since no function is called. And in Options > Sticky I don’t see any way to configure anything. Maybe the solution to this is easy but I’m sorry I really don’t get it. Any help is more than welcome, thanks a lot :)

    Awkvart did not rate this post.
  46. GaMerZ's Avatar
    GaMerZ Says:

    You can’t make it appear exactly where you want to. It will always be the first post.

    GaMerZ did not rate this post.
  47. Awkvart's Avatar
    Awkvart Says:

    Huh ok… But what if I want the annoucement post to be on the top of the page, way above all the other posts, with a banner in between? So you mean an annoucement will only be on the top of the posts, no way to customise anything from that? So we can’t work with any layout? Your plugin is very cool but wouldn’t it be a good idea to create a function like get_annoucement_post and get_sticky_post we could put exactly where we want them to appear on the page and then define the number on posts to display (and a class) for each function? It could make WP Sticky more flexible. I will use your plugin anyway because it’s great, these are ideas only, since WP Sticky is still in beta version, you care doing something with them ^^

    Awkvart did not rate this post.
  48. GaMerZ's Avatar
    GaMerZ Says:

    It is possible, you can check whether a post is sticky or announcement using php codes. I think there is some topic posted in http://forums.lesterchan.net.

    You can check it out, if you can’t find it, maybe you can create a thread.

    GaMerZ did not rate this post.
  49. videokeman's Avatar
    videokeman Says:

    wow this plugin rocckz… just what i needed on my site. thanks a lot for this gamerz

    videokeman did not rate this post.
  50. Sandeep's Avatar
    Sandeep Says:

    Wow…….

    Sandeep did not rate this post.
  51. Kym's Avatar
    Kym Says:

    Hi,

    I’m hoping this will do what I’m hoping I need it to do. I want a plugin where I can choose certain posts and sticky them to the homepage so readers can see the hot topics I want them to see.

    Is this going to show at the top of the page or in a side bar?

    Can I choose more than one post to sticky?

    Is there a place to see what it will look like when installed?

    Thank you :)

    Kym did not rate this post.
  52. GaMerZ's Avatar
    GaMerZ Says:

    It will show on top of the page and if you are using recent post on the sidebar, it will be on top also.

    Yes you can.

    Check out the Plugin Screenshot link on the right sidebar under Blogroll

    GaMerZ did not rate this post.
  53. Rob's Avatar
    Rob Says:

    GaMerZ, I think what Noryakam meant was this:

    Say you wanted to have an explanation post in the archives of each category. This post could tell you what that category was all about. Having it “stick” at the top of each category would be great.

    This is the type of functionality I would like, to choose between date and category for the stickiness.

    Rob did not rate this post.
  54. Rob's Avatar
    Rob Says:

    Oops, I see now that the category display is already a feature!

    Any way of making that post not show up on the main index page? Also, even with the option to not display date, the date still shows for me, even with the WP default theme.

    Rob did not rate this post.
  55. GaMerZ's Avatar
    GaMerZ Says:

    Unless you do some if else checking.

    The default theme by default did not use the_date() and hence it uses the_time() and the_time() will always show.

    GaMerZ did not rate this post.
  56. TWD's Avatar
    TWD Says:

    Hi, it’s working well. I wanted to remove the “Announcement” that appears at the top of the sticky post. I did it at line 113, right after
    case 2:

    $temp = $before.__(’Announcement’, ‘wp-sticky’).$after;

    removing Announcement, but leaving the two single quotation marks.
    GaMerZ, let me know if there’s a better way.

    TWD did not rate this post.
  57. veryid's Avatar
    veryid Says:

    it is z good idea,but “posted on the same day”?? the sticky posts?
    i think ,the same weeks,may be batter.

    do you think?

    veryid did not rate this post.
  58. GaMerZ's Avatar
    GaMerZ Says:

    @TWD: You can change the text via options? WP-Admin -> Options -> Sticky?
    @veryid: No, same week will be not much different from announcement. I based my idea on http://csnation.net actually.

    GaMerZ did not rate this post.
  59. Blooobs's Avatar
    Blooobs Says:

    Hello
    great plugin.

    Thanks

    Blooobs did not rate this post.
  60. Adam's Avatar
    Adam Says:

    Is it possible to have a different announcement post for each category.

    Lets says I have 3 categories: Jobs, Real Estate, Health
    and I want my visitors to see a different announcement in each of those categories.

    Would I be able to create 3 DIFFERENT announcements and assign them to the respective category, so that visitors will see a different announcement post in each of the 3 categories.

    Or is it that you can only create 1 announcement post that will be desplayed across all categories?

    Thanks
    Adam

    Adam did not rate this post.
  61. GaMerZ's Avatar
    GaMerZ Says:

    Adam: Replied You in the forums

    GaMerZ did not rate this post.
  62. aswind's Avatar
    aswind Says:

    nice work. Keep on moving.

    aswind did not rate this post.
  63. WordPress Plugin: WP-Sticky's Avatar
    WordPress Plugin: WP-Sticky Says:

    [...] may want to read this post by the plugin author if you have not understood the [...]

  64. WordPress Plugin: WP-Sticky | Hallo World!'s Avatar
    WordPress Plugin: WP-Sticky | Hallo World! Says:

    [...] may want to read this post by the plugin author if you have not understood the [...]

  65. Make a sticky post in WordPress's Avatar
    Make a sticky post in WordPress Says:

    [...] to WP-Sticky New Ideas for more information about the difference. There are also some Options available in Dashboard > [...]

  66. rita hainsworth's Avatar
    rita hainsworth Says:

    So is there a way to have two announcements?….or a sticky that stays at the top of the page, but under the announcement?…that would be really nice.

    rita hainsworth did not rate this post.
  67. GaMerZ's Avatar
    GaMerZ Says:

    you can have as many announcement or sticky, it would get sorted by date/time.

    GaMerZ did not rate this post.
  68. Uncle Bubba's Avatar
    Uncle Bubba Says:

    How about this for a description:

    When you login and write/manage a post you’ll see “Post Sticky Status” down in the lower right hand corner. There are three options “Announcement”, “Sticky”, and “None”. Announcement makes a post always on top no matter what. Sticky keeps it at the top of that day’s posts. So, say you made 4 posts on Wednesday and made one sticky, the sticky one would stay on top of Wednesday’s posts. If you then make a post on Thursday it will appear on top of all of Wednesday’s posts but underneath the Announcement post.

    Uncle Bubba ratings for this post: Uncle Bubba gives a rating of 4Uncle Bubba gives a rating of 4Uncle Bubba gives a rating of 4Uncle Bubba gives a rating of 4Uncle Bubba gives a rating of 4
  69. GaMerZ's Avatar
    GaMerZ Says:

    Thanks Uncle Bubba =) Updated the post =)

    GaMerZ did not rate this post.
  70. Apollos's Avatar
    Apollos Says:

    Great plugin GaMerZ, thanks much.

    Suggestion: Have announcements that only show up for their own category. So I could have an announcement in my “tutorials” catagory, and it would only show up when the tutorials category was being viewed; I could have a separate announcement that showed up when I was viewing the “news” category.

    Thanks again!

    Apollos did not rate this post.
  71. Apollos's Avatar
    Apollos Says:

    Just to clarify, right now the categories only feature seems to be mutually exclusive to a regular home page announcement.

    Apollos did not rate this post.
  72. GaMerZ's Avatar
    GaMerZ Says:

    The categories only in wp-admin -> options -> sticky will do the, in this case you need 2 sticky announcement, one in news category, one in tutorial categories.

    http://forums.lesterchan.net

    GaMerZ did not rate this post.
  73. 5source.com » Blog Archive » test's Avatar
    5source.com » Blog Archive » test Says:

    [...] to know what is the difference between Announcement Posts and Sticky Posts? Check it out here. Displaying WP-Sticky (Inside The WP [...]

  74. Rob Cooper's Avatar
    Rob Cooper Says:

    Lester, what if I’ve got multiple authors on my blog? I’d like to keep them from making a post a sticky or an announcement or changing the status of the current sticky

    has that been considered?

    Rob Cooper did not rate this post.
  75. Herman's Avatar
    Herman Says:

    Lester,

    Does sticky work with version 2.33
    How do you implement it..I couldn’t see documentation
    (except for Uncle Bubba’s comment) ie

    When you login and write/manage a post you’ll see “Post Sticky Status” down in the lower right hand corner. There are three options “Announcement”, “Sticky”, and “None”. Announcement makes a post always on top no matter what

    I don’t see this after activating plugin

    Herman did not rate this post.
  76. GaMerZ's Avatar
    GaMerZ Says:

    yes it does. This is not a support site, http://forums.lesterchan.net

    GaMerZ did not rate this post.
  77. matias's Avatar
    matias Says:

    It will be possible to ad the option to only get a anouncement post in the top of a category selection? would be great to explain wht this category is for.

    matias did not rate this post.
  78. matias's Avatar
    matias Says:

    sorry, i saw in the coments tha this is already implemented.

    matias did not rate this post.
  79. mario's Avatar
    mario Says:

    Is it possible to set a post to status “Announcement” inside one special tag not only inside one special category?

    mario did not rate this post.
  80. GaMerZ's Avatar
    GaMerZ Says:

    nope

    GaMerZ did not rate this post.
  81. mario's Avatar
    mario Says:

    But I think it would be nice to choose between “Categories Only” and “Tags Only”. I know many people who has only Tags anymore - instead of categories.
    Ok, I’m not a programmer, I’m just thinking…. Maybe it’s not possible…

    mario did not rate this post.
  82. GaMerZ's Avatar
    GaMerZ Says:

    I mean it is possible to do it but it is not inside as one of the feature currently, but good suggestion. I will see if i got time to add it in.

    GaMerZ did not rate this post.
  83. Lee's Avatar
    Lee Says:

    Good job :-)

    Lee ratings for this post: Lee gives a rating of 5Lee gives a rating of 5Lee gives a rating of 5Lee gives a rating of 5Lee gives a rating of 5
  84. Nord's Avatar
    Nord Says:

    Hi Lester,

    Nice plugin.

    Is it possible to make an “announcement post” that will ALWAYS appear as the 2nd, 3rd, or 4th post on a blog’s homepage (blog owner can choose position), and perhaps with the option of having a different colored background behind the announcement if we choose?

    I’d be willing to make a nice contribution if this is possible!

    Please let me know - e-mail me or post here.

    Thanks!

    N~

    Nord did not rate this post.
  85. GaMerZ's Avatar
    GaMerZ Says:

    nope, not possible with the position. You can style your own. http://forums.lesterchan.net

    GaMerZ did not rate this post.
  86. problem's Avatar
    problem Says:

    Not matter what I select before publishing my post, it is still as “Normal” in post sticky status after publishing my post.

    I select Sticky and save but it jumps back to normal. I select Announcement and save but it jumps back to normal after save.

    Using WP 2.3.3 and WP-Sticky 1.10.

    problem did not rate this post.
  87. WordPress de Basis 2.5 » Archief » Vertaald: Plugin WP-Sticky's Avatar
    WordPress de Basis 2.5 » Archief » Vertaald: Plugin WP-Sticky Says:

    [...] info kun je vinden op het blog van Lester Chan [...]

  88. Sérgio Nascimento's Avatar
    Sérgio Nascimento Says:

    Exactly what I was looking for.
    Annoucenments are useful in any sort of blog. It should be nice, in some time, to became a WP built-in feature.

    Thanks for the plugin.

    Sérgio Nascimento did not rate this post.
  89. Tom Kelshaw - Digital Strategist's Avatar
    Tom Kelshaw - Digital Strategist Says:

    Your WP-Polls and WP-Sticky plugins have saved me time and made me money. I’ve just donated some cash, keep up the good work, you’re a champion.

    Tom Kelshaw - Digital Strategist did not rate this post.
  90. GaMerZ's Avatar
    GaMerZ Says:

    Thanks for the donations =D

    GaMerZ did not rate this post.
  91. lamer's Avatar
    lamer Says:

    I think the idea is great however I don’t like the “sticky of day” very much. can we make it into “sticky of a Category” thing? Maybe there is an option to choose between the two.
    Your plugins are great. you are a genius, man

    lamer did not rate this post.
  92. GaMerZ's Avatar
    GaMerZ Says:

    You can choose Announcement instead and set to Categories only in the options

    GaMerZ did not rate this post.
  93. Michael Nowak's Avatar
    Michael Nowak Says:

    mDwpgd Blogs rating, add your blog to be rated for free:
    http://blogsrate.net

    Michael Nowak did not rate this post.

Leave a Reply

 

Comments for this post will be closed on 23 August 2008.