Showing posts with label Development. Show all posts
Showing posts with label Development. Show all posts

Jan 24, 2018

10 Free Customizable CSS Snippets for Radio Toggles & Switches

Radio buttons have only recently been open for deep customizations with CSS. The on/off switch design was lifted from Apple’s original iOS and moved onto the web using radios and checkboxes for toggle switches.
1. Accessible Toggles
Accessibility is a huge concern on the web and it’s something you have to consider when restyling an HTML element. These accessible toggles by Chris Hart show just how much you can change with a little CSS.
Each switch has its own unique style including custom animation effects. You can click either side of the switch to toggle the result which is perfect for usability on smaller screens.
Overall these switches are some of the best you can use and they’re really easy to customize. However they do rely on checkboxes so form submissions work a bit differently compared to radio buttons.

2. On/Off CSS Switches

If you like a minimalist approach to design then check out these radios created by Nick Bottomley. They’re as simple as can be and they work flawlessly.
The secondary styles even add custom animation effects to the switch where it expands out like a blob before animating. You can add optional labels that light up when switched on/off and you have plenty of room for adding colors and changing styles.
I’d say these switches make the sturdiest base for customizing on/off buttons without building them from scratch.

3. iOS7 Switches

When Apple released iOS 7 it came with many updates including a flatter design and new on/off switches. These iOS7 switches were recreated using checkboxes and CSS3 by skilled developer Bandar Raffah.
The backgrounds have an interesting animation effect where they slide in & out of view along with the switch button. It’s a really unique approach to the design and the fact that it’s all powered by CSS is even more impressive.
If you’re looking for an Apple-inspired design on your site then these checkbox switches take the cake.

4. Pure CSS Circles

For a slightly more customized solution take a look at these iOS switches by Jesse Couch. The labels are built primarily for Chrome and Firefox so they may not work in all browsers like Opera or Safari.
But they do support the “label” element for radios that can automatically switch between values when clicked. This way the user doesn’t even need to hit the radio, but just the label to get the on/off switch working.

5. Win10 Switches

Windows 10 users will know all about their latest changes for better or worse. The new Win10 settings include many custom on/off switches duplicated in this pen.
You can edit the size, color, and padding all through SCSS variables right in CodePen. These switches all use the HTML checkbox element which makes them superior for mobile users. They don’t have much animation but they look great and work well, two factors that always sell quality interface elements.

6. Clean On/Off Toggle

For accessibility you have to consider how checkboxes handle in older browsers and how attributes like aria-hidden operate. That’s the basis of this pen created by Felipe Fialho.
He takes this on/off switch to the highest level of support with an HTML label and custom styles that degrade gracefully. It’s also a nice looking switch and given the simple setup it works well on any website.

7. Switchboxes

These cleverly designed switchbox inputs were created by Victor Knust as a universally-supported solution. Every switch works in all major browsers including IE7 and above.
Because of this wide browser support you will have to work with JavaScript. It’s not much JavaScript, but it is a factor when deciding if these switches could work on your site.
But they look great and offer universal support which is more than most CSS-based switches.

8. Custom Square Toggles

If you’re really going for custom then check out these square toggles by Andrew Gehman. They completely restyle the checkbox design with square corners, a square switch, and custom text.
I can’t imagine this would blend nicely into many websites. However it shows how far you can go with pure CSS3 and this may be a nice codebase to start with if you wanna customize your own checkboxes.

9. Glowing Switch

An original design by Nick Vasile turned into a fully-functioning glowing CSS switch thanks to developer Valentin Galmand.
This interface almost exactly matches the original Dribbble shot which makes the switch even more impressive. It relies solely on CSS3 to recreate the shadow effects and icons in the center. It’s a shining example of how much you can do with pure CSS.

10. Sliding Radio Buttons

This example may be my favorite because it has such a delectable gradient attached to each button. These sliding radios created by Oguzhan Cansever use CSS3 gradients and custom labels attached to each side of the switch.
However these are pure radio buttons so you can only select one at a time. This means if you click the active side it will not switch over.
But if you like that style then this is more than applicable to any website. You can even customize the gradient colors and increase spacing in the switches all through CSS.

Wrapping Up

You can find dozens of amazing radios in CodePen with free code snippets to copy & edit.
If you like these examples be sure to save your favorites and feel free to browse the “switch” tag for more examples.
You should take a look at these code snippets for creating beautiful CSS buttons next or this collection of copy and paste responsive navigation snippets.

Oct 16, 2017

Angular 4 – Tutorial from scratch


Hello everyone, Angular,  as you may already know is one of the powerful and popular JavaScript frameworks. There are currently 3 versions of Angular, in which Angular 4 is the latest. Angular 2, the second version, was completely rewritten to provide more flexibility and more ease in development, then AngularJS, the first version. Angular 4 is the update to the Angular 2 and has the backward compatibility support. Angular is used to create SPA which stands for Single Page Application. The SPA helps in smooth user experience as the page gets loaded at one time only and routing is also done on the same page removing the page to reload.
So, this is the quick brief about the Angular framework, as the Angular 4 is the latest, there are very few tutorials on the internet, most of them are not complete or paid. So, I thought of writing a complete tutorial for Angular 4 and will be trying to cover all the features of Angular 4.  To start with Angular 4, knowledge of AngularJs or Angular 2 is not required at all. It will be helpful if you some experience with HTML, CSS and JavaScript. Also though the Angular 4 uses TypeScript, it is not required to learn TypeScript, JavaScript knowledge will be enough.

Getting Started

With Angular 2, Angular CLI was introduced which stands for Angular Command Line Interface. Angular CLI runs on node JS and helps in the quick creation of the new Angular application. To start creating an application first we need to install Angular CLI and for that, we need to have Node js. To install Node js click on the link  https://nodejs.org/en/download/current/ and install for your platform. After installing Node js open the command terminal, as I m using windows so I’ll open a command prompt. To install Angular CLI type
npm install -g @angular/cliwhere npm stands for Node Package Manager, -g for global to use it globally in the system. To check if Angular CLI is installed properly you can use command
ng –versionto check the version.

Creating Angular 4 Application

Now we can start creating our Angular 4 application. To create a new project, we will be using Angular CLI and will type the command
ng new new-angular-appThis command will create the default structure and files with needed for the development of the project. It will take some time to download the files. After it is completed you will have a configured Angular 4 project. Now let’s see the structure and files inside the folder. I ‘ll be using the Microsoft Visual Studio Code IDE for my development as its free and powerful. Let see the created directories and files for our new angular app.
Inside the root directory, you’ll see 3 folders, e2e which is an end to end testing which we ‘ll be using later. The second one is the node_modules folder which contains the angular files and other required classes for development. We don’t have to do anything in this folder. The last one is the src or the source folder which contains the development files and index.html.
We have some other files which we may not require as default configuration is sufficient for running the application. We ‘ll be doing our development inside the src folder only. In this app, the folder contains the components. Images and other media files can be stored in assets  folder. Environment variables configurations are in the environment folder which as of now we don’t need to change. Out of the other files, we will be using, index.html (rarely) for few imports of style libraries, style.css for application level styling and favicon.ico to change the favicon. Others we can leave to default.

 Inside the app folder except for app.module.ts  all other files will be there for every new component we create. In Angular we can create different components for a different purpose and include it using the selector, we will get in detail later. Every component as app.component.css, which contains styling instructions, app.component.html, which contains the HTML code for that component, app.component.ts, which acts like and controller class and all the javascript code related to events and functionalities are written in this file. For component level unit testing app.component.ts, is there. During development, we will be using various dependencies for Angular libraries which need to imported and added to app.module.tsfile.
This was about the structure of Angular 4 files, now lets start and check the app is working or not. Angular CLI provides a server which we can start and check the output in the browser. To start that go inside the application folder in command prompt and type ng serve this will compile and deploy the app on the local server, which can be accessed through http://localhost:4200 (to change port number ng serve –port_no ). So let’s start the app and see if it is working fine.
Application compiled successfully. Let’s see the output.
As you can see the default page, means the app server is working fine. In the next tutorial, we will start development of a cool and reactive app using Angular 4 and Angular Material. Before that let’s understand some basics of Angular 4

Oct 7, 2016

10 jQuery Security Plugins

How secure is your password? If you are confident enough that no hacker can break your pass codes then you might have to think again. Below are some tutorials that you might want to learn to secure you passwords. Be safe!

1. Password Strength Indicator and Generator

This plugin lets you set the class of an element so that you can do a graphical representation of the strength.
Password-Strength-Indicator-and-Generator.jpg
Source

2. jQuery AlphaNumeric

It is a JavaScript control plugin that allows you to limit what characters a user can enter on textboxes or textareas.
jQuery-AlphaNumeric1.jpg
Source

3. jCryption

t is a JavaScript HTML-Form encryption plugin, which encrypts the POST/GET data submitted by forms.
jCryption.jpg
Source

4. Password Validation Plugin

This plugin offers a function that rates passwords for factors like mixed upper/lower case, mix of characters (digits, special characters), length and similarity to a username (optional) and gives a custom method for the validation plugin that uses the rating function to display a password strength meter, requiring the field to have a “good” rating.
Password-Validation-Plugin.jpg
Source

5. Password Strength – Estimates brute force time

This plugin tries to calculate how many possibilities the hacker needs to try to guess your password. It makes the assumption that it is possible to test 2800 million passwords per second.
Password-Strength-–-Estimates-brute-force-time.jpg
Source

6. Password Strength Meter v2

This plugin works by presenting a global variable score and at the end of the algorithm the plugin will decide the passwords strength according to the score value.
Password-Strength-Meter-v2.jpg
Source

7. jQuery-Encoder

It is a jQuery plugin whose goal is to provide jQuery developers with a means to do contextual output encoding on untrusted data. As applications become more and more reliant on rich client technologies the need for client-side code to have the ability to properly escape untrusted data becomes exponentially more important.
jQuery-Encoder.jpg
Source

8. ChronoStrength

It is a password strength checking plugin. However, rather than just saying “Too Weak” or “Strong”, which don’t really mean much, ChronoStrength displays how long it would take a regular desktop PC to crack the password using a brute-force attack. Seeing that their password would only take 30 seconds to crack might convince people to choose a more secure one!
ChronoStrength.jpg
Source

9. jqCrypt

A simple jQuery plugin to encrypt form data client-side and pass it (with an obfuscated key) to the processor via the POST method.
jqCrypt.jpg
Source

10. RC4 Symmetric Encryption/Decryption

Extends RC4 symmetric encryption/decryption to JQuery. Less than 3KB.
RC4-Symmetric-Encryption-or-Decryption.jpg
Source

Sep 7, 2016

31 Best Websites for Scoring Freebies

As the world becomes even more commercialized, an increasing amount of free stuff can be had through discount offers, recycling efforts and Internet loss leaders. Learning where to look for these deals and free samples can save you a significant amount of money on a variety of stuff. Below are the 31 best websites to check out for free stuff, although not in any particular order:
1. Craigslist
While Craigslist has a mixed reputation -- users need to use caution and common sense when interacting with total strangers -- it is also a great source of free stuff. As the phenomenon known as freecycling becomes increasingly popular, Craigslist can be a great resource for finding these offers. Freecycling is based on the idea that many people have used items that have remaining useful life but they are replacing those items anyway. Rather than throwing these items away, the owners offer them to the general public for free.
2. FreeStuff.com
FreeStuff.com gives you access to free samples of common household items ranging from coffee to moisturizer. You can use this site to save money on many items you use or to try out new brands for free.
3. Yerdle
Yerdle describes itself as the "people-powered store."  The idea of the site is that the more stuff you give away, the more credits you earn with which to buy other things you might want on Yerdle without having to use cash. While this might seem like it takes more effort than throwing things out, you can get something instead of nothing for items you were going to put in the trash. Using a service like this could be a good option for items that you feel are too valuable to simply give away or throw away but that you're not having success selling.
4. FreeSamples.org
FreeSamples.org is a portal that gives you access to a variety of free product offers for things like household products as well as coupons for products and local restaurants. The offers are updated every day.
5. The Freecycle Network
The Freecycle Network is made up of nearly nine million members worldwide. It is dedicated to enabling members to get and give stuff for free in order to put goods to their most efficient use -- and keep usable items out of landfills. This nonprofit describes itself as a "grassroots movement," and local volunteer moderators help handle network activity to keep exchanges safe and posts accurate. Membership is free.
6. Woman Freebies
Offering people the chance to try before they buy, Woman Freebies supplies free samples, coupons and giveaways of products geared toward women, from candles and shoes to vacations. This site is a good place to look for fun stuff you need or even a cheap gift for your mom, sister, wife or girlfriend.
7. Drugs.com
Drugs.com is an online resource that offers a drug discount program. The free membership card can save you as much as 80% at major pharmacies, according to the website.
8. The ReUseIt Network
The ReUseIt Network serves as a portal to give you access and information on hundreds of freecycling groups worldwide. The site focuses on directing you to freecycling groups and resources in your local area.
9. Free Stuff Finder
Free Stuff Finder shares deals, giveaways and discounts offered both online and at popular retailers. The site shows you both the original price of an item and the price after coupons and discounts to break down your savings for you.
10. Target
Target has a free sample portal that allows you to try products for free. Furthermore, by signing for the store's Red Card, you can save 5 percent on every purchase. Know what you're signing up for before committing. Loyalty cards can come with perks but also typically track your purchases, which some consumer advocacy groups consider an invasion of privacy.
11. SweetFreeStuff.com
SweetFreeStuff.com offers an e-newsletter that includes regular access to great deals online and free samples. The website also lists giveaways and sweepstakes you can sign up for online.
12. Cardpool
Cardpoolis an online marketplace that allows you to purchase gift cards at a discount to use at your favorite stores. While the discount levels vary, there are some attractive deals to be found. You also can sell your gift cards for cash.
13. All You
Lifestyle website All You lists 59 birthday freebies. The site also provides coupons for groceries and household items as well as other exclusive deals.
14. The Penny Hoarder
In addition to listing 100 places that have free birthday offers, the Penny Hoarder offers advice on saving and earning money in unconventional ways.
15. HeyItsFree.com
Another site with a long list of birthday freebies, Hey It's Free also is a good source for free offers throughout the year. Find coupons for everything from free food and moisturizer to free comic books and codes for free rewards points.
16. Freaky Freddie's
In addition to deals on products for grown-ups, Freaky Freddie's has long list of free kids' stuff. Check out offers for books, T-shirts, coloring books and activities like roller skating.
17. Totally Free Stuff
Totally Free Stuff< offers dozens of categories of free stuff as well as daily updates. Search for things in categories for type of person or interest -- such as men, women, business, religious, wedding -- or by product type, such as kitchen, pet products, toys, sports and automotive.
18. I Love Free Things
I Love Free Things is another site with a diverse collection of free stuff for kids, from books to deals on fun activities like bowling. The site has dozens of other categories of free stuff for all ages as well.
19. Freeflys.com
Freeflys.com provides lists of free samples, coupons and coupon codes. You can search the site or look for items sorted by category or brand name.
20. Raise
Raise is an online marketplace that allows you to buy gift cards for products and services from over 1000 stores and restaurants at a discount. The site also gives you the option of selling unwanted or unused gift cards for cash.
21. Recycle the World
Recycle the World is another freecycling website that allows you to post and find free stuff. Whether you are looking to get rid of unwanted items or are looking for something specific, the site lets you target your local area. It also provides a search tool to help you find recycling centers near you.
22. Coupons.com
Couponing has grown from a trend into a lifestyle for many people, and the number of websites dedicated to providing access to coupons has exploded in recent years. As a leader in the industry showcasing more than 2,000 brands, Coupons.com offers multiple ways to get coupons online. You can use the site to print coupons, find coupon codes and find discounts to specific retailers that you can add to your credit or debit card.
23. SmartSource.com
Another great source of free coupons, SmartSource.com can help you save money on everything from beauty products and groceries to weight loss products and sanding sheets for your DIY projects.
24. The Krazy Coupon Lady
Extreme couponing website The Krazy Coupon Lady< is a great source for coupons from some of your favorite retailers, from discount stores like Walmart and Dollar Tree to high-end brands like Sephora. The site also features deals for stores like Home Depot as well as online retailers such as Amazon.
25. Freebie-Depot
Freebie-Depot has "hot lists" for everything from everyday offers to birthday giveaways across a range of products and services from various brands and retailers. Among its many categories, the site features a wedding freebies section with deals for people who are getting married or are recently married.
26. Lifehacker
While Lifehacker is known for unconventional solutions to everyday problems, the website often publishes articles on how and where to save money, such as a feature on the best retail and restaurant birthday freebies.
27. Freebies.org
In addition to providing access to a variety of offers, Freebies.org offers tips and tricks on how to save money as well as its Complete Guide to Freebie Hunting.
28. I Crave Freebies
Similar to other online sources of free samples, I Crave Freebies offers links to coupons for discounts and free product samples. It also provides links to sites that pay you to take surveys.
29. GetItFree
Updated daily, GetItFree finds free offers for everything from food to household products. As you browse the site, you can add coupons, deals, freebies and sweepstakes offers to your basket just like you would when shopping online.
30. Freebies.com
Freebies.com started as a print magazine more than 30 years ago. As a digital resource, it continues to provide a blend of both products and services that are offered at no charge from major national retailers.
31. Shop4Freebies
Shop4Freebies catalogs offers for everything from free home care product samples and bargains to free cookbooks. Its list of printable coupons and other offers is updated daily.
Hundreds of sites offer consumers great ways to save. This list narrows down the options so that you can more easily find providers of freebies and deals that suit your needs. By checking out the features of these different sites, you can find the online resources that work best for you, whether you want birthday freebies, discounted items, coupon codes or free stuff year-round.
This article originally appeared on GOBankingRates.com: 31 Best Websites for Free Stuff