• OzzModz is no longer taking registrations. All registrations are being redirected to Snog's Site
    All addons and support is available there now.

Mixing these two htaccess

Norman

New member
Hi there guys, I'm Dakoom (TAZ)! Finally here. So, the DNS seems that is still propagating. In the meantime maybe you can help me here. I'm trying to add these rules: Speed Up Your Site Via htaccess to my htaccess. The problem is that I have to mix them mith the existing rules:

Code:
<IfModule mod_suphp.c>
suPHP_ConfigPath /home/glaucoze/public_html
</IfModule>
<Files php.ini> 
order allow,deny 
deny from all 
</Files>

RewriteEngine On
# Force the "www."
RewriteCond %{HTTP_HOST} !^www\.klayz\.com$ [NC]
RewriteRule ^(.*)$ http://www.klayz.com/$1 [R=301,L]

RewriteCond %{HTTP_HOST} ^67.227.193.221
RewriteRule (.*) http://www.klayz.com/$1 [R=301,L]

RewriteBase /
RedirectMatch 301 ^/webmaster/(.*)$ http://webmaster.klayz.com/$1
RedirectMatch 301 ^/tools/(.*)$ http://tools.klayz.com/$1
RedirectMatch 301 ^/musica/(.*)$ http://musica.klayz.com/$1
RedirectMatch 301 ^/kick/(.*)$ http://kick.klayz.com/$1
RedirectMatch 301 ^/w3/(.*)$ http://w3.klayz.com/$1
RedirectMatch 301 ^/zcoin/(.*)$ http://zcoin.klayz.com/$1

ErrorDocument 404 /404.php

# Define Expires dates for static contnet
## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType text/css        "access plus 1 month"
ExpiresByType text/javascript "access plus 1 month"
ExpiresByType text/x-javascript "access plus 1 month"
ExpiresByType image/x-icon    "access plus 1 year"
ExpiresByType image/jpeg      "access plus 1 month"
ExpiresByType image/jpg       "access plus 1 month"
ExpiresByType image/gif       "access plus 1 month"
ExpiresByType image/png       "access plus 1 month"
ExpiresByType application/pdf "access plus 1 month"
ExpiresByType application/x-shockwave-flash "access plus 1 month"
</IfModule>
## EXPIRES CACHING ##

# Compress text, HTML, JavaScript, CSS, and XML
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript

# Remove browser bugs
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4\.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
Header append Vary User-Agent

# Omit Inode from Etag to prevent cache invalidation on server swap
#
FileETag MTime Size


#browser caching added by LW
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/text text/html text/plain text/xml text/css application/x-javascript application/javascript
</IfModule>
 
<IfModule mod_mime.c>
# Text
AddType text/css .css
AddType application/x-javascript .js
AddType text/html .html .htm
AddType text/richtext .rtf .rtx
AddType text/plain .txt
AddType text/xml .xml
 
# Image
AddType image/gif .gif
AddType image/x-icon .ico
AddType image/jpeg .jpg .jpeg .jpe
AddType image/png .png
AddType image/svg+xml .svg .svgz
 
# Video
AddType video/asf .asf .asx .wax .wmv .wmx
AddType video/avi .avi
AddType video/quicktime .mov .qt
AddType video/mp4 .mp4 .m4v
AddType video/mpeg .mpeg .mpg .mpe
 
# PDF
AddType application/pdf .pdf
 
# Flash
AddType application/x-shockwave-flash .swf
 
# Font
AddType application/x-font-ttf .ttf .ttc
AddType application/vnd.ms-fontobject .eot
AddType application/x-font-otf .otf
 
# Audio
AddType audio/mpeg .mp3 .m4a
AddType audio/ogg .ogg
AddType audio/wav .wav
AddType audio/wma .wma
 
# Zip/Tar
AddType application/x-tar .tar
AddType application/x-gzip .gz .gzip
AddType application/zip .zip
</IfModule>
 
<IfModule mod_expires.c>
ExpiresActive On
 
# Text
ExpiresByType text/css A31536000
ExpiresByType application/x-javascript A31536000
ExpiresByType text/html A3600
ExpiresByType text/richtext A3600
ExpiresByType text/plain A3600
ExpiresByType text/xml A3600
 
# Image
ExpiresByType image/gif A31536000
ExpiresByType image/x-icon A31536000
ExpiresByType image/jpeg A31536000
ExpiresByType image/png A31536000
ExpiresByType image/svg+xml A31536000
 
# Video
ExpiresByType video/asf A31536000
ExpiresByType video/avi A31536000
ExpiresByType video/quicktime A31536000
ExpiresByType video/mp4 A31536000
ExpiresByType video/mpeg A31536000
 
# PDF
ExpiresByType application/pdf A31536000
 
# Flash
ExpiresByType application/x-shockwave-flash A31536000
 
# Font
ExpiresByType application/x-font-ttf A31536000
ExpiresByType application/vnd.ms-fontobject A31536000
ExpiresByType application/x-font-otf A31536000
 
# Audio
ExpiresByType audio/mpeg A31536000
ExpiresByType audio/ogg A31536000
ExpiresByType audio/wav A31536000
ExpiresByType audio/wma A31536000
 
# Zip/Tar
ExpiresByType application/x-tar A31536000
ExpiresByType application/x-gzip A31536000
ExpiresByType application/zip A31536000
 
# Webfonts
ExpiresByType application/x-font-ttf "access plus 1 month"
ExpiresByType font/opentype "access plus 1 month"
ExpiresByType application/x-font-woff "access plus 1 month"
ExpiresByType image/svg+xml "access plus 1 month"
ExpiresByType application/vnd.ms-fontobject "access plus 1 month"
 
<FilesMatch "\.(?i:css|js|htm|html|rtf|rtx|txt|xml|gif|ico|jpg|jpeg|jpe|png|svg|svgz|asf|asx|wax|wmv|wmx|avi|mov|qt|mp4|m4v|mpeg|mpg|mpe|pdf|swf|ttf|ttc|eot|otf|mp3|m4a|ogg|wav|wma|tar|gz|gzip|zip)$">
<IfModule mod_headers.c>
Header set Cache-Control "public, must-revalidate, proxy-revalidate"
Header unset ETag
</IfModule>
</FilesMatch>


Can you please help me to do the mix?
 
Last edited:
Just try stacking these right on top or right below your existing ones. If there is a conflict it is easy for you to undo this action.
 
Quite a improvement in the grade for caching. I'm "Anton" over at TAZ by the way.

Your main performance problem is as I have said, the number of requests. Do you really need to be loading over 150 images?

You never did the BASELINE TEST we talked about. This is what will show you more than anything else, how much your add-ons, plugins and Mods, and 3rd party calls, are killing your performance.
 
Last edited:
I don't understand how anyone could expect 1.2 megabytes on 180-plus requests, to load blazingly fast. The site has too much glut!

You have sacrificed performance, for looks only YOU like - that does nothing for visitors or members. They don't CARE all that much how fancy pants your site looks. They care if it frikkin LOADS fast and works right.
 
Last edited:
Yes I deduced you were Anton. :wink:
Sincerely? After some brainstorming on it, I don't really want to know how much will be without everything loaded, because that would be only a "test" specifically for vBulletin and its performances. And excuse me for beign rude, but I'm not currently on this side of the thing, as I have to better invest my time on optimizing what I have now. I know those addons/mods/skins/buttons or whatever are killing my performance, but I'm here also because I still need to optimize them. Sure, wouldn't be better to remove them? Yeah, but I wouldn't have added them in this case. So I have them and I just need to have them, but optimized (at least as much as I/we can - if you still want to give me some advices).

You have sacrificed performance, for looks only YOU like - that does nothing for visitors or members. They don't CARE all that much how fancy pants your site looks. They care if it frikkin LOADS fast and works right.
I'm not on the same opinion as you here. I'm more likely to signup on a website that works and also have a good style. Sure, it should also go fast and without problems.
I don't want to say that now my website is loading fast, but at least it is "loading", which is already a good point, despite all.
Obviously I'm here because I want to compress the everything possible immaginable just to make it better! I have a plugin for TapaTalk users, and I'm in the process to compress its JS code too, just as an example. I also added some async to the scripts (yeterday I haven't them) and this is doing well too (now eg. for the black popups you don't have anymore to wait for the page to be completely loaded). Now I'd like to compress more the images if possible, merge some CSS and JS files and so on.
 
Your main performance problem is as I have said, the number of requests. Do you really need to be loading over 150 images?

This is crucial as probably I could use a better solution that I'm not aware of about what I'm going to explain here in the next lines. As you can see I have there the big button that open a CSS/jQuery popup in forumhome. This popup code is loaded at the bottom of the page, and it contains all the forums and subforums icon images. I currently want it like it because I think it's a good thing and it's cool to see. Yeah, a lot of images, I know. Probably 100. Maybe could I serve it from a different location or find a better solution? What do you think about this? Maybe you have some ideas that could save me about loading performances. As said I don't want to both remove the popup or the images in it. And as said before, I already super compressed them more than one time using this online tool: TinyPNG – Compress PNG images while preserving transparency.
 
Yes I deduced you were Anton. :wink:
Sincerely? After some brainstorming on it, I don't really want to know how much will be without everything loaded, because that would be only a "test" specifically for vBulletin and its performances. And excuse me for beign rude, but I'm not currently on this side of the thing, as I have to better invest my time on optimizing what I have now. I know those addons/mods/skins/buttons or whatever are killing my performance, but I'm here also because I still need to optimize them. Sure, wouldn't be better to remove them? Yeah, but I wouldn't have added them in this case. So I have them and I just need to have them, but optimized (at least as much as I/we can - if you still want to give me some advices).

TBH, you need the baseline test. One to see how much your customizations add to the load time, but more importantly to see how the site performs on the host, like it was out of the box. Otherwise you have no idea if any optimization is just spinning your wheels in the mud.
 
I don't really want to know how much will be without everything loaded, because that would be only a "test" specifically for vBulletin and its performances.
You don't know what else is going on, this is why you need the baseline test - because with that, if there's still issues, we know it's the server and not the garbage you're loading.
 
Thank you guys for your replies. I'll try to do it, hoping that tomorrow I will have my internet connection fixed. Now it is going really slow so I really can't do nothing, especially running a base line test. Tomorrow, if everything goes the right way, should come a tecnhician here to solve my internet connection troubles, so I'll update you as soon as possible. Anyway, in the meantime, after completely removing CloudFlare I have done a lot of things here and there, and now at least I have some decent results. For example:

Latest Performance Report for: [url]http://www.klayz.com/community | GTmetrix[/url]
10 seconds to load. Still a lot of time, so I'll really try to disable all those images that take time to load, even if they are so small.
For some reason, GTMetrix is still seeing my website in a wrong way as it doesn't see the updated CSS rules. I almost already fixed all the images dimensions problems, so probably I'll get even a better score there.

Website speed test
Here it loads it in less than 3 seconds. Still 230 requests. Still some scripts to optimize and maybe if I'll remove the images too... you know.

And finally (your favourite, isn't it? :) ):
WebPagetest Test Result - Dulles : [url]www.klayz.com/community - 12/30/15 02:17:24[/url]
7 seconds first load. 4 seconds on second view. Not so much bad, but still bad for my tastes. Still an F for the First Byte Time. And a D for compressing images... but they are just these:
WARNING - (38.7 KB, compressed = 21.8 KB - savings of 16.9 KB) - http://www.klayz.com/imgs/bg.jpg
WARNING - (7.4 KB, compressed = 6.1 KB - savings of 1.2 KB) - http://www.klayz.com/community/customavatars/avatar431_3.gif
WARNING - (4.4 KB, compressed = 4.0 KB - savings of 0.5 KB) - http://www.klayz.com/community/customavatars/avatar2_2.gif
Not so much. Argh that damn bg image. I'll consider to add a more simple (clean), small bg. image.

Personally, just for me? Your style looks like hammered dog crap.

LOL it's just too much a subjective thing to discuss about it. For example, just to let you understand with a website that you have surely seen... this one: Android Forum for Mobile Phones, Tablets, Watches & Android App Development - XDA Forums, posted on TAZ in my thread. As said, consider that I'm on a current bad connection status, but that website seems to be not one of the fastest we see everyday. So, what's the point? Maybe it takes some more seconds to load, but I'll definitely prefer to signup there rather than on a website with a default vB style (maybe with only the colors changed - or whatever else). Why? Because, speaking like a noob, it loads the page and it takes some seconds to do it: my head says "Ok, probably there is a reason... oh ok, I see. There is a lot of stuff going on. Mh, let me see!". Maybe it's different for you. Probably you say "Mh, it is taking too much to load... oh ok, I see. There is a lot of stuff going on. -> Click on the browser "X"". But as said it is purely a subjective manner.

The optimization per se, this is not a subjective manner. And this is the reaosn why I'm here, and for this I thank you one more time for your time and your help that you're spreading. :)
 
Last edited:
Test shopping and muddying the waters isn't a objective or scientific approach. None of the other tests you posted use real browsers, real connections.

It's interesting that everything we have told you has helped when you've tried it, helped a lot actually - but for some reason there's only so far you want to go. Just admit you're doing the site for your own ego and gratification, and really don't care what visitors or members think of it. YOU like it.:smokin:

And that's all fine and dandy. What you like and want to see is far secondary for you, to performance. There's lots of folks out there like that. BUT...
LOL it's just too much a subjective thing to discuss about it. For example, just to let you understand with a website that you have surely seen... this one: forum.xda-developers.com, posted on TAZ in my thread. As said, consider that I'm on a current bad connection status, but that website seems to be not one of the fastest we see everyday. So, what's the point? Maybe it takes some more seconds to load, but I'll definitely prefer to signup there rather than on a website with a default vB style (maybe with only the colors changed - or whatever else). Why? Because, speaking like a noob, it loads the page and it takes some seconds to do it: my head says "Ok, probably there is a reason... oh ok, I see. There is a lot of stuff going on. Mh, let me see!".
Do not propose to lecture, giving comparisons to sites in great genres and are long established and with millions of members, as some example of what you should do for performance. There's sites all over the web representing big companies which spend millions on servers and a IT department, who have poor performance. It's got nothing to do with new sites trying to get established.

But more to your point, what YOU think would prompt you to create a account and post is singular - it's just you. For NEW sites, every study ever done shows speed and performance do the trick for converting visitor traffic into posting members. Speed is what cuts it, not glitz. And for NEW sites, especially today - slow sites make people click the X button and never return. It's proven over and over.

If you want to compare old established sites we can do it all day. I'm also a admin Here and this sucker's been around since you were filling diapers, still has its old skin and is still vB3, and gets about 70,000 posts a day. And makes around 8K a week in advert revenue. BUT, I wouldn't ever compare this to a NEW site just starting out, like yours.

The two old sites got where they are by keeping it simple, having a great genre and subject material - AND initially their pages loaded really fast. (The one I linked still does). You should check both sites at archive dot org and see how they started. Default styles, nothing fancy. That is what built their membership and got them their momentum.

We can give you good advice, but again it is up to you to take any of it. Hey, when I was a young fella I never listened to the old timers either. But I also learned not to waste any of their time - we can at least give them a little respect in that regard.

The goal should be achieving a BALANCE between the glitz, and performance. Right now you're not anywhere near that balance.
 
Last edited:
I mean, all this PC view style and performance talk is really secondary, what with more than 60 percent of all web users now using mobile devices and browsers, (and that number is growing) your real work for the future is making your site mobile friendly. Have fun with that. Here's a report.
 
Do not propose to lecture, giving comparisons to sites in great genres and are long established and with millions of members, as some example of what you should do for performance.

Just to clarify, I was talking only about the style and not about the optimization. Anyway, I completely understand what you're saying, and yes, I also do my websites based on my tastes and my likes. I like a website like mine, sincerely, and I'd like to have there people like me who like this type of things. Stop. If they don't like my website, ok, no problem. I'm not here saying that you have to signup there. I completely agree on all of your points to be honest. And trust me, even if I could seems like one who doesn't listen, it is simply not true. You told me to disable ClodFlare, let's say a month ago or so, and it seemed like I ignored you in that discussion were you posted that, but that was untrue. I was just "waiting to see"; simply testing. Now I have an idea on it. If I disabled it straight when you told me to do so, I will have probably used it tomorrow just for and with the curiosity to test it out and see how it was working for my website.

To enforce my point here I have also to say that mine is a general discussion board. And there are so many out there. So I also thought that maybe a good appearing style could bring up more people to join too. But as said and said again, this is still a singular subjective thing.

Excuse me in advance if I offended you or whatever else, if this happened, in regards to respect. And obviously excuse me if you see any error in my grammar or spelling, I'm still Italian after all. :D
 
I mean, all this PC view style and performance talk is really secondary, what with more than 60 percent of all web users now using mobile devices and browsers, (and that number is growing) your real work for the future is making your site mobile friendly. Have fun with that. Here's a report.



Yes I know this, but there are also a lot of peope still using desktops. And for mobile users I installed TapaTalk and it works great, at least for now.
Obviously not a thing to not consider for future development, this is sure.
 
Last edited:
Excuse me in advance if I offended you or whatever else, if this happened, in regards to respect. And obviously excuse me if you see any error in my grammar or spelling, I'm still Italian after all. :D
No, I am not offended at all. Not even annoyed. It's a humorous exercise really, after all I was once just starting out too and did ALL the things you've done and thought I was the Bee's Knees.

But - let's not misunderstand: Nobody ever said or even hinted that you haven't been listening. All I said was, it appears that you only want to take it just so far, to help performance.

Also, what you said earlier about going to plain jane default style - nobody's suggested that either. You need to TEST the default install, not try to actually use it and live with it. After the baseline testing is over you need not ever see default again.

Like I said before, the goal is balance. Achieving really good performance and also having some of the bells, whistles, glitz and glamour you like. Some of the latter needs to be sacrificed in your case though, because it is demolishing your performance. The balance isn't there.
 
Back
Top