title: get top posts link by add_query_arg() in wordpress
body: <p>in wordpress we have <code>add_query_arg()</code> function to generat a url query from public <em>key</em> and <em>value</em> .</p>
  
  <p>i retrive the <strong>cat</strong> link from query with <code>add_query_arg()</code> function like this :</p>
  
  <pre><code>$retrive ='424'; //my custom cat id .
  $postnumber = '5';   
  $my_query = new WP_Query(array('showposts' =&gt; $postnumber , 'cat' =&gt; $retrive));
  $query_name = get_cat_name($retrive);
  $key = 'cat';
  $value = $retrive;
  // generat query link
  $query_link= esc_url( add_query_arg( $key , $value ,site_url('/') ) );
  echo '&lt;a class="btn btn-lg btn-blue" href="'.$query_link.'"&gt;'.$query_name.'&lt;/a&gt;';
  </code></pre>
  
  <p>now ,i want the link of "<strong>top</strong>" and "<strong>rand</strong>" post with <code>add_query_arg()</code> function.
  this is my query's:</p>
  
  <pre><code>$top_query = new WP_Query(array('meta_key'=&gt;'post_views_count','orderby'=&gt;'meta_value_num','showposts'=&gt;$postnumber,'order'=&gt;'DESC'));
  $key = ?;
  $value = ?;
  
  $rand_query = new WP_Query(array('showposts' =&gt; $postnumber , 'orderby' =&gt; 'rand'));
  $key = ?;
  $value = ?;
  </code></pre>
  
  <p><em>(i need this links for my custom tab_widget plugin that user can see the link of other post of current tab.)</em></p>
  
  <p>how can do this ?</p>