1

I am trying to add a new tab in Luci . I added a new file page.lua with following code in /lua/luci/controller/admin

module("luci.controller.admin.page",package.seeall)
function index()
entry({"admin","content"},template("admin-page/pagedetail"),_("Page"),20).index=true
end

and in view pagedetail.htm

<%+header%>
<h1></h1>
<%+footer%>

But when i add this content , the new created "page" tab is merge with logout tab in main page . When i inspect the values , i can see that

<a class="logout" style="" href="">Page
<img src="/luci-static/resources/cbi/logout.png" style="float:right"></a>

why my new tab is acessing the class="logout"? Any suggestions ?

user2986042
  • 1,098
  • 2
  • 16
  • 37

1 Answers1

1

I solved by adding a drop down tab .

entry({"admin","newtab"},alias("admin","newtab","tab"),_("newtab"),20).index=true

and you can add child elements to this newtab by adding another entry function with template or cbi methods .

user2986042
  • 1,098
  • 2
  • 16
  • 37