Title: Vikram S Sangotra's Replies | WordPress.org

---

# Vikram S Sangotra

  [  ](https://wordpress.org/support/users/vikkram/)

 *   [Profile](https://wordpress.org/support/users/vikkram/)
 *   [Topics Started](https://wordpress.org/support/users/vikkram/topics/)
 *   [Replies Created](https://wordpress.org/support/users/vikkram/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/vikkram/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/vikkram/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/vikkram/engagements/)
 *   [Favorites](https://wordpress.org/support/users/vikkram/favorites/)

 Search replies:

## Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)

 *   Forum: [Developing with WordPress](https://wordpress.org/support/forum/wp-advanced/)
   
   In reply to: [get_pages & number](https://wordpress.org/support/topic/get_pages-number/)
 *  Thread Starter [Vikram S Sangotra](https://wordpress.org/support/users/vikkram/)
 * (@vikkram)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/get_pages-number/#post-9739730)
 * Hello [@bcworkz](https://wordpress.org/support/users/bcworkz/),
 * As per your suggestions I tried :
 * 1) **child_of** & it doesn’t work with **number**.
    2) **parent** it ignores **
   number**
 * 🙁 Any more suggestions.
 * Thanks again,
    Vikram
 *   Forum: [Developing with WordPress](https://wordpress.org/support/forum/wp-advanced/)
   
   In reply to: [get_pages & number](https://wordpress.org/support/topic/get_pages-number/)
 *  Thread Starter [Vikram S Sangotra](https://wordpress.org/support/users/vikkram/)
 * (@vikkram)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/get_pages-number/#post-9728922)
 * Hi [@bcworkz](https://wordpress.org/support/users/bcworkz/) – good morning,
 * Ok – I got third level parents and have used it in ‘child_of’ like :
 * `$parent_four=get_pages( array('parent'=>$parent_three_id, 'child_of'=>$parent_three_id,'
   number'=>2,'sort_column'=>rand) );`
 * Now what happens is **number->2** gives me **2 child pages** of each parent. 
   So I made little adjustments by displaying 4 columns – till this it is absolutely
   fine.
 * But what if in future when there’ll be 3 or more parents? 😀 😀 😀
 * Please advise.
 * Thanks again,
    Vikram
 *   Forum: [Developing with WordPress](https://wordpress.org/support/forum/wp-advanced/)
   
   In reply to: [get_pages & number](https://wordpress.org/support/topic/get_pages-number/)
 *  Thread Starter [Vikram S Sangotra](https://wordpress.org/support/users/vikkram/)
 * (@vikkram)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/get_pages-number/#post-9724863)
 * Hello [@bcworkz](https://wordpress.org/support/users/bcworkz/),
 * Thanks for your detailed reply. Things at my ends are like :
 * a) 2 Main Categories
    b) Both these categories have 4-4 sub categories c) These
   sub categories are having content pages. e) I want to show 3 random content pages(
   from random sub categories) in 2 different sections ie. main categories. f) In
   future Main Categories &/or Sub Categories may increase.
 * I may be making it more complex. And I also think there should be simpler way
   to present it.
 * Please advise.
 * Thanks again,
    Vikram

Viewing 3 replies - 1 through 3 (of 3 total)