[geeklog-cvs] geeklog-1.3/public_html portal.php,1.10,1.11
dhaun at geeklog.net
dhaun at geeklog.net
Thu Jan 1 15:50:10 EST 2004
Update of /usr/cvs/geeklog/geeklog-1.3/public_html
In directory geeklog_prod:/tmp/cvs-serv15309
Modified Files:
portal.php
Log Message:
Changed to send a HTTP Location: header when redirecting to the linked site.
Index: portal.php
===================================================================
RCS file: /usr/cvs/geeklog/geeklog-1.3/public_html/portal.php,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** portal.php 3 Dec 2002 13:45:26 -0000 1.10
--- portal.php 1 Jan 2004 20:50:08 -0000 1.11
***************
*** 6,17 ****
// +---------------------------------------------------------------------------+
// | portal.php |
- // | Geeklog portal page that tracks link click throughs. |
// | |
// +---------------------------------------------------------------------------+
! // | Copyright (C) 2000,2001 by the following authors: |
// | |
! // | Authors: Tony Bibbs - tony at tonybibbs.com |
! // | Mark Limburg - mlimburg at users.sourceforge.net |
! // | Jason Wittenburg - jwhitten at securitygeeks.com |
// +---------------------------------------------------------------------------+
// | |
--- 6,18 ----
// +---------------------------------------------------------------------------+
// | portal.php |
// | |
+ // | Geeklog portal page that tracks link click throughs. |
// +---------------------------------------------------------------------------+
! // | Copyright (C) 2000-2004 by the following authors: |
// | |
! // | Authors: Tony Bibbs - tony at tonybibbs.com |
! // | Mark Limburg - mlimburg at users.sourceforge.net |
! // | Jason Whittenburg - jwhitten at securitygeeks.com |
! // | Dirk Haun - dirk at haun-online.de |
// +---------------------------------------------------------------------------+
// | |
***************
*** 38,52 ****
// MAIN
! $display = '';
! if (!empty($item)) {
$url = DB_getItem ($_TABLES['links'], 'url', "lid = '{$item}'");
! DB_change($_TABLES['links'],'hits','hits + 1','lid',$item,'',true);
! $display .= COM_refresh($url);
! } else {
! $display .= COM_refresh($_CONF['site_url']);
}
! echo $display;
?>
--- 39,58 ----
// MAIN
! $url = '';
! $item = COM_applyFilter ($HTTP_GET_VARS['item']);
!
! if (!empty ($item)) {
$url = DB_getItem ($_TABLES['links'], 'url', "lid = '{$item}'");
! if (!empty ($url)) {
! DB_change ($_TABLES['links'], 'hits','hits + 1', 'lid',$item, '', true);
! }
}
! if (empty ($url)) {
! $url = $_CONF['site_url'];
! }
!
! header ('Location: ' . $url);
?>
More information about the geeklog-cvs
mailing list