Disable per directory /wildcard?

1,643 views
Skip to first unread message

Vid Luther

unread,
May 8, 2011, 2:23:09 PM5/8/11
to mod-pagesp...@googlegroups.com
So,
 I've been busy for the past few months, and finally rejoined this list to see the progress of the project, looks like we've come a long way :). Really happy to see the progress, but I wasn't sure if this was discussed already.. 

How do disable pagespeed for a specific directory? 

I'm using mod_pagespeed with WordPress, the customer facing side is working fine with pagespeed, everything looks great, but when I go into /wp-admin/ all hell breaks loose, the ajax, ui, etc get all convoluted.  I'm using the SVN bleeding edge of WordPress, so it's hard for me to say if it's a bleeding edge issue which will be fixed eventually.. or what. 


Joshua Marantz

unread,
May 8, 2011, 2:28:53 PM5/8/11
to mod-pagesp...@googlegroups.com
Welcome back Vid!  You can use wildcarding to do that now:

Vid Luther

unread,
May 8, 2011, 4:57:24 PM5/8/11
to mod-pagesp...@googlegroups.com
that worked like a charm :). just waiting on dns changes to work and i'll things through webpagetest.org again :)


gives me a 94, while webpagetest gives me a 70.. big difference :)
--
Vid Luther
CEO and Founder
ZippyKid
Managed Wordpress Hosting
http://zippykid.com/
210-789-0369

Joshua Marantz

unread,
Jan 7, 2013, 10:03:05 AM1/7/13
to mod-pagespeed-discuss
ModPagespeedDisallow */wp-admin/*

We really should get to the bottom of *why* mod_pagespeed doesn't work with wp-admin...Emanuel, what symptoms do you see?

-Josh



On Mon, Jan 7, 2013 at 9:57 AM, Emanuel Pesendorfer <man...@gmail.com> wrote:
its been some time since you wrote that... i got the same problem now with a worpress installation, that breaks on the backend.
I turned off pagespeed via .htaccess (ModPagespeed off) and it worked again.

Now the question: How do I actually turn it off only for the /admin area?

I tried following, but it didnt do the magic:

ModPagespeedDisallow wp-admin/*

Matt Atterbury

unread,
Jan 7, 2013, 10:03:50 AM1/7/13
to mod-pagespeed-discuss
Hi,

Please try ModPagespeedDisallow */wp-admin/*


On Mon, Jan 7, 2013 at 9:57 AM, Emanuel Pesendorfer <man...@gmail.com> wrote:
its been some time since you wrote that... i got the same problem now with a worpress installation, that breaks on the backend.
I turned off pagespeed via .htaccess (ModPagespeed off) and it worked again.

Now the question: How do I actually turn it off only for the /admin area?

I tried following, but it didnt do the magic:

ModPagespeedDisallow wp-admin/*

On Sunday, May 8, 2011 10:57:24 PM UTC+2, Vid Luther wrote:



--
"Klaatu barada nikto"                          (754) 444-6288
Message has been deleted

Joshua Marantz

unread,
Jan 7, 2013, 10:28:18 AM1/7/13
to mod-pagespeed-discuss
Great.  Trying to reproduce now, ut that file can't be loaded into an HTML file without some other JS you must have.  I get this from Firebug:

ReferenceError: thickboxL10n is not defined

I think that's preventing me from getting to the unicode escape sequence problem.
Are there other JS files loaded before that one?
Also, can you share the any "meta" tags in the HTML that loads this file?  They might affect the charset.
-Josh


On Mon, Jan 7, 2013 at 10:19 AM, Emanuel Pesendorfer <man...@gmail.com> wrote:
More message actions
4:15 PM (2 minutes ago)
hey, thanks for getting back so quick. that did it. thought i tried that... :)

the problem that we discovered was an error that prevented the "add media" - popup (iframe overlay) to open. this overlay lets you choos files from your media gallery to set them as background of a slider in our case. it just didnt open, and firebug showed this error:


Timestamp: 07.01.13 16:12:48
Error: SyntaxError: malformed Unicode character escape sequence
Source: http:/*****/wordpress/wp-admin/load-scripts.php,qc=1,aload,5B,5D=jquery,,utils,,jquery-ui-core,,thickbox,,underscore,,shortcode,,plupload,,plupload-html5,,plupload-flash,,plupload-silverlight,,plupload-h,aload,5B,5D=tml4,,json2,,jquery-ui-datepicker,,media-upload,,farbtastic,,quicktags,aver=3.5.pagespeed.jm.CG6at-LLbC.js

Line: 32, Column: 5
Sourc Code:
__p+='\n\undefined\undefined<
div class="media-modal wp-core-ui">\

Joshua Marantz

unread,
Jan 7, 2013, 10:51:50 AM1/7/13
to mod-pagespeed-discuss
Can you also paste other 'script' tags?

Thanks!
-Josh



On Mon, Jan 7, 2013 at 10:47 AM, Emanuel Pesendorfer <man...@gmail.com> wrote:
there is only the charset meta tag

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />

we use this theme if that helps... maybe u can contact the author? but on my search on this bug I found some people writing about wp/pagespeed problems.

http://themeforest.net/item/churchope-responsive-wordpress-theme/2708562

Joshua Marantz

unread,
Jan 7, 2013, 4:42:13 PM1/7/13
to mod-pagespeed-discuss
Do you have any idea where ' thickboxL10n' is defined?  Even when I put the large failing script in the context of the HTML you just provided, I still get the Firebug error:
ReferenceError: thickboxL10n is not defined

rather than the error that you quoted.


On Mon, Jan 7, 2013 at 11:03 AM, Emanuel Pesendorfer <man...@gmail.com> wrote:
here you go

<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<script type="text/javascript">
addLoadEvent = function(func){if(typeof jQuery!="undefined")jQuery(document).ready(func);else if(typeof wpOnload!='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}};
var ajaxurl = '/wordpress/wp-admin/admin-ajax.php',
	pagenow = 'edit-th_slideshows',
	typenow = 'th_slideshows',
	adminpage = 'edit-php',
	thousandsSeparator = ',',
	decimalPoint = '.',
	isRtl = 0;
</script>
	<script language="javascript" type="text/javascript">
		if(typeof  THEME_URI == 'undefined')
		{
			var THEME_URI = 'http://www.iact.eu/wordpress/wp-content/themes/churchope';
		}
	</script>
	
<script type='text/javascript'>
/* <![CDATA[ */
var userSettings = {"url":"\/wordpress\/","uid":"1","time":"1357576925"};/* ]]> */
</script>
<script type='text/javascript' src='http://*****/wordpress/wp-admin/load-scripts.php?c=1&amp;load[]=jquery,utils&amp;ver=3.5'></script>
		<script>
			var th_wpml_lang = '';
		</script>
			<script>
			var time_24_format = false;
		</script>
	<style type="text/css" media="print">#wpadminbar { display:none; }</style>
</head>

[…]

<script type='text/javascript'>
/* <![CDATA[ */
var commonL10n = {"warnDelete":"You are about to permanently delete the selected items.\n  'Cancel' to stop, 'OK' to delete."};var inlineEditL10n = {"error":"Error while saving the changes.","ntdeltitle":"Remove From Bulk Edit","notitle":"(no title)","comma":","};/* ]]> */
</script>
<script type='text/javascript' src='http://*****/wordpress/wp-admin/load-scripts.php?c=1&amp;load[]=admin-bar,hoverIntent,common,suggest,inline-edit-post&amp;ver=3.5'></script>
	
<div class="clear"></div></div><!-- wpwrap -->
<script type="text/javascript">if(typeof wpOnload=='function')wpOnload();</script>
</body>

hope that helps!


 

Joshua Marantz

unread,
Mar 26, 2013, 5:12:41 PM3/26/13
to mod-pagespeed-discuss
FYI we have added a global disallow of */wp-admin/* in our trunk code, pending an investigation of what it is that we break in wp-admin.

-Josh



On Mon, Feb 4, 2013 at 8:40 PM, Jordan Meeter <j...@electrojams.com> wrote:
Just wanted to chime in and also say that I had issues with wp-admin not working. So, for now I am just disabling wp-admin in .htaccess!

--
You received this message because you are subscribed to the Google Groups "mod-pagespeed-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mod-pagespeed-di...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Jordan Meeter

unread,
Mar 26, 2013, 5:14:33 PM3/26/13
to mod-pagesp...@googlegroups.com
Fascinating. I was wondering why PSS seemed to be disabled for /wp-admin/ despite me not having a rule for it. Nice one guys ;)


--
You received this message because you are subscribed to a topic in the Google Groups "mod-pagespeed-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/mod-pagespeed-discuss/r6lcoseTJks/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to mod-pagespeed-di...@googlegroups.com.

jkarlin

unread,
Apr 17, 2013, 6:58:03 AM4/17/13
to mod-pagesp...@googlegroups.com
Jordan, 

Can you provide some detail on what wasn't working for you in wp-admin?  I'm trying to track down wp-admin bugs.

Thanks,

Josh
To unsubscribe from this group and stop receiving emails from it, send an email to mod-pagespeed-discuss+unsub...@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to a topic in the Google Groups "mod-pagespeed-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/mod-pagespeed-discuss/r6lcoseTJks/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to mod-pagespeed-discuss+unsub...@googlegroups.com.

Josh Karlin

unread,
Apr 17, 2013, 1:59:48 PM4/17/13
to mod-pagesp...@googlegroups.com
Could somebody with this bug run an experiment for me?  My guess is that there are UTF-8 BOM markers in the middle of the concatenated javascript that wordpress produces with load-scripts.php and mod_pagespeed is failing to set the charset to UTF-8 in the HTTP response headers.  

So please look at the response headers from the load-scripts.php...pagespeed.js URL and report the charset (if any).  Also please report the charset of the load-scripts.php URL (no .pagespeed. in the URL) when mod_pagespeed is turned off.

Ideally it would be helpful for me to have the full broken and working URLs (with domain) so that I can inspect for myself.  You can email that to me directly if you don't want to put it on the list.

Thanks,

Josh

Jordan Meeter

unread,
Apr 17, 2013, 2:02:59 PM4/17/13
to mod-pagesp...@googlegroups.com
Hi Josh,

Unfortunately I for the life of me cannot remember. If you could somehow enable PSS for my blog's WP-Admin folder I would be more than happy to report back to you my findings!

Sorry I couldn't be more helpful.



To unsubscribe from this group and all its topics, send an email to mod-pagespeed-di...@googlegroups.com.

Josh Karlin

unread,
Apr 17, 2013, 2:16:59 PM4/17/13
to mod-pagesp...@googlegroups.com
Also, a list of your wordpress plugins could also be of help.

Josh Karlin

unread,
Apr 17, 2013, 2:41:40 PM4/17/13
to mod-pagesp...@googlegroups.com
Jordan, 

Thanks, no worries.  I'm hoping to find somebody with an old version of mod_pagespeed which hasn't blocked wp-admin in the binary.

Josh


To unsubscribe from this group and stop receiving emails from it, send an email to mod-pagespeed-di...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages