Loading...
 
Skip to main content

tiki-user_reports_send.php from command line doesn't find ip_address

Status
Open
Subject
tiki-user_reports_send.php from command line doesn't find ip_address
Version
8.x
Category
  • Error
Feature
Daily reports
Resolution status
New
Submitted by
Clif Kussmaul
Lastmod by
Clif Kussmaul
Rating
(0)
Description

I am following instructions in http://doc.tiki.org/Daily+Reports.
When I run:
php tiki-user_reports_send.php

from the Linux command line or in cron, I get an error:
This script can only be called by the server.

$tikilib->get_ip_address() returns 0.0.0.0 not 127.0.0.1.

I am in a shared hosting environment (A2Hosting),
which could certainly contribute to the problem.

Solution

One solution is to modify tiki-user_reports_send.php
to accept both 127.0.0.1 and 0.0.0.0 as representing the server.

Another solution is to modify $tikilib->get_ip_address()
to default to 127.0.0.1 instead of 0.0.0.0
although this might have many other side effects.

Importance
5
Easy to solve?
10 easy
Priority
50
Demonstrate Bug on Tiki 19+
Demonstrate Bug (older Tiki versions)
Ticket ID
4231
Created
Wednesday 23 May, 2012 20:58:08 UTC
by Clif Kussmaul
LastModif
Wednesday 23 May, 2012 20:58:08 UTC


Show PHP error messages