ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Google analytics query link giving 404 on root level -- ?utm_source=

October 01, 2012 7:02pm

Subscribe [2]
  • #1 / Oct 01, 2012 7:02pm

    ideadigital

    9 posts

    Google analytics link trackers with URLs that match this pattern:

    domain.com/?utm_source=Text+Goes+Here

    Causes a 404 error at the root level. Other levels seem OK.

    We’ve tried adding question marks as acceptable characters in config.php:

    $config['permitted_uri_chars'] = "a-z 0-9~%.:_\-?";

    We’ve tried adjusting the Rewrite code as follows:

    # Catch any Google campaigns directed to the home page
    RewriteCond %{REQUEST_URI} ^/$
    RewriteCond %{QUERY_STRING} ^(utm_source.*)
    RewriteRule ^(.*)$ /index.php? [L,PT]

    Also tried adding a question mark to this line in our rewrite code:

    RewriteRule .* index.php?/$0 [NC]

    I’ve seen some other threads with similar problems but no final resolution… any ideas?

     

     

  • #2 / Oct 02, 2012 4:02pm

    ideadigital

    9 posts

    We found the answer to this on this thread. That solution worked fine.

  • #3 / Oct 02, 2012 5:10pm

    Shane Eckert

    7174 posts

    Hey ideadigital,

    Awesome. Glad that you got this figured out.

    If you need anything else, please just let me know by opening a new thread.

    Cheers,

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases