• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

how to put contact-form as overlay?

erich37

Well-known member
#1
within one of my forum-post, I would like to enter a link for "Contact us" and when a user is clicking onto this link, it should open the "Contact"-window as an overlay.

when using the link "domain.com/misc/contact" , it does not show the overlay.

Is this possible ?
How to do this ?

Appreciate your help!
 

Brogan

XenForo moderator
Staff member
#2
Open the post template and look for this line:
Code:
<xen:if is="{$visitor.user_id}"><a href="{xen:link posts/report, $post}" class="OverlayTrigger item control report" data-cacheOverlay="false"><span></span>{xen:phrase report}</a></xen:if>

After it add this:
Code:
<xen:if is="{$xenOptions.contactUrl.type} === 'default'">
    <a href="{xen:link 'misc/contact'}" class="OverlayTrigger" data-overlayOptions="{&quot;fixed&quot;:false}">{xen:phrase contact_us}</a>
<xen:elseif is="{$xenOptions.contactUrl.type} === 'custom'" />
    <a href="{$xenOptions.contactUrl.custom}" {xen:if {$xenOptions.contactUrl.overlay}, 'class="OverlayTrigger" data-overlayOptions="{&quot;fixed&quot;:false}"'}>{xen:phrase contact_us}</a>
</xen:if>