Using Notepad++ to edit online files

Unlock Your Productivity

notepad++While I was updating the look of my blog I found Notepad++, a Windows notepad replacement one of the most useful tools ever. It gives you syntax highlighting for many programming languages, advanced search and replacement features, line collapsing, ftp down and uploading and so on, but if you just need a simple text editor it’s great as well.

I used it to be able to modify my blog template and php files without the need to upload then after each save. Another feature I found very helpful was automatic line collapsing. This means that it knows where a <div> element begins and ends for example (it also handles many other block elements), enabling me to just collapse lines I don’t need.

Using it to edit online files is also very simple. You need to configure the ftp client, but if you have your server details this should be a cinch. Once you have configured the client, you can connect to the server and access the files. They will be opened inside Notepad++ in a new tab and you can edit the contents. When you save the document it will be uploaded automatically, so you can see the changes immediately online.

First of all, find the icon (fifth from the right) which is labeled “show ftp folders”. Next, click the “open settings dialog” in the sidebar that just opened. You may also want to click the newly opened bottom window as well, this is for server messages and is only needed if you are an ftp whiz or if something goes wrong. So in the settings dialog, click new (at the bottom), type in a name and click rename. Edit the server details as needed, press ok, and you are ready to connect.

Just navigat through the folders as you would do normally, you can even perform folder actions. Double click on an item to open it, and when you save it, it will be uploaded automatically. Your productivity will increase by a lot using this app, no more downloading, renaming, renaming and other types of misery.

Make a to-do list in your Wordpress dashboard

Unlock Your Productivity

wordpress dashboardIf you are a blogger and need to keep track of some of your post ideas, but don’t really like writing drafts, let me show you a great way to store some notes. If you follow this tutorial, all you will really need is to be comfortable with writing notes in a text editor. In addition, if you are familiar with CSS you can do anything you like to your list, but this is not needed.

We will be modifying your index.php file, the one governing your admin, not the website itself. This file can be found in the wp-admin folder, simply named index.php. Download it and make sure to make a backup copy. Open up the file with a text editor, I prefer Notepad++, and search for the following line:

<p><?php _e(’Use these links to get started:’); ?></p>

You may notice, that this is the first line of your admin dashboard, so let’s put a to-do list above this. Now there are two ways you can go about this. You can either put the list right here, or you can write it in another file, and tell the page to call that file. Writing it here is fine, but you don’t want to go through all this code whenever you want to edit the list right? So let’s place it in a different file, to make it easily editable. Above the line we just searched for, type the following.

?php include(”todo.php”); ?>

This will tell your browser to load the contents of the file “todo.php” right here. All we have to do is create a new file, name it “todo.php”, edit it in whatever way we want, and upload it to the same folder that “index.php” is found in. First of all, create a new simple text document and save it, naming it todo.php naturally. Now we need to write the list, in the following form.

<ul>
<li>List item 1</li>
<li>List item 2</li>
<li>List item 3</li>
</ul>

Save the file and upload it, you should have a nice little list of things to do on your dashboard. It could be useful to jot down some long term things if you don’t feel comfortable editing this list all the time. If you think that rearranging and touching the list takes a long time try some of the advanced features of Notepad++, it can upload files directly to where you want it to, but more on this soon, in another article.

This article is part of the Wordpress customization series, with more to come, like skinning the admin interface, so be on the lookout for new parts. If you would like me to cover anything specific don’t be afraid to suggest.

Hack Your Day theme by Daniel Pataki from Blogtastique, content ©2008 Hack Your Day