Icy Phoenix

     
 

Static Content From A Subdomain.

Static Content From A Subdomain.

Article
Reply with quote    Download Post  
Post Static Content From A Subdomain. 
 
Hello Everybody.

I'm interested in optimize my IP installation. My web is http://www.miiconsola.com .

I have done a few modifications related to the performance, but i don't know how to change the URI only for static content.

As i use www always, using another subdomain which doesn't use cookies would increase the performance of my site, as the client doesn't have to send the cookies in the header.

Is there any constant (or var) i can modify to do this ?

Thanks for your help



 
Danielc - View user's profile Send private message  
Danielc [ Mon 14 Jun, 2010 18:31 ]
Icy Phoenix is an open source project, you can show your appreciation and support future development by donating to the project.

Support us


Static Content From A Subdomain.

Comments
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
Sorry, but I do not understand what you need. Can you please try to add some details?

Thanks,
Luca



 
Mighty Gorgon - View user's profile Send private message  
Mighty Gorgon [ Tue 22 Jun, 2010 08:42 ]
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
First, thanks for the answer. I give more details:

As Icy Phoenix uses cookies, my current domain (www.miiconsola.com) uses cookies. When a web browser sends a request to www.miiconsola.com, it sends the cookies in the header. It does this even with static content (like images, css, etc., that doesn't need in any way cookies) from www.miiconsola.com. If we could use another subdomain (for example static.miiconsola.com) for the static content, then the browser wouldn't send the cookies in the header when it is downloading static content (as there is no cookies for static.miiconsola.com), and the performance would be increased.
I want to apply this, so i have to replace some images-related url's. I think that i should modify template files. Am I correct? Is there "an easy way" to do this?

Thanks!

Greetings.



 
Danielc - View user's profile Send private message  
Danielc [ Tue 22 Jun, 2010 17:30 ]
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
I need to have a deeper look at the code before being able to answer. I'm not quite sure that cookies are processed also for images.

Adding another domain for images is surely good because of http requests to a different domain (and this usually speeds up page loading), but I'm not aware on how cookies are processed. Can you please explain me (or link some pages about this topic) further?



 
Mighty Gorgon - View user's profile Send private message  
Mighty Gorgon [ Tue 22 Jun, 2010 19:09 ]
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
Look at this:
http://code.google.com/intl/es-ES/s...ookielessDomain

Some tips to get a better performance (i have done this on my website):
Add this to .htaccess:
Code: [Download] [Hide]
  1. <FilesMatch "\.(ico|gif|jpeg|jpg|png|css)$">  
  2. Header set Cache-Control "max-age=29030400, public"  
  3. Header unset ETag  
  4. FileETag None  
  5. </FilesMatch> 

This extends the expiration date of images and disable ETag which usually doesn't work as expected.

Also i edited overall_header_js.tpl to combine all javascripts and compress them using minify. This works well and reduces so much the page size and speed up it..

Thanks!



 
Danielc - View user's profile Send private message  
Danielc [ Tue 22 Jun, 2010 20:12 ]
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
Thanks, I'll have a look.



 
Mighty Gorgon - View user's profile Send private message  
Mighty Gorgon [ Wed 23 Jun, 2010 20:20 ]
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
Perfect.. I will try to do it on my own way, but it would be good that it is included in the next release

Also, in the page i linked say that you have to buy another domain, but if you use URL's with www (for example www.miiconsola.com) the cookies would be only for www domain (www.miiconsola.com) and not for the domain without www (in this case the cookies would be for miiconsola.com and all his subdomains).

Thanks!



 
Danielc - View user's profile Send private message  
Danielc [ Thu 24 Jun, 2010 17:57 ]
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
I had just a quick look so far... please be patient a bit about this topic, because I need to have some free time to be able to answer correctly.

If you don't get any answer in a couple of week, please bump...



 
Mighty Gorgon - View user's profile Send private message  
Mighty Gorgon [ Tue 29 Jun, 2010 23:08 ]
Reply with quote    Download Post  
Post Re: Static Content From A Subdomain. 
 
Perfect.. I will wait.. While that, i will work in a template for my web.

Thanks!



 
Danielc - View user's profile Send private message  
Danielc [ Wed 30 Jun, 2010 18:40 ]
Display posts from previous:    

HideWas this topic useful?

Post new topic  Reply to topic  Page 1 of 1
 
 




 


 

  cron