Donncha: WP Super Cache 0.9.9.7
WP Super Cache is a full page caching plugin for WordPress that makes your website run much faster!
I’ve just released a new version and the biggest change in this one is the addition of Content Delivery Network (CDN) support thanks to Mark Kubacki who allowed me to integrate his OSSDL CDN Off Linker plugin. (Please go visit his blog and say thank you if you use this feature!)
The CDN support simply rewrites images, CSS and Javascript files so they point at a different hostname. That hostname can be another virtual host on your own server (aka “Poor Man’s CDN”) pointing at your WordPress install or a fully fledged CDN. If your CDN supports “origin pull” then all the files on your server will be copied there as they are requested by visitors. Otherwise you’ll have to transfer the files over manually.
Apart from that, bugs have been fixed, a few features have been tweaked including the uninstall script which has been streamlined somewhat.
I also added links (on the “Easy” settngs page) to some plugins and tools you may find useful in making your site run faster.
Problems? Go to the forum and someone may already have had that problem and solved it. If not, post there and you’ll get a reply.
Related Posts
Tags: Cloud Hosting - Coding Web 3.0 - delivery - features - file - full - HD Video - Hi-Def Multimedia (HD) - host - HTML 5 - images - Multimedia and Video Platforms - Multimedia News - Music on The Web - Online Marketing - Open Source Software (OSS) - script - server - site - The Bleeding Edge of Tech - The Blog Roll - Vlog - websiteRead More...
PHP 4 and MySQL 4 End of Life Announcement
Our approach with WordPress has always been to make it run on common server configurations. We want users to have flexibility when choosing a host for their precious content. Because of this strategy, WordPress runs pretty much anywhere. Web hosting platforms, however, change over time, and we occasionally are able to reevaluate some of the requirements for running WordPress. Now is one of those times. You probably guessed it from the title — we’re finally ready to announce the end of support for PHP 4 and MySQL 4!
First up, the announcement that developers really care about. WordPress 3.1, due in late 2010, will be the last version of WordPress to support PHP 4.
For WordPress 3.2, due in the first half of 2011, we will be raising the minimum required PHP version to 5.2. Why 5.2? Because that’s what the vast majority of WordPress users are using, and it offers substantial improvements over earlier PHP 5 releases. It is also the minimum PHP version that the Drupal and Joomla projects will be supporting in their next versions, both due out this year.
The numbers are now, finally, strongly in favor of this move. Only around 11 percent of WordPress installs are running on a PHP version below 5.2. Many of them are on hosts who support PHP 5.2 — users merely need to change a setting in their hosting control panel to activate it. We believe that percentage will only go down over the rest of the year as hosting providers realize that to support the newest versions of WordPress (or Drupal, or Joomla), they’re going to have to pull the trigger.
In less exciting news, we are also going to be dropping support for MySQL 4 after WordPress 3.1. Fewer than 6 percent of WordPress users are running MySQL 4. The new required MySQL version for WordPress 3.2 will be 5.0.15.
WordPress users will not be able to upgrade to WordPress 3.2 if their hosting environment does not meet these requirements (the built-in updater will prevent it). In order to determine which versions your host provides, we’ve created the Health Check plugin. You can download it manually, or use this handy plugin installation tool I whipped up. Right now, Health Check will only tell you if you’re ready for WordPress 3.2. In a future release it will provide all sorts of useful information about your server and your WordPress install, so hang on to it!
In summary: WordPress 3.1, due in late 2010, will be the last version of WordPress to support PHP 4 and MySQL 4. WordPress 3.2, due in the first half of 2011, will require PHP 5.2 or higher, and MySQL 5.0.15 or higher. Install the Health Check plugin to see if you’re ready!
Tags: 15 - Cloud Hosting - Coding Web 3.0 - download - HD Video - Hi-Def Multimedia (HD) - high - host - Hosting - HTML 5 - Multimedia and Video Platforms - Multimedia News - Music on The Web - Online Marketing - Open Source Software (OSS) - percent - platform - server - The Bleeding Edge of Tech - The Blog Roll - VlogRead More...
Mail gets rejected: This mail server requires authentication.
I have a problem sending mail to 1 specific domain on my new cPanel/WHM VPS with Exim mailserver from my external hosted Exchange account. Sending mails to every other e-mail domain on my VPS works fine, only to that specific domain fails.
But when I use an non-exchange email account to send to that domain, it works perfect.
This is the info in the rejection mail:
|
Bronserver: mx1.myoutlookonline.com axel@xxx.eu |
I think the Exim mailserver rejects the mail, because the sending mailserver domain (myoutlookonline.com) is not the same as my e-mail account (mydomainname.be), but in the mail logs on my server I can’t find any notice of the exchange server that connects, or that any mail gets rejected.
I tried adding the IP of mx1.myoutlookonline.com tot the Trusted SMTP IPs and to the /etc/relayhosts, and I tried disabeling some of the ACL Options, but still I get the rejection notice.
So it looks like the problem is the connection from the exchange server to my mailserver.
Anyone has an idea why the mail gets rejected?
Thank you!
Read More...
nameserver IP Setup
I have a VPS. I have a domain registered at godaddy and have the host ns1 and ns2 set to two different IPs. ns1 is set to my main server Ip and ns2 is set to another open IP on my server. I have A records set to these IPs on this domain as well. When I ping ns1.mydomain.net and ns2.mydomain.net they both return the main server IP.
I have sites hosted that are reporting occassional page load issues with "server not found" error. I’m thinking it could be because of a nameserver setup issue.
Read More...
Apache Status From WHM
http://img213.imageshack.us/img213/10/42232474.png
What exactly are all these ?
Sorry for the nooby question and thanks in advance.
Read More...
Help! Mail Hijacked!
How do I know my email has been hijacked?
I "bcc" all emails to my hotmail account.
I am getting emails now that are: to somebodyNOTme@hotmail.com and from somebodyNOTme@hotmail.com.
I am a complete novice at SSH so I hope answers to my problem can avoid this.
What should I do?!?!
Info: I use Horde. I have a virtuozzo VPS server so I think no firewall can be installed.
Read More...
Security token failure & not found error
<br />
The server was not able to find the document (./public_html/gpEasy/data/index.html/) you requested.<br />
Please check the url and try again. You might also want to report this <br />
error to your web hosting provider.<br />
<br />
cpaneld/11.26 Server at 188.72.250.141
What can I do about that?
Read More...
PHP: Fast and easy SQL queries using ezSQL
What’s ezSQL, and why it is useful
On big projects, the usual good practice is to use a CMS or a framework such as Symfony or CodeIgniter to build your site on. But on smaller projects, many developers are still using PHP functions such as
to do SQL queries to the database.
While it’s functional, I do not recommend to use all those
functions: Most websites are using MySQL, that’s right, but if one day you have to deal with another DB like PostGres or Oracle… Your code will not work at all, and you’ll have to rewrite it. Scary, isn’t it? This is why is it recommended to use a database abstraction layer, an API which unifies the communication between your application/website and databases such as MySQL, Oracle or PostgreSQL.
As you can guess, ezSQL allows you to work with various databases very easily. Though, please note that it does not support differences in SQL syntax implementations among different databases.
Also, ezSQL provide a few methods which simplify queries to the database, and help producing a cleaner code.
ezSQL and WordPress
As most of you are familiar with WordPress, you probably know the
class, which allows you to send queries to the database. As wpdb is based on ezSQL, and you’re already familiar with the WordPress class, you won’t have any trouble to learn using ezSQL. And don’t worry if you never heard of WordPress or the wpdb class. ezSQL is extremely easy to learn and to use.
Downloading and installing ezSQL
Right, I have talked too much. How about some coding now? Let start by grabbing your copy of ezSQL. Once you have it, unzip on your server (or hard drive).
In order to be able to use ezSQL in your projects, you have to include two files: The first is
, which is ezSQL core file. The second depends on the database you’re going to use. In order to use ezSQL with a MySQL database, you have to include
.
Once done, you have to create a ezSQL object. This is done easily using your database username, password, name and host. The following example demonstrates the inclusion of the required files and the creation of a ezSQL object:
include_once "../shared/ez_sql_core.php";
include_once "ez_sql_mysql.php";
$db = new ezSQL_mysql('db_user','db_password','db_name','db_host');
Now, you have an object called
. We’ll use it run any types of queries to our database.
Queries examples
ezSQL has a few methods to make SQL queries extremely simple. Let’s see what you can do with it:
Execute any query
In order to insert, delete or most generally, run any kind of query to the database, we have to use the
method. In case of a data insertion, the method will return the insert id.
$db->query("INSERT INTO users (id, name, email) VALUES (NULL,'The Cat','cat@google.com')");
Example of an update query:
$db->query("UPDATE users SET name = 'Patrick' WHERE id = 4");
Select a row
The
method is great if you just need to select a row from your database. The example below executes a simple select query and displays the results.
$user = $db->get_row("SELECT name, email FROM users WHERE id = 4");
echo $user->name;
echo $user->email;
Select a single variable
If you only need a variable, the
method is here to help. Using it is extremely simple as shown below.
$var = $db->get_var("SELECT count(*) FROM users");
echo $var;
Select multiple results
Although the methods documented above are quite useful, most of the time you’ll need to get various rows of data from your database. The method called
will get various data from your database. To output the data, a simple
loop is all you need.
$results = $db->get_results("SELECT name, email FROM users");
foreach ( $results as $user ) {
echo $user->name;
echo $user->email;
}
Select a column
If you need to get a column, you can use the get_col method. The second parameter is the column offset.
foreach ( $db->get_col("SELECT name,email FROM users",0) as $name ) {
echo $name;
}
Debug
When something doesn’t work as expected, ezSQL has a great method to perform some debugging. Not surprising, the method is called
. When called, the method will display the last query performed and its associated results.
$db->debug();
I hope you enjoyed this article and that you’ll use ezSQL in your future projects. It’s a great tool which was very helpful for me many times!
Like CatsWhoCode? If yes, don’t hesitate to check my other blog CatsWhoBlog: It’s all about blogging!
PHP: Fast and easy SQL queries using ezSQL
Read More...
How to create a kick-ass CSS3 progress bar
Please note: The original CSS3 progress bar shown in this tutorial has been created by Ivan Vanderbyl, which hereby gave me the right to reproduce and document his work.
The following tutorial and the demo works best on Chrome and Safari, correctly on Firefox and very badly in Internet Explorer (eh…I’m sure you hadn’t guessed that).
The Demo

Click on the image to view a live demo. You can also get the source on Github.
Getting ready
Let’s start by organizing our work. To achieve the effect of this tutorial, we’ll need to create 3 files:
-
progress.html
, which will contain our markup.
-
ui.css
which will contain our CSS styles.
-
progress.js
which will contain some additional jQuery animations.
Create a directory on your webserver (or hard drive) and create the files.
The HTML markup
Here we go. Open your
file and paste the following markup in it:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Pure CSS Progress Bar</title>
<link rel="stylesheet" href="stylesheets/ui.css">
<link rel="stylesheet" href="stylesheets/ui.progress-bar.css">
</head>
<body>
<div id="container">
<div id="progress_bar" class="ui-progress-bar ui-container">
<div class="ui-progress" style="width: 79%;">
<span class="ui-label" style="display:none;">Processing <b class="value">79%</b></span>
</div><!-- .ui-progress -->
</div><!-- #progress_bar -->
<div class="content" id="main_content" style="display: none;">
<p>Hello, World!</p>
</div><!-- #main_content -->
</div><!-- #container -->
</body>
</html>
Let me explain the code a bit: On line 1, I’ve declared a HTML5 doctype. Then, lines 12 to 16 contains the markup for the progress bar itself. If you save the file and view it in your browser right now, you’ll see that nothing appears. Don’t worry, we’re going to apply so CSS3 magic in a minute.
Diving into CSS3
Open your
file and paste the following code in it. There’s nothing fancy there, just some basic styles (that I’ve simplified from the original source) for the layout.
body {
background:#eee;
padding: 30px;
font-size: 62.5%;
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
position: relative;
margin: 0;
}
#container {
margin: 0 auto;
width: 460px;
padding: 2em;
background: #DCDDDF;
}
.ui-progress-bar {
margin-top: 3em;
margin-bottom: 3em;
}
.ui-progress span.ui-label {
font-size: 1.2em;
position: absolute;
right: 0;
line-height: 33px;
padding-right: 12px;
color: rgba(0,0,0,0.6);
text-shadow: rgba(255,255,255, 0.45) 0 1px 0px;
white-space: nowrap;
}
Once you are done, we can finally get into more serious things. The code below will make your progress bar come to life. I’ll explain it in details in a minute. For now, copy it and paste it in your
file.
@-webkit-keyframes animate-stripes {
from {
background-position: 0 0;
}
to {
background-position: 44px 0;
}
}
.ui-progress-bar {
position: relative;
height: 35px;
padding-right: 2px;
background-color: #abb2bc;
border-radius: 35px;
-moz-border-radius: 35px;
-webkit-border-radius: 35px;
background: -webkit-gradient(linear, left bottom, left top, color-stop(0, #b6bcc6), color-stop(1, #9da5b0));
background: -moz-linear-gradient(#9da5b0 0%, #b6bcc6 100%);
-webkit-box-shadow: inset 0px 1px 2px 0px rgba(0, 0, 0, 0.5), 0px 1px 0px 0px #FFF;
-moz-box-shadow: inset 0px 1px 2px 0px rgba(0, 0, 0, 0.5), 0px 1px 0px 0px #FFF;
box-shadow: inset 0px 1px 2px 0px rgba(0, 0, 0, 0.5), 0px 1px 0px 0px #FFF;
}
.ui-progress {
position: relative;
display: block;
overflow: hidden;
height: 33px;
-moz-border-radius: 35px;
-webkit-border-radius: 35px;
border-radius: 35px;
-webkit-background-size: 44px 44px;
background-color: #74d04c;
background: -webkit-gradient(linear, 0 0, 44 44,
color-stop(0.00, rgba(255,255,255,0.17)),
color-stop(0.25, rgba(255,255,255,0.17)),
color-stop(0.26, rgba(255,255,255,0)),
color-stop(0.50, rgba(255,255,255,0)),
color-stop(0.51, rgba(255,255,255,0.17)),
color-stop(0.75, rgba(255,255,255,0.17)),
color-stop(0.76, rgba(255,255,255,0)),
color-stop(1.00, rgba(255,255,255,0))
), -webkit-gradient(linear, left bottom, left top, color-stop(0, #74d04c), color-stop(1, #9bdd62));
background: -moz-repeating-linear-gradient(top left -30deg,
rgba(255,255,255,0.17),
rgba(255,255,255,0.17) 15px,
rgba(255,255,255,0) 15px,
rgba(255,255,255,0) 30px
), -moz-linear-gradient(#9bdd62 0%, #74d04c 100%);
-webkit-box-shadow: inset 0px 1px 0px 0px #dbf383, inset 0px -1px 1px #58c43a;
-moz-box-shadow: inset 0px 1px 0px 0px #dbf383, inset 0px -1px 1px #58c43a;
box-shadow: inset 0px 1px 0px 0px #dbf383, inset 0px -1px 1px #58c43a;
border: 1px solid #4c8932;
-webkit-animation: animate-stripes 2s linear infinite;
}
Save your
file and view
in your web browser, and you’ll see your gorgeous progress bar, done without using any image.
So, what’s inside? Let me explain the code a bit.
First, we have two CSS classes:
and
. The first is the container, and the second is the green progress bar.
- Lines 1 to 9: These lines define a webkit-specific animation, which allows us to move an element from a pint to another.
For more details about webkit animations, see http://webkit.org/blog/324/css-animation-2/. - Line 16: The
border-radius
CSS3 property allows you to define a radius and get rounded corners.
- Line 17: Mozilla specific property for
border-radius
.
- Line 18: Webkit specific property for
border-radius
.
- Line 19: The -webkit-gradient property allows you to add a gradient to an element. It works only on Webkit, other browsers will ignore this property.
- Line 20: Mozilla specific property, similar to
-webkit-gradient
with a different syntax.
- Lines 21 to 23:
box-shadow
(and its browser specific alternatives) allows you to add a shadow to an element.
- Line 34: Webkit specific property, based on the standard
background-size
property, which allows you to specify the size of a background image.
- Line 56: Triggers webkit animation defined on line 1.
Final touch: Using jQuery to animate the progress bar
A pure CSS3 progress bar is a very cool thing, but progress bars are here to show progress, so we have to animate it. We’re going to use jQuery to do so.
Open your
file and paste the two line below just above the closing
tag.
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" type="text/javascript" charset="utf-8"></script> <script src="progress.js" type="text/javascript" charset="utf-8"></script>
This code will load jQuery from Google (Which I recommend to do instead of loading your own copy) as well as your
file, which will contain the required code to animate the progress bar.
Now, paste the code below in your
file:
(function( $ ){
$.fn.animateProgress = function(progress, callback) {
return this.each(function() {
$(this).animate({
width: progress+'%'
}, {
duration: 2000,
easing: 'swing',
step: function( progress ){
var labelEl = $('.ui-label', this),
valueEl = $('.value', labelEl);
if (Math.ceil(progress) < 20 && $('.ui-label', this).is(":visible")) {
labelEl.hide();
}else{
if (labelEl.is(":hidden")) {
labelEl.fadeIn();
};
}
if (Math.ceil(progress) == 100) {
labelEl.text('Done');
setTimeout(function() {
labelEl.fadeOut();
}, 1000);
}else{
valueEl.text(Math.ceil(progress) + '%');
}
},
complete: function(scope, i, elem) {
if (callback) {
callback.call(this, i, elem );
};
}
});
});
};
})( jQuery );
$(function() {
$('#progress_bar .ui-progress .ui-label').hide();
$('#progress_bar .ui-progress').css('width', '7%');
$('#progress_bar .ui-progress').animateProgress(43, function() {
$(this).animateProgress(79, function() {
setTimeout(function() {
$('#progress_bar .ui-progress').animateProgress(100, function() {
$('#main_content').slideDown();
});
}, 2000);
});
});
});
Save the file, and view
in your web brower: Wow, the progress bar is now animated. How cool is that?
This Javascript code makes the progress bar go from 0 to 100, and then, it displays a message, which is simply “Hello World” in our tutorial.
I hope you enjoyed reading this tutorial as much as I enjoyed writing it. Have fun with CSS3!
Like CatsWhoCode? If yes, don’t hesitate to check my other blog CatsWhoBlog: It’s all about blogging!
How to create a kick-ass CSS3 progress bar
Read More...
Enhance your web forms with new HTML5 features
Please note that HTML5 is an emerging technique. These examples are not intended for use on a production site. Results may vary according to browser implementation. Please use Chrome or Safari for best results.
Required fields
Whose ever tried to submit a form and gotten an error message saying that you “forgot” to enter your email address? Probably not a lot of us: In fact, 99 percent of all web forms have at least one field marked as required.
In good ol’ HTML, we had to manually display that a specific field is required, most of the time by using a red asterisk. But with HTML5, you can set up a input field to be required:
<input type="text" name="client_name" required>
And on the CSS side, something like
input:required {
border: 1px red solid;
}
will save you a lot of time.
Two similar attributes are also available:
and
. They work exactly as the
attribute explained above.
Placeholders
In a form, an input field always has a label explaining what kind of information is required. While you can currently use the
tag to display a label for a specific text field, HTML5 introduces the
attribute. As shown below, using it is pretty simple:
<input name="firstname" placeholder="Please enter your first name">
The HTML5
attribute works exactly as the
attribute, except that when the user click on the text field, the placeholder text is automatically removed so the user can easily enter his information.
The placeholder attribute currently works only in safari/webkit. Don’t worry about other browsers though, it is pretty easy to simulate placeholders using javascript:
Autofocus
A new HTML5 attribute is named
. If applied to an element, the element will automatically receive the focus once the page is loaded. This can be seen on some sites and most search engines.
Nothing complicated, just use the syntax below, and remember that in HTML5, there’s no more need for attributes to have a value like in XHTML 1.0.
<input name="search" autofocus>
Email fields
Asking someone’s email on a web form is extremely common because email is still the easiest way to contact someone over the internet. HTML5 introduces a new type for the input element, named
.
<input name="email" type="email">
Pattern attribute
When validating a web form, we have to validate the data entered by the visitor. The new
HTML5 attribute allows you to define a regular expression pattern. Only the data that matches the defined pattern will be validated. If the data doesn’t match the pattern, then the form will not be submitted.
This is, in my opinion, an extremely good thing, which will save lots of time to developers when coding forms. Though, remember that you should always validate data on the server side as well.
<input type="text" name="Phone" pattern="^0[1-689][0-9]{8}$" placeholder="Phone" required>
Url fields
Nowadays, many people have a website, blog, or at least a Twitter profile. This is why many web forms offer the possibility to enter an url.
HTML5 introduces a new type for the
element, designed specifically for entering urls:
<input name="url" type="url">
Although I didn’t test it myself, I heard that the W3C validator will raise an error if the value of a url field doesn’t match a proper url structure.
Date pickers
Many businesses are offering an appointment request through their website. In that case, the visitor has to specify the day they would like an appointment. HTML5 introduces the
type for the
element:
<input name="day" type="date">
When clicked, the
attribute will display a date picker so visitors will simply have to choose a date instead of entering it manually. Unfortunately, except in Opera, most browsers don’t have it implemented yet.
Note that a date picker can be implemented on your forms using the following types:
<input type="date"> <input type="datetime"> <input type="month"> <input type="week"> <input type="time">
Isn’t that user friendly? Personally, I can’t wait to implement this in my forms but as I said earlier this isn’t very well implemented in browsers at the time of writing this post. Of course, Javascript is always here to help. On this site I found a simple fallback implementation for the
HTML5 attribute:
var i = document.createElement("input");
i.setAttribute("type", "date");
if (i.type == "text") {
// No HTML5 native date picker support, use jQuery or your favorite framework to create one.
}
Search boxes
To enhance ease of retrieving information, many websites have implemented their own search engine. HTML5 has created a new type for search fields.
<input name="q" type="search">
For now, the only difference with regular text inputs is that, if you use Safari, the search box will have rounded corners. But maybe interesting functionalities will be implemented in the future. Let’s hope, because right now I have to admit that I don’t really see why we should use this type.
Sliders type and step attribute
HTML5 is also introducing sliders: A new type for the input element, which allows visitors to easily select a number instead of entering it manually.
<input name="number" type="range" min="0" max="10">
The example above allows the visitor to choose a number between 0 and 10. If you want the slider to be incremented/decremented 2 by 2, you’ll have to use one more new attribute: step. Here is an example:
<input name="number" type="range" min="0" max="10" step="2" >
That way, visitors will only be able to select numbers like 0, 2, 4, and so on.
Like CatsWhoCode? If yes, don’t hesitate to check my other blog CatsWhoBlog: It’s all about blogging!
Enhance your web forms with new HTML5 features
Read More...



