Modify

Opened 8 years ago

Closed 7 years ago

Last modified 4 years ago

#7612 closed defect (worksforme)

luci custom error 404

Reported by: cedric.voncken@… Owned by:
Priority: normal Milestone: Barrier Breaker 14.07
Component: luci Version: Trunk
Keywords: Cc:

Description

The file error404.html is placed on my filesystem. But I don't see my custom error page.

In the function error404(message) in dispatcher.lua :

function error404(message)

	luci.http.status(404, "Not Found")
	message = message or "Not Found"

	require("luci.template")

	if not luci.util.copcall(luci.template.render, "error404") then
		luci.http.prepare_content("text/plain")
		luci.http.write(message)
		luci.util.perror(message)
	end
return false
end

The problem is on function render, this function do not return any value, and the copcall function return always false.

Attachments (0)

Change History (2)

comment:1 Changed 7 years ago by jow

  • Resolution set to worksforme
  • Status changed from new to closed

It must be "error404.htm" in "/usr/lib/lua/luci/view" and works here.

comment:2 Changed 4 years ago by jow

  • Milestone changed from Attitude Adjustment 12.09 to Barrier Breaker 14.07

Milestone Attitude Adjustment 12.09 deleted

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.