<?php
$rand_posts = get_posts(‘numberposts=10&orderby=rand’);
foreach( $rand_posts as $post ) :
?>
<li><a href=”<?php the_permalink(); ?>”><?php the_title(); ?></a></li>
<?php endforeach; ?>
wordpress display random articles
Related Articles
WordPress functions.php-Add a Sidebar
Adding a Sidebar Our theme also doesn’t have a sidebar (widget area), let’s fix that now. First, we need to register the sidebar in functions.php: function my_custom_theme_sidebar() {register_sidebar( array( ‘name’ => __( ‘Primary Sidebar’, ‘my-custom-theme’ ), ‘id’ => ‘sidebar-1’,) );...
0
0
1
WordPress Tutorial-Install widgets
If you’re looking for extra features, head to the Appearance tab in your dash and click Widgets from the drop-down menu. The widget menu includes the designated areas on your WordPress site where you can place widgets. Clicking on the widget titles...
0
0
0
Hide Plugin From WordPress Dashboard
Do you want to have one or multiple of your WordPress plugins hidden yet still running and fully functional? It is entirely possible and quite easy to do, simply follow these steps: Login to your WordPress dashboard Under Appearance click on Editor Click...
0
0
1
Backup Database from phpMyAdmin
Making backups is necessary for every host and of databases. We want to describe how to make a backup from your host database by using phpmyadmin. Login to Cpanel and find “databases” section. Click on “Phpmyadmin”. After opening, you will...
0
0
0
Comments (0)