My First Android App “MyGoals”

After having seen a lot of buzz about Android over the last few years, I always wanted to dive into android development. The main motive behind it is that it is open source and a lot of potential the moment it was out. I really like android platform, I have android based mobile as well and we have every kind of app available on its app market. I found some time to dig into android development and made my very first android app named My Goals made with native Java.

In my last article, I had shared GoodTodo app which can be used to set ToDos in your browser; here is My Goals app that you can use to set your todos or goals via mobile as well:

screenshot

Download

GoodTodo PHP and SQlite App

I really like to keep track of tasks and projects (personal or otherwise) I work on. I used to keep my todos list in notepad or by using some other sticky notes application but I wanted dead simple todos app with beautiful looks and simple to use without irrelevant options or goodies. So here I introduce GoodTodo; a todo app made via PHP and SQlite. I chose SQlite because I wanted to make sure that app is portable and of course since it’s small todo app, choosing SQlite for it makes perfect sense. I have used flightPHP framework and idiorm ORM for it.

Here are its screenshots:

localhost todo home localhost todo settings localhost todo categories

 

How to use:

Make sure you have wamp/xampp or other stack installed. Download the app and put in www/htdocs folder and browse to that folder via browser something like http://localhost/todo. Please make sure you have sqlite extension turned on from php.ini if it isn’t already.

So go ahead and download GoodTodo to keep track of your todos.

 

Developer Wallpaper

I like to keep my desktop clean and icons categorized. I had been using Fences but it seems it doesn’t work well with Windows 8.1 and is no more a free product. This made me create custom wallpaper that would help me with categorization of desktop icons thereby allowing me to coin the term Developer Wallpaper or Programmer Wallpaper. I create two categories; one for development related softwares while other for general programs. Here is how my office desktop looks:

desktop

You can download above wallpaper or psd of it below.

desktop_background_template

 

Download PSD

So simply download wallpaper and use it by setting appropriate stretch settings.

PHPStorm Quick Tip: Fix reference class not found errors

Sometimes PHPStorm stops knowing about references or locations of class definitions that were working fine previously. Below is an image (click to enlarge) where PHPStorm tells method not found in class even though class file is included and everything is okay:

phpstorm_class_not_found

This may happen due to a bug in PHPStorm (possibly), unexpected system shutdown, system date time modification or some other reason.

To fix it, you just need to change modified dates of files PHPStorm thinks aren’t there. Once you do that, PHPStorm will reload the changes and will be able to get the reference to those files thereby doing away with such errors. You could simply go to a file and modify it by entering space in its contents or if you have good deals of files, the easiest way would be to touch them. The touch is command line utility that comes with Linux OS. If you are using Windows though, you can download it here. Just run below command to touch all files of the project so PHPStorm knows about class definitions and references of them.

touch -m -c -s -R yourProjectFolder

You can see the options of touch utility by typing touch –help.

 

Automatic git Commit and Push

At times you would like to save some time or find it little boring to repeat same process of committing and pushing to remote git branch; in that case you can find below tip useful. Here is a tip that would help you commit your project changes and push to remote branch with a single click.

Create a file push.sh (notice the .sh extension for bash file) and put following contents in it:

#!/bin/sh
###########################
cd D:/wamp/www/yourProjectFolder
# switch to branch you want to use
git checkout master
# add all added/modified files
git add .
# commit changes
git commit -am "made changes"
# push to git remote repository
git push
###########################
echo Press Enter...
read

Now put that file under your project folder. When you run it, your changes will automatically be committed and pushed to remote branch. Change the commands accordingly to reflect your branch or commit message. Here is the screenshot of what I get after running above commands:

pic

If you would like to customize the commit message, you would modify the script a bit:

#!/bin/sh
###########################
cd D:/wamp/www/yourProjectFolder
# switch to branch you want to use
git checkout master
# add all added/modified files
git add .
# commit changes
read commitMessage
git commit -am "$commitMessage"
# push to git remote repository
git push
###########################
echo Press Enter...
read

And of course, you can add any git commands you would like to automate to that file.

Please notice it is just a tip for those who didn’t know they can automate git commands that way. However, this isn’t usually a good practice; it is always a good idea to review your changes and then commit and push instead of pushing automatically like that. This just turns out to be handy when you are in hurry (or lazy) and are sure about what you are doing.

Please make sure to add PATH environment variable in case script doesn’t work for you.

Save Complete HTML Pages with Pure PHP

screenshot

In order to save complete pages along with all resources such as images, styles and scripts, you could use your browsers, however browsers also save accompanying files in separate folder. For example if you wanted to save some page called sample, browser would save the complete page along with folder named sample_files. Browsers also have their proprietary formats such as MHTML (Mime HTML) for Internet Explorer or MAFF (Mozilla Archive Format) for Firefox but with these you are limited to opening these files in these browsers only which isn’t good or always ideal.

It would be good if one could save all resources of an html page in a single file which can be opened by all browsers which is the html format itself. In order to achieve that, I have created a class that helps you save entire page in a single HTML file along with all its resources, no side folder created, all images, CSS and scripts reside in that single html file which of course can be opened in any browser.

This allows really cool possibilities such as creating your own app allowing to save complete html pages like evernote, creating browser extensions for the same purpose or saving your favorite pages to cloud and more you can put the class to your best use and needs :)

Download Class at PHPClasses

Don’t forget to rate the class :p

Free Twitter Bootstrap Admin Template

Previously I had shared an admin template which was custom-made. Today I share an admin template based on popular Twitter’s Bootstrap CSS framework. It has a lot of benefits such as responsive design, response images, a host of ready-made styles and icons that you can use.  Take a look at some of the images in below given gallery, click to see in full view:

Go ahead and download it here and have fun :)

Download