Monthly Archives: March 2014

You might not need Bootstrap

Its the era of electronic gadgets, that is computers are secondary now a days. People are using smartphones,tablets, for surfing. There comes the importance of responsive websites. When the sites are accessed from a phone, it should be readable & user friendly. And it should be able to execute users needs.

We all know Twitter Bootstrap is response framework that comes with optional js plugins. The twitter css library has arround 6000 lines of code when its not minified.of which you may need only 100-200 lines to make your site responsive. This 6k+ lines of styles is not that light.

If you need only to make your site responsive, we have lots of replacement for this Bootstrap. which are super-light weighted. For example lets say,

Skelton

www.getskelton.com

The skelton css will help you to achieve responsiveness for you site. The file structure for Skeleton is:

index.html: The base html page that includes the necessary initial markup
stylesheets (folder)
base.css: Basic styles of Skeleton
skeleton.css: The glorious Skeleton grid
layout.css: File with no specific styles, but a variety of useful media queries
images (folder):
favicon.ico: Standard 16×16 favicon
apple-touch-icon (x3): All three sizes of Apple touch icons for iPhone 3, iPad and iPhone 4 with retina.

At the same time, we twitter provide themes and javascript plugins for your site.

There’re lots of libraries like Skelton

So before start your project, just think of what you need really, whether just a responsive site or responsiveness and theme for you site.

Installing plugins in Phonegap 3.0

Check whether the plugin supports Phonegap CLI, or not. If it does,  run the command.

Using the Phonegap CLI run:

phonegap local plugin add https://github.com/aharris88/phonegap-sms-plugin.git

This will place the plugin in your plugins directory and update your android.json file that keeps track of installed plugins.

Then when you run,

 phonegap  build android

or

 phonegap install android

Phonegap will put the necessary files into the platforms/android directory. It will update AndroidManifest.xml, res/xml/config.xml, and it will add the src/org/apache/cordova/sms directory.
If it doesn’t,
–   Copy the .js file to your www folder. And link it to your html.
–   Create a package, create the folder structure as yours package name.                        

comnuevalgoplugin

–   Copy the .java file into this package.
–   Update your platformsandroidresxmlconfig.xml adding the following line.

The plugin will be added to your project. Once these things are done, all you have to do implement the js functionality in your app, as you need it.
To view the errors while building:
Add verbose argument to the build command as follow.

phonegap -V build android

If you’re getting a class not found exception, check the config.xml where you added your plugin. The package name might be not correct.