How Composer works in Laravel 5

I hope you have a basic idea about Namespace, Trait and JSON. Now we will again look into the ‘autoload.namespaces.php’ file in our ‘Composer’ folder. Suppose you want to work with time. One of the best packages is ‘Carbon’. It has got required libraries you need to work with so it will be easy to use it. In your ‘autoload.namespaces.php’ file you will find a line like this:
'Carbon' => array($vendorDir . '/nesbot/carbon/src')

Continue reading “How Composer works in Laravel 5”

What is Composer?

Composer is a tool. As a PHP developer you need to depend on many project’s application logic. You need to use their classes and sometimes you need to use them directly into your code repositories. Composer will allow you to declare those libraries on which your project may depend upon. Not only that, it also makes your life comfortable with all those updates and additions that often take place into the world of open source world. Composer will automatically install and update those libraries for your project.

Continue reading “What is Composer?”

Installing and running OpenOffice4.1.0 in Kali Linux

In fact this steps can be followed for any Debian package.
It’s a few simple lines on Debian/Ubuntu distros Download the file Use Archive Manager to open it and extract it to a folder.
Open a terminal cd to the folder.
when in the folder cd DEBS to change into the DEBS folder.
In Kali, Type ‘su’ and by typing root password you become ‘root’. In other package like Ubuntu, type:
sudo dpkg -i *.deb
cd desktop-integration
sudo dpkg -i *.deb (once again!)

Now you should see your OpenOffice in Usual Application – Office section of your kali Linux.

Function generator in Python

Normally when we use for loop and range() method in Python it stops at just before the range we mentioned.

It looks like :

for i in range(10):
print(i)

And it reads from 0 to 9 and stops.
Basically through the range() method of Python, we pass three variables – start, stop and step. In between these three variables, by default the values of ‘start’ and ‘stop’ are pre-set. ‘start’ is 0 and ‘stop’ is 1. So it starts from 0 and each step it iterates 1 step and stops at 9. In it the ‘stop’ value remains inconclusive.
But we can make the ‘stop’ value conclusive by the following method:
Continue reading “Function generator in Python”