Advanced Random Posts Widget displays your posts by selecting randomly. It gets posts from selected categories or current category or all posts. When your visitors are at home, it gets posts from all posts or selected category. If you set 'Get posts from current category', when visitors see single post, widget lists posts in the same categories of single post or when visitors click a category link, it gets posts from current category. At now, plugin could display thumbnails of your posts. (sorry, my English is poor)
Installation
- Make sure you are running WordPress version 2.8 or better. It won't work with older versions. If you use older versions, please download "Advanced Random Posts v1.1".
- Download the zip file and extract the contents.
- Upload the 'advanced-random-posts' folder to your plugins directory (wp-content/plugins/).
- Activate the plugin through the 'plugins' page in WordPress.
- See 'Appearance'->'Widgets' to place it on your sidebar. Set the settings
If you don't use 'Widgets', add following codes in your 'sidebar.php' to place 'Random Posts' on your sidebar. Change the parameters as you want:
-
<li><h2><?php echo 'Random Posts'; ?></h2>
-
<ul>
-
<?php
-
'limit' => 10, //Number of posts to show
-
'excerpt' => 60, //excerpt length (letters)
-
'actcat' => false, //get posts current category
-
'cats' => '5,6', //Categories to get posts
-
'cusfield' => 'thumbnail', //custom field name of thumbnail image
-
'w' => 48, //width
-
'h' => 48, //height
-
'firstimage' => true, //get first image of post content
-
'atimage' => false, //get first attached image of post
-
'defimage' => 'http://www.yakupgovler.com/default.jpg' //default thumbnail image
-
);
-
//print random posts
-
yg_randomposts($parameters);
-
?>
-
</ul>
-
</li>
-
<?php } ?>
FAQ
How can I set it to get posts from current category?
Select checkbox on widget's settings called 'Get posts from current category'.
I want to display only the posts in two categories.
You have to write their category's ids -seperated with a comma- to 'Categories to get posts' textbox.
Screenshots

Widget's screenshot in 'Apperance'->'Widgets'
Options
Widget's options allow you to change your random posts list displaying.
Title - Your random posts widget's title on your sidebar.
Number of posts to show - How many posts to display
Excerpt length (letters) - You know that
Thumbnail Custom Field Name - If you want to display the thumbnail of your posts via a custom field, write its name.
Height, Width - Images size.
Get first image of post - If you don't want to use custom field, plugin will get first image from your post content.
Get first attached image of post - Plugin gets first attached image of post.
Default image - If post has no image, plugin display this image. Ex: http://www.yakupgovler.com/default-image.png
Notice: If you use three options, plugin uses custom field image firstly. If the post has no custom field, it gets first image from content. At last it gets first attached image. I suggest not to use "Get first image of post" for performance. It queries much more.
Categories - Plugin gets posts in these categories. (Category IDs, separated by commas.)
Get posts from current category - Posts will be get from current category (single post's category or current category).
Changelog
= 2.2 =
* Added Russian Language Support
= 2.1 =
Fixed a bug. Thanks E.Ali
= 2.0 =
* Adding thumbnail image support
* Rewriten by using WordPress 2.8 Widget Class API
= 1.1 =
*Bug fixed, showing the same post id.
= Version 1.0 =
* Initial release version.
Support Language
* English
* Turkish
* Russian - Thanks Fatcow
Notice: If you translate it in your language, please let me know.
Download
Advanced Random Posts v2.2
Advanced Random Posts v1.1
My English Plugins
- Random Tags Cloud Widget: A fantastic widget to manage your tags cloud.
- Advanced Random Posts: It shows random posts from selected categories or current categories or all posts, it is very useful.
- Advanced Blogroll Widget: display your bookmarks as you want. You can customize your blogroll displaying.
- Comment Approved Notifier Plugin: sends an e-mail to your commenters when you approve their comments.
Bu yazının kısa bağlantısı http://www.yakupgovler.com/?p=416.
Yazılarımı RSS aboneliği ile takip edebilir, yeni yazılarıma kolaylıkla ulaşabilirsiniz. Bunun için ise RSS adresimi kullanabilirsiniz.















Bu yazıya yapılan yorumları dilerseniz, ( 



Tarih: 01 Kasım 2008 Saat: 10:16
[...] Advanced Random Posts Widget von Yakup Gövler zeigt ein zufällig ausgewähltes Posting aus wählbaren [...]
Tarih: 01 Kasım 2008 Saat: 11:35
[...] Advanced Random Posts 31.10.2008 [...]
Tarih: 01 Kasım 2008 Saat: 20:18
Hi
I installed this plugin and it's not working fine in my blog, it shows the titles of the ramdom post but the links are wrong, all of these links are the current post link.
Any tip?
thanks in advance!
Tarih: 01 Kasım 2008 Saat: 21:28
Dear Alturo,
Thank you very much. I fixed it as you see on my sidebar ('Random Posts'). Please, update it.
Tarih: 02 Kasım 2008 Saat: 01:56
[...] Advanced Random Posts Display random posts from selected categories or current category or all posts. Release page [...]
Tarih: 02 Kasım 2008 Saat: 20:13
Thanks, using it.
Tarih: 11 Kasım 2008 Saat: 03:02
Good Work and thanks for this great plugin. Why don't you remove ."\" alt=\"". $post_title , that way there would be no problem with xhtml validation.
Tarih: 21 Kasım 2008 Saat: 09:01
[...] หลังจากที่พยายามมานานในเรื่องการหาปลั๊กอินในการ Random Post ในที่สุดก็ประสบความสำเร็จซักที จริงๆ แล้วมีปลั๊กอินหลายตัวที่น่าใช้มากๆ แต่หลังจากที่ออฟได้ลองลงและลองใช้ก็พบว่าตัวนี้เป็นตัวที่” ใช่ “ที่สุด โดยเฉพาะสำหรับบล็อกของออฟที่ Theme ไม่สนับสนุน Widget ปลั๊กอินตัวนี้ชื่อว่า Advanced Random Posts v1.1 [...]
Tarih: 21 Aralık 2008 Saat: 20:03
nice plugin, i just installed and working well... thank you!
Tarih: 21 Aralık 2008 Saat: 22:37
[...] Advanced Random Posts: It shows random posts from selected categories or current categories or all posts, it is very useful. [...]
Tarih: 22 Aralık 2008 Saat: 07:47
[...] Advanced Random Posts: It shows random posts from selected categories or current categories or all posts, it is very useful. [...]
Tarih: 17 Ocak 2009 Saat: 18:46
[...] Advanced Random Posts -> für die Verwandten Blogeinträge [...]
Tarih: 25 Ocak 2009 Saat: 18:25
Good job! Thanks.
Tarih: 10 Mart 2009 Saat: 16:47
[...] Advanced Random Posts (Version 1.1): Zeigt zufällig irgendwelche Artikel an (bis zu 20), widget-fähig. [...]
Tarih: 17 Nisan 2009 Saat: 02:21
[...] del plugin originale è Yakup [...]
Tarih: 20 Nisan 2009 Saat: 00:37
Aradığım,fakat bulduklarımı beğenmediğim bir eklenti konusuydu. Widget olarak kullanılabilmesi ve ayar yapılabilmesi gerçekten mükemmel. Kullanıyoruum ve sorunsuz çalışıyor, teşekkürler.
Tarih: 22 Nisan 2009 Saat: 22:35
Eklentiyi tema içinde veya yaratılmış bir sayfada nasıl gösterebilirim?
Tarih: 23 Nisan 2009 Saat: 05:46
Yazı içerisindeki
yg_randomposts('limit=10&cats=3,6,8¤tcat=1');
kodunu kullanarak kullanabilirsiniz. Örnek kodda 3. ve 6. kategoriden rastgele 10 tane yazıyı gösteriyor, ayrıca eğer bir kategori tıklanmışsa da sadece o kategorideki yazıları getiriyor.
http://www.yakupgovler.com/?p=386 adresindeki açıklamaları okuyunuz, Türkçe bileşen için onu kullanınız.
Tarih: 01 Mayıs 2009 Saat: 15:02
Hello,
Great plugin but the posts choosen are always the same
I use 2.7.1
Tarih: 30 Mayıs 2009 Saat: 17:27
Hey, thank you for sharing. nice plugin, really useful for my blog. thank you very much.
Tarih: 16 Haziran 2009 Saat: 17:20
[...] View original post here: Advanced Random Posts v1.1 · Yakup Gövler - WordPress'e dair ne varsa [...]
Tarih: 22 Haziran 2009 Saat: 06:55
[...] Advanced Random Posts – after 2+ years of blogging there’s a lot of good content that can easily get buried. [...]
Tarih: 29 Haziran 2009 Saat: 12:38
[...] böyle bir zamanda ulaştım Yakup Gövler‘in eklentisine. Eklenti için söylenecek çok fazla bir şey yok. Blogunuzdaki yazılar içerisinden istediğiniz [...]
Tarih: 09 Ağustos 2009 Saat: 00:19
Working great with WP 2.71.
Now, my theme has a function which returns the thumbnail of the first image of a post, e.g. getpostgk_img($post->ID). I gather it could be added somewhere to Line 111 of your plugin's Php file, where the $postlist string is being built. But where exactly? The best my experimentations have produced so far is the same thumbnail N times followed by the titles of the N random articles.
Suggestions?
Tarih: 09 Ağustos 2009 Saat: 07:01
You can do your codes by adding line 110 like the following if your function returns your images url:
This code will show your image 50x50px size and you can customize it by "randompostimg" class identifier in your style.css, for example to add margin.
If your function returns < *img src="your image url" /> you have to use the following codes.
Please, let me know about results.
Tarih: 29 Ağustos 2009 Saat: 13:23
[...] Advanced Random Posts: It shows random posts from selected categories or current categories or all posts, it is very useful. [...]
Tarih: 29 Ağustos 2009 Saat: 21:00
hi, good job dude
Tarih: 05 Eylül 2009 Saat: 22:15
[...] Advanced Random Posts: It shows random posts from selected categories or current categories or all posts, it is very useful. [...]
Tarih: 07 Eylül 2009 Saat: 04:31
Hi Yakup,
is it possible, that the plugin show just the thumbnails without title and maybe two or three thumbnails in one line instead of just one? It should look like a small random thumbnail gallery in the sidebar.
Cheers and greetings from germany!
Dennis
Tarih: 07 Eylül 2009 Saat: 08:23
Hi Dennis,
Thit is a good idea and It's possible but i am busy at todays so in next week i can add a choice not/to display title.
Thanks.
Tarih: 07 Eylül 2009 Saat: 17:58
Hi Yakup,
yeah that is a great news. Thank you very much!
Dennis
Tarih: 21 Eylül 2009 Saat: 16:44
excellent plugin ... thank you for the time you spend working on it ! one suggestion : it would be nice to have an option for not posting article without thumbnail (posting the result with default image one thumbnail not related to the blog post is not useful ... and sometimes, your plugin doesn't find the image in the blog post)
Tarih: 25 Eylül 2009 Saat: 18:53
hello,
i liked so much the plugins Advanced Most Recent Posts and Advanced Random Posts. But the only thing i would like you improve is the thumb layout. i think it`s better to complete the blank spaces. ( i made the print screen to show you ... http://img268.imageshack.us/i/image1nb.jpg/ )
a tip, u can put like this other plugin
http://alkivia.org/wordpress/sideposts or remove this blank space using the excerpt text.
another tip is option to show the date of the post.
i wait contact, thanks
Tarih: 08 Ekim 2009 Saat: 02:30
[...] http://www.yakupgovler.com/?p=416 [...]