Skip to:
Content

bbPress.org

Changeset 1576


Ignore:
Timestamp:
07/03/2008 06:42:35 AM (16 years ago)
Author:
sambauers
Message:

parse_url() borks out when http:// is in the querystring, changing to more manual method

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bb-includes/functions.php

    r1575 r1576  
    22092209        return (int) $_GET['page'];
    22102210
    2211     if ( isset($_SERVER['PATH_INFO']) ) {
     2211    if ( isset($_SERVER['PATH_INFO']) )
    22122212        $path = $_SERVER['PATH_INFO'];
    2213     } else {
    2214         if ( !$parsed = parse_url( $_SERVER['REQUEST_URI'] ) )
     2213    else
     2214        if ( !$path = strtok($_SERVER['REQUEST_URI'], '?') )
    22152215            return 1;
    2216         if ( empty($parsed['path']) )
    2217             return 1;
    2218         $path = $parsed['path'];
    2219     }
    22202216
    22212217    if ( $page = strstr($path, '/page/') ) {
Note: See TracChangeset for help on using the changeset viewer.