2014-03-27 60 views
0

我正在尝试向我公司的新即将推出的网站添加功能。点击电子邮件地址时的弹出式邮件表

我们目前在该公司有9个人,每个人都有自己的电子邮件地址,我想添加的是弹出式窗口内的弹出式窗口功能。但是,这种扭曲是因为当一个外部的人点击一个电子邮件地址时,该人直接写到该人(在公司内部)的电子邮件地址(这是否有意义?)。

我已经做了JSFiddle,只是举个例子

下面是代码的预览太:

<table border="1" align="center"> 
    <tbody> 
     <tr> 
      <td width="100px" height="100px">Picture</td> 
      <td width="100px" height="100px">Picture</td> 
      <td width="100px" height="100px">Picture</td> 
     </tr> 
     <tr> 
      <td height="50px">CEO<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
      <td height="50px">Sales<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
      <td height="50px">Sales<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
     </tr> 
     <tr> 
      <td width="100px" height="100px">Picture</td> 
      <td width="100px" height="100px">Picture</td> 
      <td width="100px" height="100px">Picture</td> 
     </tr> 
     <tr> 
      <td height="50px">Sales<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
      <td height="50px">Sales<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
      <td height="50px">Driver<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
     </tr> 
     <tr> 
      <td width="100px" height="100px">Picture</td> 
      <td width="100px" height="100px">Picture</td> 
      <td width="100px" height="100px">Picture</td> 
     </tr> 
     <tr> 
      <td height="50px">Driver<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
      <td height="50px">IT<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
      <td height="50px">IT<br />E-mail: <a href="mailto:[email protected]">Test-mail</a><br />Unique popup-emailform</td> 
     </tr> 
    </tbody> 
</table> 
+0

你开始对随后弹出的代码?如果是这样,请分享 – Lodder

回答

0

我假设你正在使用的Joomla,你标记的Joomla你的问题。你可以使用Joomla的模式功能。

首先覆盖联系人 - 在您自己的模板中查看。复制文件 /components/com_contact/views/category/tmpl/default_items.php 到 /templates/yourtemplate/html/com_contact/category/default_items.php

某处的文件的顶部添加

<?php JHTML::_('behaviour.modal'); ?> 

这使得带班的所有链接的模式弹出=态

现在使你的电子邮件的链接是这样的:

<a class="modal" href="<?php 
echo JRoute::_(Juri::root()."?option=com_contact&view=contact&tmpl=component&id={$contact_id}"; 
?>">Test-mail</a> 

其中$ contact_id是您的员工的联系人ID。因此,您还需要在contacts-component中添加联系人信息。现在,该链接应该为您的员工打开一个带有联系表单的模式对话框。

此处了解详情:Using modal windows with Joomla

问候乔纳斯

相关问题