0

I have this code

 <?xml version='1.0' encoding='UTF-8' ?>
   <html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:pe="http://primefaces.org/ui/extensions" >

    <h:head>
        <title>Facelet Title</title>
        <link rel="stylesheet" type="text/css" href="easyui.css"/>
        <link rel="stylesheet" type="text/css" href="icon.css"/>
        <link rel="stylesheet" type="text/css" href="demo.css"/>
        <script src="jquery.easyui.min.js" type="text/javascript"></script>
        <script src="jquery.min.js" type="text/javascript"></script>
    </h:head> 
    <h:body>
       <h:form>  
         <pe:layout maskPanesEarly="true">  
         <pe:layoutPane position="north" size="85">  
            North  
         </pe:layoutPane>  
         <pe:layoutPane position="center" maskContents="true">  

          <div id="tt"  class="easyui-tabs" style="width:400px;height:333px">
              test
         </div>
        </pe:layoutPane>  
        <pe:layoutPane position="west" size="250" resizeWhileDragging="false"  
                       maxSize="500" minSize="100" resizable="true">                    
            West  
         <li><a href="#" onclick="addTab('My Site','index.xhtml')">My Site</a>

        </pe:layoutPane>  
        </pe:layout>  
            </h:form>  
              </h:body>
              </html>

And I am trying to add this jquery script :

< script >
  function addTab(title, url) {
    if ($('#tt').tabs('exists', title)) {
      $('#tt').tabs('select', title);
    } else {
      var content = '<iframe scrolling="auto" frameborder="0"  src="' + url + '" style="width:600%;height:100%;"></iframe>';
      $('#tt').tabs('add', {
        title: title,
        content: content,
        closable: true
      });
    }
  } < /script>

But when I am using this script, the result is a blank page

I do not know where is my problem, I removed the jquery code, and the Layout Primeface is displayed I want a personalized display layout?

yannicuLar
  • 3,083
  • 3
  • 32
  • 50
  • if you are using primefaces too, try to load with --> this is just an example – ZaoTaoBao Apr 26 '16 at 09:49
  • 1
    You should **NOT** load your own jquery this way as PF/PFE already uses its own jquery. As can be read on several stackoverflow questions. What goes wrong when using the embedded jquery from PF/PFE? 'the result is a blank page' is an end-user description of the situation. Investigate as a developer – Kukeltje Apr 26 '16 at 10:16
  • thank's Kukeltje but What do you mean PF/PFE ? – Soufiane Barakat Apr 26 '16 at 10:49
  • thank's ZaoTaoBao it's display page but code
    test
    not displayed Failed to load resource: the server responded with a status of 404 (Not Found)
    – Soufiane Barakat Apr 26 '16 at 11:00
  • PrimeFaces, PrimeFaces Extensions.... – Kukeltje Apr 26 '16 at 12:01

0 Answers0