Mail web page integration
Back to Support Page
There are several supported methods to integrate the Mail contact tool in your website
As an alternative you might consider using one of the methods in the Smart Contact Button family.
Button + popup
This method allows you to add a button to your website which a visitor clicks to contact you. A new browser window will open (popup) which hosts the Mail contact tool.
Pro's:
- Fairly easy to integrate in an existing website
- The Mail contact tool will be opened in a new window, which will not interfere with the style of your webpage
Con's:
- Popup blockers might block opening the popup window
code example:
<a href="#" onClick="javascript: window.open('http://buttons.pushcall.com/mail/yourtargetname','pcwindow','width=500,height=500,scrollbars=no,toolbar=no,location=no'); return false;">
<img src="button-demo.jpg" border="0"/>
</a>
This example uses an image of a button. This <a> tag makes the image clickable. The onClick attribute will run the javascript function window.open() which will take care of opening a new browser window with the size specified by "width" and "height".
Please note that you should replace yourtargetname with the name of your target.
demo
Embedded
This method allows you to embed the Mail contact tool in your website.
Pro's:
- Fairly easy to integrate in an existing website
- It does not require an extra click to present the contact tool
Con's:
- The style of the Mail contact tool might interfere with the style of your site
- Navigating away from the page will disconnect the chat
code example:
<iframe src="http://buttons.pushcall.com/mail/yourtargetname" scrolling="no" height="500" width="500" marginheight="0" marginwidth="0" frameborder="0" allowtransparency="true"></iframe>
This example uses an <iframe> element which will allows you to integrate another web page in your own web site. The size of this element is specified by the "width" and "height" attributes.
Please note that you should replace yourtargetname with the name of your target.
demo
Overlay popup
By clicking a button on your website an overlay popup will open with the Mail client.
Pro's:
Con's:
- More difficult to integrate
- Navigating away from the page will disconnect the chat
Include this in the head of the HTML document:
<script>
function ShowContent(d) {
document.getElementById(d).style.display = "block";
}
function HideContent(d) {
document.getElementById(d).style.display = "none";
}
</script>
<style type="text/css">
body, a {
color:#595959;
font-family:arial;
font-size:13px;
text-decoration:none;
}
#flashwindow {
position:absolute;
left:50%;
top:50%;
margin-left:-213px;
margin-top:-250px;
text-align:right;
display:none;
}
#flashwindow a {
background:white;
border:1px solid gray;
padding:2px 8px;
line-height:25px;
}
</style>
Include this in the body of the HTML document:
<a href="javascript:ShowContent('flashwindow')">
<img src="button-demo.jpg" border="0"/>
</a>
<div id="flashwindow">
<a href="#" onClick="HideContent('flashwindow'); return false;">close window</a><br />
<iframe src="http://buttons.pushcall.com/mail/yourtargetname" scrolling="no" height="500" width="500" marginheight="0" marginwidth="0" frameborder="0" allowtransparency="true"></iframe>
</div>
This example uses an image of a button. This <a> tag makes the image clickable. Clicking the image will make the hidden <div> element visible. The <div> contains an <iframe> element which loads the Mail client.
Please note that you should replace yourtargetname with the name of your target.
demo