Results 1 to 8 of 8
  1. #1
    Newbie
    Overall activity: 0%

    Join Date
    Dec 2008
    Posts
    90
    Liked
    0 times
    Points
    4,931

    Spin boost-your-website-load-time-with-3-lines-of-code

    Many webmasters,want to improve their website loading speed to enhance their visitors’ experience. Many of you, who are using a host which do not give you .htaccess to perform gzip compression on your data stream, can now have an effective solution for that.
    a website script giving you the power to do such as thing. The script which does this great job is called PHP Speedy.PHP Speedy is a script that you can install on your web server to automatically speed up the download time of your web pages. PHP Speedy automatically joined together all the appropriate files and compressed them, greatly reducing the load time of the page.

    http://aciddrop.com/2008/01/21/boost-your-website-load-time-with-3-lines-of-code/

    The script does all of the following:
    Make fewer HTTP requests
    Add a far-future expires header
    Gzip your page’s components
    Minify your JavaScript, CSS and HTML

    First you need to download the script.
    http://aciddrop.com/aciddrop/minify-0.3/aciddrop_site_compression-0.3.zip

    Download file with Script And Demo Page.
    http://aciddrop.com/aciddrop/minify-0.3/aciddrop_site_compression-0.3.1.zip

    Then you need to place this piece of PHP code at the start of your page:
    ***********************************
    PHP:
    require_once('class.compressor.php'); //Include the class. The full path may be required
    $compressor = new compressor('css,javascript,page');
    *********************************************************
    Then this one at the botton of the page:
    ****************************
    PHP:
    $compressor->finish();
    ******************************
    you can check out the test pages here:
    web-site speed boost test page WITH compression
    http://aciddrop.com/aciddrop/minify/

    web-site speed boost test page WITHOUT compression
    http://aciddrop.com/aciddrop/minify/compress_me.php?compress=no

    For webmasters starting out, make sure your template already has the code! If you have a wordpress blog, you might be happy to know that a plugin has been released for it which implements PHPSpeedy on it. Click below to know more. Happy coding!
    http://aciddrop.com/2008/03/07/php-speedy-wordpress-plugin-preview-release/

    According to Yahoo’s YSlow Firefox Plugin, the demo page whcih had a ranking of F(45) improved to a ranking of A(97).

    Requirements
    A server running at least PHP4. For JavaScript minification to work as well, PHP5+ is required.
    You should set the folder where you are running the class from as writable

    Download

    You can download PHP Speedy from this link:http://aciddrop.com/aciddrop/download/php_speedy_wp_0.5.2.zip

    Installation - via auto-install

    In order to install PHP Speedy you should:
    Download and unzip the PHP Speedy package into its own directory
    Point your browser to the PHP Speedy directory
    Follow the installation instructions
    Installation - manual

    If you prefer to manually install things:
    Download and unzip the PHP Speedy package into its own directory
    Delete the index.php and install.php files
    Open config.php
    Fill in the blanks for the variables (apart from username and password). You might enter something like this:
    $compress_options['document_root'] = “/home/my_site/public_html”;
    $compress_options['javascript_cachedir'] = “/home/my_site/public_html/aciddrop/php_speedy/”;
    $compress_options['css_cachedir'] = “/home/my_site/public_html/aciddrop/php_speedy/”;
    $compress_options['minify']['javascript'] = “1?;
    etc
    Make sure the directories you specified for the cachedirs are writable
    For the GZIP, minify and expires options 1 is on and 0 is off
    Open the php file that controls the output of HTML that you will be compressing. This might be something like index.php. Include the php_speedy.php file at the very top, i.e like this:
    require(’/home/my_site/public_html/aciddrop/php_speedy/php_speedy.php’);
    Add this code at the very bottom $compressor->finish();

    Source:
    http://codefusionlab.co.cc/boost-you-website-speed-by-500-with-3-lines-of-code/

    php speedy
    http://aciddrop.com/

    wordpress plugins: http://aciddrop.com/2008/03/07/php-speedy-wordpress-plugin-preview-release/

    php speedy: http://aciddrop.com/php-speedy
    http://aciddrop.com/2008/01/23/site-speed-boost-script-updated/



  2. #2
    Administrator
    Overall activity: 46.0%

    Join Date
    Nov 2006
    Location
    Malaysia
    Posts
    9,803
    Liked
    1656 times
    Points
    48,740
    Problem with gzip is it won't be 100% compatible with all users.
    There will be some people who tries to visit the site and end up seeing blank pages.

  3. #3
    Experienced User
    Overall activity: 0%

    Join Date
    Jan 2008
    Location
    Nearer than u think
    Posts
    1,046
    Liked
    0 times
    Points
    7,469
    Owh that sounds terrible.. Thanks for the info

  4. #4
    Newbie
    Overall activity: 0%

    Join Date
    Jun 2008
    Posts
    11
    Liked
    0 times
    Points
    2,821
    HI All,

    would like to know some information about .htaccess

    e.g how to redirect my blog to my main url like what raymond doing
    means from http://www.yoursite.com redirect to http://www.yoursite.com/blog

    Your reply is appreciate

    Anthony
    Thank you

  5. #5
    Administrator
    Overall activity: 46.0%

    Join Date
    Nov 2006
    Location
    Malaysia
    Posts
    9,803
    Liked
    1656 times
    Points
    48,740
    This is my site's .htaccess file.

    Code:
    RewriteEngine on
    
    Options +FollowSymlinks
    RewriteEngine On
    
    RewriteBase /
    RewriteCond %{HTTP_HOST} !^www.raymond.cc$ [NC]
    RewriteRule ^(.*)$ http://www.raymond.cc/$1 [L,R=301]

  6. #6
    Newbie
    Overall activity: 0%

    Join Date
    Jun 2008
    Posts
    11
    Liked
    0 times
    Points
    2,821
    Hi Raymond,

    First thing first, thank you for your prompt reply.
    What I do with the code you provided:
    1.0 I changed your domain name to mine,
    2.0 Upload to my hosting.
    I already tried what you mentioned above, however it stills not working, and I getting error message as below:





    So I thought It could be I configure my wordpress wrongly, so I check with my webhost they just advice me to add 1 index.html with following code, I personally think that, the code they provide to me is not re-direct is just a frame. Just take a look on coding below:

    <html>
    <frameset rows="*">
    <head>
    </head>
    <frame name="fmeMain" src="http://mydomain.info/blog"/>
    </frameset>
    </html>

    Extra information, on how I configure my wordpress blog
    1.0I configure it in www.mydomainname.info/blog
    2.0I configure using fantastico
    Does this information help?


    Please help on this.
    Thank you.
    Last edited by helpunme; 07-07-2009 at 12:06 PM.

  7. #7
    Administrator
    Overall activity: 46.0%

    Join Date
    Nov 2006
    Location
    Malaysia
    Posts
    9,803
    Liked
    1656 times
    Points
    48,740
    Sorry I made a mistake. That is to redirect from raymond.cc to www.raymond.cc

    Now, make an index.php file on your website with the following code.

    Code:
    <?
    Header( "HTTP/1.1 301 Moved Permanently" ); 
    Header( "Location: http://www.raymond.cc/blog/" ); 
    ?>

  8. #8
    Newbie
    Overall activity: 0%

    Join Date
    Jun 2008
    Posts
    11
    Liked
    0 times
    Points
    2,821
    Hi Raymond,

    For the second code you provide is working now.

    However the 1st example is still not working getting the same error message. (screenshot above)

    do you have any idea why?

    Thank you.

 

 

Similar Threads

  1. Sleazy subject lines spammed out with malware !!!
    By INDRANIL in forum Spyware/Viruses
    Replies: 6
    Last Post: 06-30-2011, 05:56 AM
  2. M$ releases 20,000 lines of code to Linux
    By Polkadot in forum General Forum
    Replies: 10
    Last Post: 07-23-2009, 12:30 PM
  3. What are these red lines?
    By heart reaper in forum General Forum
    Replies: 14
    Last Post: 03-04-2009, 12:27 PM
  4. Replies: 22
    Last Post: 12-22-2008, 11:52 AM
  5. Kaspersky antivirus takes long time to load
    By Jowin in forum Software
    Replies: 27
    Last Post: 11-22-2008, 06:57 PM

Tags for this Thread

All times are GMT +8. The time now is 09:08 AM.