• Resolved Imageofmarconi

    (@ofmarconi)


    Hello,

    is it possible to fill with the value of the query string parameters?

    If the URL for: website.com/?Nick=John

    The Shortcode: [SC name=”Nick” nick=”%%par_nick%%“]

    Would it be filled %%par_nick%% by the value of the parameter in the URL ?Nick=*

    Is this possible with your plugin?

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Imagevaakash

    (@vaakash)

    Hi @ofmarconi,

    You have to place the “placeholder” in the shortcode content and then pass the parameter to the shortcode.

    Shortcode content:

    website.com/?Nick=%%my_parameter%%

    Shortcode:

    [sc name="my_shortcode" my_parameter="John"]

    Thanks,
    Aakash

    Thread Starter Imageofmarconi

    (@ofmarconi)

    Sorry, I explained wrong, the page URL containing the shortcode that has this address:

    website.com/?nick=John

    And then the shortcode fills with the name:

    <h1> Wellcome [sc name="my_shortcode" my_parameter="Nick"] </h1>

    I think it’s clearer now, right?

    Thx!

    Plugin Author Imagevaakash

    (@vaakash)

    Hi @ofmarconi,

    Ok I got it.. you want the query parameter of the URL to be present in the shortcode content.

    This is currently not possible, but seems like useful. I’ll do some research if there would be a demand or any security issue for it and implement if possible in the future.

    Thanks,
    Aakash

    Thread Starter Imageofmarconi

    (@ofmarconi)

    Perfect!

    I guess I would not have a problem if you cleaned the output … for example, do not let someone inject code by this door, only text.

    The usefulness is almost infinite.
    Since some forms insert parameters based on the filled fields, I can leave more human the thanks, with the name of the lead.

    If you use elementor, you should know, they do this, could consult their code;)

    Today I am using the elementor + shortcoder to do this.
    Awaiting 😉

    Thanks!

    • This reply was modified 4 years, 3 months ago by Imageofmarconi.
Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Parameters of the query string’ is closed to new replies.