• Hi,

    I want to add this hidden field to the widget

    <input type="hidden" name="SIGNUPPAGE" id="mce-SIGNUPPAGE" value="<?php the_title(); ?>">

    to pass the page name as a merge field, but it seems I can’t use php in the widget. how can I get the page name to pass it with the plugin?

Viewing 2 replies - 1 through 2 (of 2 total)
  • I don’t know about the php part, but you could instead insert a new version of the widget on each page/post and use static text for the page name. If you’re trying to do this in a sidebar or other widget area that appears on multiple pages (which I’m assuming is what you’re trying to do, you may have to go another route.

    There’s a plugin (amr shortcode any widget) where you can add a widget and then get a shortcode that you can use in any page or post. Then you can hardcode the page/post name for each version you create.

    I realize it’s not ideal, but it’s a work-around until you can figure out how to do what you really want.

    Thread Starter sigul77

    (@sigul77)

    Thanks for supporting, but this wont help ??

    I want to get the page name per each page to store it in mailchimp merge field.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘use page name in a hidden field’ is closed to new replies.