Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Review preg_match() usage #911

Closed
robocoder opened this Issue · 1 comment

1 participant

Anthon Pang
Anthon Pang
Collaborator

PHP 5.1.x appears to handle backslash escaped characters differently from 5.2/5.3.

Example: core/SmartyPlugins/output.cachebuster where php 5.1.x reports preg_replace() [function.preg-replace]: Unknown modifier '.'

Propose using:

      $pattern = array(
        '~<script type="text/javascript" src="([^"]+)">~',
        '~<script src="([^"]+)" type="text/javascript">~',
        '~<link rel="stylesheet" type="text/css" href="([^"]+)"~',
      );
Anthon Pang
Collaborator

I'm marking this as fixed cause I don't see anything more that can done here, other than to recommend using a newer version of PHP.

See changesets [1377, [1378].

Anthon Pang robocoder added this to the Piwik 0.4.3 milestone
Anthon Pang robocoder self-assigned this
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.