Welcome to Geeklog Tuesday, November 19 2019 @ 04:27 pm EST

Fix for broken polls on Mac OS X 10.2

  • Contributed by:
  • Views: 4,600
Geeklog.net Polls do not work correctly for virtual sites on Mac OS X 10.2 from a regular install of GeekLog, the only flaw I have yet detected.

Mac OS X sets the environment variable REMOTE_ADDR to the IP of the server, not the remote user! Thus all votes appear to come from the same IP number.

As polls are restricted to one vote per IP number, only one vote can be cast for the entire site.

A quick fix is to put the following line at the beginning
of lib-common.php

which will set REMOTE_ADDR to the correct remote address.