Question: Is there a function or something in laravel which I can use to make first letter uppercase in breadcrumbs? 

This is what I'm using right now but in my links and routes are all lowercase letters and if I go and try to update all will be very time consuming..

```
<ul class="breadcrumb">
<li>
     <i class="glyphicon glyphicon-home"></i>
     <a href="{{ URL::to('/') }}">Home</a> /
     @for($i = 0; $i <= count(Request::segments()); $i++)
         <a href="">{{Request::segment($i)}}</a>
         @if($i < count(Request::segments()) & $i > 0)
              /
         @endif
</li>
     @endfor
</ul>

```

Or this isn't correct way of making breadcrumbs in laravel 4.2?

Answer: 
If you mean only JavaScript and HTML on the client, there are some third party libraries.

Auth0 is popular and has [instructions for Twitter](https://auth0.com/docs/connections/social/twitter).

Another possible solution is to use Firebase auth. It has a [JavaScript API which can be used as follows](https://firebase.google.com/docs/auth/web/twitter-login#redirect-mode):

> 
> Create an instance of the Twitter provider object:
> 
> 
> 

```
var provider = new firebase.auth.TwitterAuthProvider();

```

> 
> Authenticate with Firebase using the Twitter provider object. You can prompt your users to sign in with their Twitter accounts either by opening a pop-up window or by redirecting to the sign-in page.
> 
> 
>
If you check the twitter's api documentation, you can see how to do the login.

I think your question is how insert a plugin to login similar than facebook but I think they don't did any library.

When the user clicks the loggin button you must send a post request to twitter to get the oauth\_token:
Example: POST request to "api.twitter.com/oauth/request\_token"

and then, twitter provides you the oauth\_token and the oauth\_token\_secret (private).

Once you did this step you must to redirect the user to twitter.
Example: GET request to "api.twitter.com/oauth/authenticate?oauth\_token=YOUR\_OAUTH\_TOKEN\_GIVEN\_IN\_STEP\_1"

If everything has gone well twitter response you with the oauth\_token and a verifier oauth token.

Let's set up the last step!

Send a post request to twitter api endpoint with the verifier oauth token provided in the response of step 2.
Example: POST request to "api.twitter.com/oauth/access\_token" sending the verifier oauth token as post parameter.

And then twitter response with a secret token and the user token, you can save it and feel free to use it in any twitter endpoint.

Login documentation: <https://dev.twitter.com/web/sign-in/implementing>
Browser auth flow: <https://dev.twitter.com/web/sign-in/desktop-browser>

Regards!