test

I had the opportunity to go to DrupalCon 2015 in Los Angelese this past week. It was my second DrupalCon, my first one being in Portland in 2013. I was very excited to make the trip to see how the Drupal community has grown and what changes were made since my last visit.

The trip itself is also interesting as you start to see other people headed to DrupalCon in the various airports along the way. Sometimes you even end up sitting next to another attendee and share stories while you travel.

DrupalCons are typically much larger than the WordCamps we also attend. WordCamps happen many times a year and in many different cities around the US, whereas DrupalCon happens once a year in the US. This time, DrupalCon was held in Los Angeles, California.

DrupalCon always kicks off with a keynote from Dries Buytaert, the founder of Drupal. Each time I see him speak he gets better and I learn more. The talk was attended by a full house of Drupal Developers, front end users, theme developers, etc. Even in the largest room of the conference center there was standing room only. Dries' keynote was about the current state of Drupal and where it is headed for the future.

This year's DrupalCon had over 3500 attendees, which came from all across the US and even other parts of the world. Over the five days there were 130 different educational talks for all ranges of Drupal experience. They also had several coding sessions, various social events, BOF (Birds of a feather) sessions, and of course the exhibition hall where there were around 70 different exhibitors promoting and educating.

The Drupal culture is very friendly with everyone talking to each other about their particular Drupal experience and projects. They simply tingle with excitement about sharing their knowledge. Drupaites treat each other as equals no matter how much or little experience they have.

Drupal 8's release is much anticipated so that was the focus of most of the talks. It has been in development for a while and is currently in Beta. We all were excited to learn the reelase date and Dries told us "when it's done". This is a great thing as Drupal is not pushing development for a particular date, but rather making sure the quality and functionality is complete. However, I was a little sad we did not have a target date yet.

Unfortunately I was not able to attend the whole event as I had another event to attend. I did attend several talks ranging from Drupal security to getting your site off the ground. All were informative and it is always great to hear different speakers give their own views on the various topics.

If you have never been to a DrupalCon you should go if you ever have the chance. The atmosphere is charged with everyone trying to learn and socialize about all things Drupal. It is a very motivating and friendly environment. I cannot wait until the next one.

rubelixadmin
rubelixadmin

Latest posts by rubelixadmin (see all)

Connect to database with php

Databases house the majority of website data for dynamic sites such as WordPress, Drupal, Joomla, etc. Getting to that data is done via the php scripts. Below I will show you how to access a database in php.

The most common method datbase transactions in php is the mysqli set of commands. This is a newer version of the old mysql commands. The mysql commands are deprecated, which means they are slated for removal in a future release of php.

Below, we see the syntax to the connect command:
mysqli_connect(host,username,password,dbname);
You can see it consists of four separate parts. The first is the host. This is the server that you will be connecting to. Most often the host is set to 'localhost'. This means the database server is located on the same server as the php script. The next three are self explanatory, they are the database username, password, and the database name.

Connecting to the database
To connect, you simply need to call the 'mysqli_connect()' function. The code actually making a connection to a database would look something like this:
<?php
$con=mysqli_connect("example.com","fred","password","my_dbname");
?>

Checking the connection
Never trust that a connection will always work. You should test to see if it was successful, and if not, give an error message. The entire snippet of code should look something like this:
<?php
// Create connection
$con=mysqli_connect("example.com","peter","abc123","my_db");

// Check connection
if (mysqli_connect_errno()) {
  echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
?>

Closing the connection
Once the connection has been made and you have run your query, it is a good idea to close the connection. This code is very simple and is done by calling the 'mysqli_close()' function. It looks like this:
mysqli_close($con);

 

 

8 Reasons to backup your site.

download

Imagine yourself relaxing on a Friday night after a long week of working on your site. You have been working diligently tweaking, adding content, and performing SEO so your site can climb higher in the search engine rankings. You go to check the site once more before signing off for the long weekend you have planned, and your site has disappeared! Was it a hacker? Did the intern delete the files? Whatever it was, all the work you did this week was for nothing, especially if the host doesn't have a copy! Or was it?

Backups are very important to the health of your site. If you have a habit of making backups of your website, this may simply just be a minor inconvenience. If you do not have that habit, you may be in for a very long weekend restoring your site. Which situation do you prefer? I thought so.

Think of backups as your insurance against unforeseen circumstances. Just like the insurance for your car, it helps protect you from the inevitable accident that is always lurking around the corner. Below are eight great reasons why you should always have a personal backup your website.

8 Reasons to make site backups

  1.  Insurance. As mentioned before, the backup serves as insurance against any catastrophes that may occur to your data.
  2. Don't rely on your host. This is not to say hosting backups are bad, but if you notice your mistake too late, the host backup copy may have run and the corrupt or missing files will be in their backup as well.
  3. Accidents happen. The intern you just hired may be slightly less savvy than you and not notice they overwrote your latest work. Or perhaps you deleted the wrong file by mistake when making the updates.
  4. Easy rollback. If you make a backup before going on an update spree, you can always restore the backup if you did not like the results. This is much easier than manually undoing all the changes you just made.
  5. It's easy. Backups take just a few moments and can even be automated. Anything this easy that can save your goose should be a no-brainer.
  6. Testing. Having extra database backups can come in handy for creating duplicate test runs. This way you do not mess up your production data.
  7. Peace of mind. Sleep better knowing the high school hacker cannot permanently destroy your site while you dream.
  8. Corruption protection. Files and databases can become corrupt. It is better to lose a days worth of data than the last three years of your blog.

With all these reasons for backing up your site, it doesn't make sense not to! For those with cPanel accounts, the manual process is very easy. You can make backups of your data at any time and download it to your local computer for safe keeping. See just how simple it is in the article link below.

Backing Up Your Website