Title: Custom Querystring support
Last modified: November 10, 2020

---

# Custom Querystring support

 *  Resolved [kevinmt](https://wordpress.org/support/users/kevinmt/)
 * (@kevinmt)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/custom-querystring-support/)
 * If I want to pass a single querystring variable ie my.com/fruits/?fruit=apple
   
   can I add the customer variable of fruit and use the plugin to conditionally 
   show or hide an image element? Also will this work if I am using a Pretty URL
   rewrite plugin?

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

 *  Plugin Author [Jonathan Horowitz](https://wordpress.org/support/users/jhorowitz/)
 * (@jhorowitz)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/custom-querystring-support/#post-13641644)
 * Hi [@kevinmt](https://wordpress.org/support/users/kevinmt/),
 * You could use `isset( $_GET['fruit'] ) && $_GET['fruit'] === 'apple'` to show
   if ?fruit=apple is present in the URL.
 * I would say a url rewrite plugin might affect it if it strips the param… what
   would the final url look like?
 *  Thread Starter [kevinmt](https://wordpress.org/support/users/kevinmt/)
 * (@kevinmt)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/custom-querystring-support/#post-13670224)
 * URL rewrite version :mysite.com/fruit/apple
    Querystring version :mysite.com/?
   fruit=apple
 * URL rewrite version :mysite.com/pet/cat
    Querystring version :mysite.com/?pet
   =dog
 * The querystring params I believe will be passed to the page and the URL rewrite
   makes i look pretty in the URL bar…. hence the name pretty permalinks…..
 * I will try this later today and let you know my results but it looks like it 
   will do what I need! Thank you!

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

The topic ‘Custom Querystring support’ is closed to new replies.

 * ![](https://ps.w.org/content-visibility-for-divi-builder/assets/icon-256x256.
   png?rev=1359961)
 * [Content Visibility for Divi Builder](https://wordpress.org/plugins/content-visibility-for-divi-builder/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/content-visibility-for-divi-builder/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/content-visibility-for-divi-builder/)
 * [Active Topics](https://wordpress.org/support/plugin/content-visibility-for-divi-builder/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/content-visibility-for-divi-builder/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/content-visibility-for-divi-builder/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [kevinmt](https://wordpress.org/support/users/kevinmt/)
 * Last activity: [5 years, 6 months ago](https://wordpress.org/support/topic/custom-querystring-support/#post-13670224)
 * Status: resolved