WordPress.org

Plugin Directory

Changeset 696585


Ignore:
Timestamp:
04/12/13 14:00:24 (13 months ago)
Author:
donncha
Message:

Escape urls in "last cached" list

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wp-super-cache/trunk/wp-cache-phase2.php

    r696583 r696585  
    678678        if ( count( $last_urls ) >= 10 ) 
    679679            $last_urls = array_slice( $last_urls, 1, 9 ); 
    680         $last_urls[] = array( 'url' => $_SERVER[ 'REQUEST_URI' ], 'date' => date( 'Y-m-d H:i:s' ) ); 
     680        $last_urls[] = array( 'url' => preg_replace( '/[ <>\'\"\r\n\t\(\)]/', '', $_SERVER[ 'REQUEST_URI' ] ), 'date' => date( 'Y-m-d H:i:s' ) ); 
    681681        update_option( 'supercache_last_cached', $last_urls ); 
    682682    } 
Note: See TracChangeset for help on using the changeset viewer.