Archive for Web Hosting Articles

What is CodeIgniter, and how does it work?

What is CodeIgniter?

ci logo2

CodeIgniter is a free, open-source, easy-to-use, object-oriented PHP web application framework, providing a ready-to-use library to use with your own PHP applications. For example, there is a Database API to make it easier and more convenient to execute SQL queries, such as SELECT, UPDATE, DELETE, INSERT, etc., without having to create a lot of repetitive code yourself. This is how an application framework is useful in application development.

CodeIgniter is object-oriented

Using CodeIgniter requiring knowledge of using the object-oriented programming technique in order to be able to use CodeIgniter effectively, and to understand what happens when you are using certain features in CodeIgniter.

But, what is object-oriented programming?

It’s quite difficult to explain object-oriented programming because from a conceptual point of view, it is difficult to understand. However, the main purpose of object-oriented programming is to make application development easier, especially as applications become bigger, with large structures. Object-oriented programming allows application code and logic to be easier to understand, structured and coherently in place, making it easier to develop and extend your application’s features and functionality. With procedural programming (which is merely standard code executed line-by-line with the use of functions as a container for code that help prevent repetitiveness and “reinventing the wheel”), applications can become a mess if they aren’t developed in a way where everything is well laid out, coherent and structured, and can be more difficult to extend and add new features and functionality to your applications later on. With object-oriented programming, in a way, you are forced to be coherent and have your code structured correctly.

Classes and Methods

What are classes and methods? These are the first concepts you’ll be introduced to if you are learning object-oriented programming from most books or online resources. Say you’re creating a framework. You’ll have different classes for different parts of your framework. One being a “Database Class”, one being an “E-mail Class”, and so forth. Of course, in this case, the Database Class is like the CodeIgniter Database Class, providing a set of ready-made methods for you to use so you don’t have to create them yourself in order to execute certain application logic, such as inserting, updating and removing database records quickly, without having to “reinvent the wheel”.

The methods are what contain the application logic, and the class merely holds many related methods together. And this is exactly how your applications would work with the use of the object-oriented programming techniques.

How does CodeIgniter work?

CodeIgniter has a very extensive user guide, which is much better than documentation on some other frameworks, such as CakePHP (which is another PHP framework).

CodeIgniter has classes and helpers.

Classes

Classes contain a collection of methods and properties (properties are essentially variables in an object-oriented context).

For example, here is an example using the Database library within CodeIgniter:

$this->db->get(‘users’,$data);

In any application you make using CodeIgniter, your own classes inherit (or extends) the CodeIgniter class, and so this is why the $this variable is used, which refers to the current class/object. So to call another method within your class, you would use $this->method_name().

Helpers

Helpers contain ordinary PHP functions. Such as the Form Helper.

Other interesting features of CodeIgniter

While this is by no means unique to CodeIgniter, and other web application frameworks use this approach to application development, CodeIgniter primarily uses the Model, View, Controller (MVC) approach to application design and development. It essentially separates application logic from the application design/view. The application logic is the Controller, whereas the application design/view is the View. The Model is for database interactions. There are more complex scenarios where the MVC approach is used, but for basic to intermediate CodeIgniter applications, the Model would contain database interactivity logic of sorts.

Active Record

When you saw an example of using the Database Class above, that code is actually part of the Active Record Class that is part of the Database library.

Active Record is where your work can be shortened by providing an easy and convenient way to execute certain SQL queries without having to write out the entire SQL query yourself. Active Record essentially allows information to be updated, retrieved, added and removed conveniently.

More information on CodeIgniter

The CodeIgniter framework works on all of our shared and reseller servers, and can be installed on pretty much any server with PHP installed. As of writing, CodeIgniter requires PHP version 5.1.6 or higher and obviously a database will be required for any database-driven PHP application (as of writing, MySQL 4.1 or higher). CodeIgniter also supports PostgreSQL, Oracle, SQLite and ODBC. For up to date server requirements, see the CodeIgniter user guide.

Visit the CodeIgniter website

Related Posts:

  • No Related Posts

Making your websites mobile-friendly is becoming increasingly more important

For years, mobile phones (on a software and hardware level) were simply inadequate for displaying websites as they were meant to be seen. However, many phones back then displayed websites without images or in a conventional view in order to make it optimised for the software and hardware of the phones at the time.

As time has gone on, however, especially with the invent of the Apple iPhone back in 2007, all smartphones now can show the entire website as it is seen on a desktop PC (albeit shrunk down) because smartphones are more powerful than standard mobile phones or featurephones and the software allows the full website to be rendered within the mobile browser application.

So why is it “more important” to also focus attention on making your websites or blogs mobile-friendly?

euk blog mobile 258x300Well. First, if you use WordPress, it’s incredibly easy. Simply install the WordPress Mobile Edition plugin (you can find and install it directly via the WordPress Administration Panel). It instantly gives your blog a mobile-friendly user interface if a mobile phone or user agent is detected.

However, you may wonder why it is even important at all. Well, foremost, let’s look at usage statistics:

 

 

StatCounter mobile vs desktop GB monthly 201012 201112 300x175With StatCounter, smartphone usage for surfing the web is at 9.39%. That’s a high number. That equates to 1 in 10 connections to a website may well be from a phone. And because smartphones are becoming used more and more for what our computers would usually be used for, many people simply use their smartphone instead of their computer to do basic computing tasks such as searching for something or for the answer to something, browsing the web, reading the news, etc.

Why should I build a mobile user interface? Smartphones are capable of viewing the full website as it is.

That is true, yes. But many websites now have specialist user interfaces specifically made for smartphones such as iPhones, Android Phones, BlackBerry smartphones, etc. For example, the WordPress Mobile Edition plugin transforms your WordPress blogs into a readable, clean format for small-screen devices. With the use of JavaScript, you can detect the user agent of the visitor visiting your website, and if it equates to a mobile browser or operating system, you can choose to provide them with a mobile user interface.

It also equates to a better user experience. Your users don’t want to be scrolling a lot to read the content on your website.

You could also consider making your forums mobile-friendly as well. While there would probably be plugins or add ons for the various popular forum systems out there, such as vBulletin, phpBB, etc., you could also install add your forum to mobile apps such as TapaTalk (Board Express on Windows Phone) which allows your users to access your forum via a mobile-friendly app. And it works for many popular forum systems, including vBulletin, Invision Power Board, MyBB, SMF, phpBB, etc.

However, there are disadvantages to using TapaTalk or Board Express. For a start, I don’t even think you can make any money if all your mobile users end up using TapaTalk or Board Express because your forum is available on it. If this is the case, I wouldn’t be surprised if forum owners have decided not to go this route because there is no way to make money when users are using your forum through a third party solution, in which you cannot make any money.

Inherent advantages to creating a mobile-friendly user interface

The inherent advantages are quite obvious. It makes it easier for your users to navigate your website or blog without having to pan and scroll a lot. It makes it more focused on the content on your website or blog.

Some other sligthly-irrelevant advantages is that it could save you bandwidth. Even though it may to matter to you much, if 9% of your visitors are from mobile devices, you could save yourself a portion of bandwidth if the mobile user interface transfers less data to the visitor when they visit your website.

Inherent disadvantages to creating a mobile-friendly user inteface

Well, if you have a mobile user interface, it would be very difficult to include advertisements unless you are able to fit in mobile-sized advertisements that coherently fit into your mobile user interface. If it does, great, you may make money via your mobile user interface, but often is the case that with a mobile user interface, such as with the WordPress Mobile Edition, while your users would be getting a better user experience, they would also not have the distraction of advertisements you may have installed on the desktop user interface through WordPress plugins such as Awesome Ads. So unless you can find a suitable way to add mobile-friendly advertisements to the mobile user interface part of that WordPress plugin, you would be without advertisements which is something to take into consideration. If a lot of your traffic (say, 9%) comes from mobile phones. That is the potential for up to 9% of loss revenue that may be potentially there if you had mobile ads on the mobile user interface. You may want to take this into consideration.

Some examples of mobile user interfaces that work perfectly on smartphones include:

engadget 283x300neowin 300x294

 

neowin ads 300x86If you noticed on the Engadget blog, they have mobile ads. It is definitely possible to implement mobile ads, Neowin’s blog (second image above) also has mobile advertisements at the top, too. There are many mobile ad firms you can use as well, in order to generate revenue through visitors on mobile devices.

Concluding…

ebuyer mobile 300x238So, there are many resources online to help you make your website mobile-friendly. This article is to help introduce you to as to why making your website mobile-friendly is indeed a good idea, because based on ever updating mobile data, it is becoming very important – even for businesses such as e-commerce stores, as more people may wish to shop on their phones. Of course, many e-commerce stores may opt to create an actual app for smartphones which provides rich user experiences with a mobile-centric app user interface, but others decide e-commerce stores decide to create mobile-friendly versions of their e-commerce store.

Related Posts:

  • No Related Posts

eNlight Cloud – Cloud Computing as it should be. Auto Scaling and Completely Cost-Effective

Today, eUKhost Ltd. introduces an entirely new cloud computing product called “eNlight Cloud” – a cost-effective, auto-scaling, pay-per-use cloud hosting solution. While “pay-per-use” sounds daunting, with eNlight Cloud, it allows you to pay only for the resources you may need and only pay for what you use, and so you will only be charged for what resources you use on your virtual machine. And eNlight will intelligently auto-scale resources to meet the demand and needs of your eNlight Virtual Machine up to the maximum resources that you have allocated to pay for, in the event that those resources are required; for example in the event of peak traffic to your business or online website(s). It is “pay-per-use” done right. With eNlight Cloud, you are always in control so no nasty surprises at the end of your billing period.

How does eNlight Cloud work?

“eNlight” is an intelligent cloud computing platform that works on the hardware virtualisation technique, with eNlight residing between the system hardware and the operating system of virtual machines. Resources (such as CPU and RAM) are automatically loaded as per the requirements of your virtual machine, with the resource scaling done automatically which is incredibly cost-effective, meaning eNlight Cloud will turn out to be a much more affordable solution to a dedicated or virtual private server.

The eNlight Cloud platform is powered with metering tools, which allows “pay per use” billing for eNlight Cloud customers, with resource usage statistics recorded every minute.

eNlight can intelligently detect when your virtual machine requires more capacity and resources, and will de-scale resources accordingly as required. This equates to a complete hosting solution while being cheaper than a virtual private or dedicated server, as for a large majority of server customers, not all the resources are used at any one time while a server is online, so you are not paying for resources you aren’t using unlike a virtual private or dedicated server.

eNlight Cloud comes with full root/administrator access.

Like a dedicated and virtual private server, eNlight Cloud comes with full root/administrator access, meaning you have full control over your eNlight Cloud VM while giving you the convenience of a ‘managed server’ solution by our in-house technicians, as do our VPS and Dedicated Server hosting customers enjoy. While you have full control over your eNlight VM, you can also ask our technicians to install any necessary services or software you may require on your eNlight VM at any time.

eNlight comes with the eNlight Control Panel, which provides server management of your eNlight VM. eNlight is like a standalone virtual server and so you can easily go ahead and install cPanel or Plesk if you wish by choosing the CentOSCP template when setting up a new VM upon after ordering your eNlight, for the management of web-based applications and data, while having the benefits of the eNlight Cloud scaling technology.

There are no contract periods with eNlight.

eNlight comes with absolutely no time-bound contracts, which equates to greater flexibility and freedom on the duration of your eNlight Cloud service. You can shut down your eNlight Virtual Machine at any time and only pay for what you have used.

eNlight is a cloud environment.

With centralised storage and backup servers in the case of hardware failure, with eNlight, we are able to offer a 100% uptime guarantee for your eNlight VM which is represented in our 100% uptime Service Level Agreement (SLA). This is the power of a centralised cloud hosting infrastructure.

eNlight Control Panel.

The eNlight Control Panel allows you to create and manage multiple virtual machines while leveraging the eNlight Cloud scaling technology with the power of a centralised cloud hosting infrastructure.

You can purchase multiple virtual machines running under eNlight right within the eNlight Control Panel.

What is eNlight suitable for?

eNlight is a perfect replacement for virtual private or dedicated server customers that are looking for a cloud computing alternative, with the benefits of our auto-scaling technology with the inherent cost-savings as a result.

You can easily have cPanel or Plesk as the control panel environment for website management on your virtual machine(s). If you are a web hosting provider, your customers being hosted on your servers with the eNlight backend will enjoy continuous speed and reliability irregardless of the resource requirements of your server. You can always ensure your eNlight service has adequate resources for any eventuality, for example in the event of a new product launch with your business.

Differences between eNlight and a standalone server?

eNlight is much like a virtual private server, using virtualisation techniques. Your eNight Cloud will consist of “virtual machines” and the resources of these virtual machines are managed automatically by eNlight in the background. Like a virtual private or dedicated server, you will have full (root) access to your virtual servers allowing you to the same control and customisability as you’d expect on a standard virtual private or dedicated server from us or any other web hosting provider. And of course, eNlight is fully managed too, so you can contact our senior technicians to install, update or upgrade any software or package you require on your virtual machines at any time.

How do I purchase eNlight Cloud or get further information?

You will find more information via our eNlight Cloud section of our company website, which is where you can also buy eNlight Cloud hosting. You can customise the resources you may need at any time throughout the lifespan of your eNlight VM on the page, prior to ordering (which are the maximum values of your VM). You can also change the maximum values of your VM (such as RAM and CPU) at any time.

If you have any questions, please contact our sales department. You can contact us via the client area, over the phone or talk to us over live chat.

Sales (Tel.) : 0808 262 0255

Sales (E-mail) : sales@eukhost.com

Related Posts:

  • No Related Posts

Enabling and Disabling the Manually Updating Awstats Feature in cPanel via WHM and SSH

Awstats Website Statistics

Due to the large competition in the uk web hosting market, most of the web hosts enables various features on the server. Allowing users to manually update Awstats from cPanel is one of the best features many web hosting providers enable. When this feature is enabled from the WHM, the cPanel users can simply see and click the link “Update now” to update their Awstats for their websites.

Enabling this feature usually consumes a lot of server resources, and is not a good idea for server owners to enable this feature especially, when a high traffic website is hosted on the Dedicated Server. This feature can only be enabled or disabled using root access, which means the user has to own a either a dedicated server or a virtual private server or must have root access to the server. User can enable or disable this feature using two different methods via WHM and SSH.

By default, this feature is disabled on the servers and needs to be enabled to allows users to manually update awstats from their cPanel. If you are a dedicated server hosting reseller, definitely you would like to save your server resources by disabling this feature if it is enabled.

How to Enable and Disable the “Allow users to update Awstats from cPanel” feature via WHM control panel?

Step 1: Log-in to your server WHM account

WHM Control Panel Login

Step 2: Click on Server Configuration >> Tweak Settings: (see image below)

Step 3: Once you click the Tweak Settings, the right pane will reload with several options as shown in the image below:

Step 4: Click on the “Stats and Logs” tab to get the option. Now click the option “On” to Enable the feature or click on the “Off” option to Disable the “Allow users to update Awstats from cPanel” feature and save the settings.

How to Enable and Disable the “Allow users to update Awstats from cPanel” feature via SSH Root Login?

Step 1: Log-in to your Dedicated Server using the SSH root login.

Step 2: Open the desired user’s Awstats directory by following the below path:

#/home/cpaneluser/tmp/awstats/

Step 3: In the directory, find out “awstats.yourdomain.com.conf” file and edit it using your choice of editor. Here we are using the “vi editor”.

#vi awstats.yourdomain.com.conf

Step 4: Search the file for the following line and change the value “0 or 1” to enable or disable the feature:

AllowToUpdateStatsFromBrowser=1        [Value “1” will enable the feature]
Or
AllowToUpdateStatsFromBrowser=0        [Value “0” will disable the feature]

Step 5: To save the settings to the .conf file, enter the following command:

esc :wq!

Step 6: The changes won’t take effect until you run the following script:

#/scripts/runweblogs username

Run the above command and your cPanel will start showing the “Update now” button on the Awstats page.

Related Posts:

  • No Related Posts

Two Most Lucrative Ways to Earn Money Online

Today, due to the accumulation and constant growth of information that we access through the Internet, we are literally bombarded by systems and online opportunities to earn money on the Internet.

Now, the most important question is whether you can really make money over the Internet? The answer is Yes, definitely you can, and not only you can earn an extra income, but a lot of money. It is also obvious that (for) the growth of a garden, you need to sow, plant and grow their seeds for them to gain their fruit in the future, the same rule applies to any online business. To succeed on the Internet, you need knowledge, attitude and a constant learning, because every day that passes, become more obsolete regarding the Internet.

The very first thing you need to understand is that the only place where the term “money” comes before work is in the dictionary. You won’t be able to generate any money on the Internet, if you are not willing to invest your time and mostly money. Remember, the money invested and applied correctly, will attract more money. The attitude is also a very important item, because you will have to work to earn the money, it won’t fall directly in your hand from the sky. Efforts are mandatory to get success in an online business.

Before considering the forms of gain, it would be much more advantageous if you have a blog to promote your business. The importance of a blog should not be ignored. A blog is like a commercial, in which you view a product to sell.

As an experienced person in this area I can definitely differentiate the best opportunities through which you can make money online.

Following are the two most profitable and proven methods through which you can earn money online on the Internet:

Affiliate Programs

Affiliate programs are one of the interesting options to generate thousands of money (£££) online. Today, affiliate programs offer almost all types of products and services. Most of the affiliate programs are totally free to join. The working of affiliate programs is very simple, it is a kind of referral program. If you recommend any products or services of a particular company, and every time a purchase is made through your recommendation, a specific amount of commission is credited into your affiliate account which can be withdrawn once a particular amount is gathered in your account.

Best Paying Web Hosting Affiliate Program

For example, just imagine, you are a big fan of cars. One of your friends knows that you master the subject well and asks you to recommend a performance oriented car to buy. So, you recommend a good car to him and he makes the purchase. Thus, the car dealer, where he bought the car will deposit a certain amount of commission as per their policy in your affiliate account as a thank you statement and for recommending a customer. It’s that simple, can you imagine that?

Affiliate programs work the same way on the Internet. Of course to get good outputs it is necessary to know effective marketing strategies in the area. For example, you can recommend the products or services via your website or blog. Thus, if you have many visitors and an interesting article about the benefits of the program, certainly many people would be interested in it, and then you can earn your commission. Or you can send mass emails such as newsletter, ezines, etc… to people that have subscribed your website feeds to know more about your products and services. Since, most of the programs are free to sign-up, you earn lots of money without investing a single penny. Some affiliate programs also offer content, information and banners to make the promotion easier such as Web Hosting Affiliate Program, which is one of the great affiliate programs for those who wish to Earn upto £300 per sale without investing money.

Affiliate programs offer great opportunities to make money online on the Internet, as there is no risk involved and you won’t have to produce, sell, deliver, serve customers and provide support. All you need to do is recommend a product or service to customers and ask them to visit the product through your unique affiliate link via which sales recommended by you are tracked.

The most important things required to get success in Affiliate Marketing are deep knowledge about products and services, good marketing strategies, excellent communication skills and convincing power.

Reseller Hosting

Due to the huge competition, any idea of doing online business you come up with, still you will find that it is already in use. It’s a fact that, there is no more original online business ideas left through which you can make money online. So, choosing a profitable online business idea is very essential. Well, if you like to opt for such profitable business idea, then I would recommend you to opt for reseller web hosting services.

Don’t worry, I don’t mean that you have to buy a web hosting server for that or invest thousands of money. Since web hosting is a common requirement for anyone who wants to establish an online business with a website, there is a huge competition in the web hosting market. The Internet is full of free reseller hosting plans along with affordable reseller hosting plans.

By choosing a reseller hosting plan you become a web hosting reseller, which means you can sell the web hosting service at your own price. Reseller Hosting plans allows you to create your own web hosting plans using the allocated resources. A hosting reseller can create small plans and set the amount of disk space, bandwidth and price as per his requirement.

Reseller Hosting plans let you brand your web hosting business with your own company name. It means you can state that your company is private and not a reseller. Once you sign-up for a reseller web hosting plan, you can start creating plans, sell it at your own price and start making money online.

Though reseller hosting is not a new business, but if you show some creativity in your web hosting plans you can still earn a good customer base. The best thing about becoming a hosting reseller is that you don’t have to manage the customers queries as most of the web hosting companies provide “end user customer support”. The key to success in reseller hosting business much depends on the way you setup the web hosting plans, their price and customer support. A satisfied customer simply means a recurring business. Also, most of the web hosting companies now provide all the necessary tools to their customers that are necessary to run a reseller web hosting business efficiently.

Anyway, these are the two main opportunities offering possibility of unlimited gains, where you determine your own hours, and work the way that fits you the best.

782x50 3

Related Posts:

« Previous entries Next Page » Next Page »