2013-08-28 2 views
0

나는이보기를 가지고있는에 ASP.NET MVC4 응용 프로그램이 있습니다면도기보기에서 전자 메일 클라이언트를 시작

@{ 
    Layout = "~/Views/Shared/Template.cshtml"; 
} 
@section logout { 

    <a href='@Url.Action("Logout", "Begin")' style="margin-left: 91.3%"><img src="~/Content/images/images.jpg" style="width:37px; height:37px" /></a> 
    } 
<html> 
<head> 
    <script> 
     function mailJob(code) { 
      window.open('mailto:[email protected]'); 
     } 
    </script> 

    </head> 
    <body> 

<form action="/Pages/Index" method="post" style="margin-left:20%"> 
    <div class ="CenterTitle"> 
     <h1 style="color:rgb(73, 140, 212)">Norm impact : Registre des réclamations clients</h1> 
    </div> 
    <div class="noPrint"> 
     <input type="hidden" value ="1" name="Pages"/> 
       <button type="submit" value="Submit" name="btnPage1"><img src="~/Content/images/OK.png" onclick="mailJob('Sample');"/></button> 
       <button type="button" value="exportToPDF" onclick="window.print()" name="btnPage1"style="margin-left:55%"><img src="~/Content/images/print.png" /></button> 
    </div> 

    ... 

    <div class="noPrint"> 
     <button type="submit" value="Page2" name="btnPage1" style="margin-left:75%"><img src="~/Content/images/next.png" /></button> 
    </div> 
</form> 

</body></html> 

소프트 메일이 시작하지만 새로운되지 않기 때문에 문제는 mailto에 이 URL이있는 창 mailto:[email protected].

어떻게이 문제를 해결할 수 있습니까?

답변

1

대신을 시도

function mailJob(code) { 
    window.location.href = 'mailto:[email protected]'; 
} 
+0

가 작동하지 않았다, 지금 어떤 창이 열립니다 없다 –

관련 문제