Welcome Guest, Not a member yet? Register   Sign In
Invalid URLs starting with numbers get cropped in log files
#1

[eluser]Fabrício Marchezini[/eluser]
When a user tries to access an invalid URL starting with a number (like "/44/55/foo-bar.html"), CodeIgniter adds an error to the log file containing only the first segment of the URL:

Code:
ERROR - 2012-03-12 10:44:17 --> 404 Page Not Found --> 44

So I don't know exactly what page the user was trying to access.

I've tested it on CI 1.6, 1.7 and on clean install of 2.1, using clean URLs (htaccess) or index.php, and the problem is the same.
#2

[eluser]Otemu[/eluser]
Check out the error template found here which handles this error, might be able to modify something there to output the full url
application/errors/error_404.php

Error handling guide http://ellislab.com/codeigniter/user-gui...rrors.html

Hope that helps
#3

[eluser]Fabrício Marchezini[/eluser]
I don't think so. The error_404.php template exists only to display the message to the user. The error logging is made before the message is displayed.
#4

[eluser]Otemu[/eluser]
This might provide your answer then
http://stackoverflow.com/questions/66009...oming-from

Thanks
#5

[eluser]InsiteFX[/eluser]
See the function _validate_request($segments) in the ./system/Router.php Class
#6

[eluser]Aken[/eluser]
Make sure you don't have a route that is redirecting these requests, also.




Theme © iAndrew 2016 - Forum software by © MyBB