Okay
  Public Ticket #2639311
Open master-details in current window
Closed

Comments

  • Richard van Heuven started the conversation

    I want to open the master details as a page in the same window (not in a new tab). How do I get that done?

  •  2,572
    Aleksandar replied

    Hello Richard

    Thank you for reaching out to us.

    Unfortunately, there is no built-in option at the moment, but we will add it in one of the next updates.

    You can change it in code in file wp-content/plugins/wdt-master-detail/class.masterdetail.wpdatacolumn.php around line 51 you will find this

    $formattedValue = "<form class='wdt_md_form' method='post' target='_blank' action='{$renderAction}'>

    and you have to change target="blank" to target="_self"

    $formattedValue = "<form class="wdt_md_form" method="post" target="_self" action="{$renderAction}">

    also in same file on line 64 you will find this

    $formattedValue = "<form class='wdt_md_form' method='post' target='_blank' action='{$renderAction}'>

    and you have to replace with this

    $formattedValue = "<form class='wdt_md_form' method='post' target='_self' action='{$renderAction}'>

    Then go to wp-content/plugins/wdt-master-detail/templates/md_modal.inc.php and change line 52 just like you did the others, so instead of:

    <form class="wdt_md_form" method="post" target="_blank" action="<?php echo $renderAction; ?>"></form>

    Change it to this:

    <form class="wdt_md_form" method="post" target="_self" action="<?php echo $renderAction; ?>"></form>

    That one's for row click.

    Kind Regards, 

    Aleksandar Vuković
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables