define('DISALLOW_FILE_EDIT', true); define('DISALLOW_FILE_MODS', true); Blog | WP Hosting

Blog

How to use a custom font in CSS

Posted by on 2:01 pm in Knowledge Base | 0 comments

Did you know that with CSS 3 you can load custom true type fonts and use them on your website? It’s relatively simple to do too. First you define a new font face with a URL to your file, then you call it just like you would call a pre-defined font. In this example I’m using the Old Typewriter font from http://www.dafont.com/old-typewriter.font. Once unzipped you’ll end up with a standard .ttf file that you can reference like so: @font-face { font-family:”Old-Typewriter”; src:url(Old-Typewriter.ttf); } Now you can...

read more

Fantastic CSS Border Radius generator for all browsers…

Posted by on 1:08 pm in Knowledge Base | 0 comments

Fantastic CSS Border Radius generator for all browsers by @jacob Bijani http://border-radius.com/

read more

Super awesome code generator for WordPress Developers by…

Posted by on 12:31 pm in Knowledge Base | 0 comments

Super awesome code generator for WordPress Developers by Rami Yushuvaev...

read more

How to change your WordPress URL when installed in a subfolder

Posted by on 4:14 pm in Knowledge Base | 0 comments

Oftentimes people install WordPress in a subdirectory of the main website. One-click installers like to do this. Say your domain is http://example.com, but WordPress lives in http://example.com/wordpress. By default this means that people will have to visit your website at the latter URL. But what if you want your URL to be http://example.com, without that /wordpress at the end? No problem I say – let me talk you through it. It may sound scary, but that’s just because we have to do some tweaks to files we don’t normally...

read more

How to override a parent function from your Child Theme

Posted by on 7:09 am in Knowledge Base | 0 comments

When you’re writing a Child Theme you can easily add your own functions to a custom functions.php file. But sometimes you want to replace or remove a function that the original theme provides. Because the Child Theme’s functions.php file is loaded BEFORE the parent’s file, you can’t just define the same function again as it will be overwritten. You also can’t rely on the original theme providing a “pluggable” parent function, as suggested in the WordPress Codex. What you can do however is to remove...

read more

How to find the directory of your WordPress Theme in PHP

Posted by on 1:34 am in Knowledge Base | 0 comments

To get the directory of the current theme (or child theme) you can use get_stylesheet_directory_uri(). Here’s how to use it. Let’s assume that your WordPress installation lives in http://demo.com, and that your theme is located in a folder named “my-super-theme”. We can assume then that the full URL that points at http://demo.com/wp-content/themes/my-super-theme/ The URL will of course be different for every user of your theme, so you can’t hard code this. Instead, you can use this handy function:...

read more

How to fix “unexpected T_FUNCTION” error in PHP

Posted by on 8:47 pm in Knowledge Base | 0 comments

I tested one of my plugins yesterday and was shocked to see a nasty error message: What was going on? I could have sworn this worked fine last time I tried! Then I remembered that I changed my PHP Version in MAMP, from 5.5.3 back to 5.2.17. And exactly therein lies the problem, because the code that was amiss was something like this: $zendash_updates = function ($a) { return null; }; This is what’s known as an anonymous function in JavaScript, and it didn’t exist in PHP until Version 5.3. If we wanted to be backward compatible, we...

read more

You are a real guru my friend!

Posted by on 1:56 pm in Testimonials | 0 comments

He find the code, he show the right way for editing it and it is working great now !  You are a real guru my friend ! :)) I really appreciate it. Thanks a lot…

read more

How to change the admin footer bar in WordPress

Posted by on 11:09 pm in Knowledge Base | 0 comments

The admin footer bar is the one line of text displayed at the very bottom of your admin interface. By default it reads “Thank you for creating with WordPress” on the left, and shows the current WordPress version on the right. You can however change this if you like. Perhaps you want to provide additional links to services you provide to your clients, or you may want to hide the version or WordPress branding – or you just want to de-clutter and feel that “less is more”. I head you! The two areas can be targeted...

read more

How to get a link to a specific WordPress admin page

Posted by on 5:53 pm in Knowledge Base | 0 comments

To get a reference to a specific admin page (such as Dashboard), we can use the admin_url(), network_admin_url() or get_admin_url() functions, like so: get_admin_url( ‘index.php’ ); You will need to pass the reference to the page you’d like to display. To find out how, simply click on the menu page in question, then look at the URL. Anything after wp-admin/ is the parameter. Those functions are described in detail in the WordPress Codex: http://codex.wordpress.org/Function_Reference/admin_url...

read more