daniel21gt

daniel21gt

Member Since 9 Months Ago

Experience Points 4,230
Experience Level 1

770 experience to go until the next level!

In case you were wondering, you earn Laracasts experience when you:

  • Complete a lesson — 100pts
  • Create a forum thread — 50pts
  • Reply to a thread — 10pts
  • Leave a reply that is liked — 50pts
  • Receive a "Best Reply" award — 500pts
Lessons Completed 0
Lessons
Completed
Best Reply Awards 0
Best Reply
Awards
  • Start Your Engines Achievement

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • First Thousand Achievement

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • One Year Member Achievement

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • Two Year Member Achievement

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • Three Year Member Achievement

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • Four Year Member Achievement

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • Five Year Member Achievement

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • School In Session Achievement

    School In Session

    Earned when at least one Laracasts series has been fully completed.

  • Welcome To The Community Achievement

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • Full Time Learner Achievement

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • Pay It Forward Achievement

    Pay It Forward

    Earned once you receive your first "Best Reply" award on the Laracasts forum.

  • Subscriber Achievement

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • Lifer Achievement

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • Laracasts Evangelist Achievement

    Laracasts Evangelist

    Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.

  • Chatty Cathy Achievement

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • Laracasts Veteran Achievement

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • Ten Thousand Strong Achievement

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • Laracasts Master Achievement

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • Laracasts Tutor Achievement

    Laracasts Tutor

    Earned once your "Best Reply" award count is 100 or more.

  • Laracasts Sensei Achievement

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • Top 50 Achievement

    Top 50

    Earned once your experience points ranks in the top 50 of all Laracasts users.

25 Jun
21 hours ago

daniel21gt started a new conversation Problems With Translation Eloquent, Laravel 5.5

What's up friends.

I have tried to transcribe this query to eloquen, but it has been difficult for me to do it, does anyone know how I can fix it?

select usuario_ad, nombre from usuarios where usuario_ad in (select username from users where users.refer="angelicaad" union select "angelicaad" );

18 Jun
1 week ago

daniel21gt started a new conversation Problem Order Select, Laravel 5.5

How I have the following code

public function create(Request $request) { $registrado = \Auth::user()->tipos_usuarios_id;

      if($registrado == 1)
      {
         $request->user()->authorizeRoles(['admin']);
         $governor = \DB::table('governor')->select('idg', 'governor_candidate')->get();
         $mayor = \DB::table('mayor')->select('idm', 'mayor_candidate')->get();
         $advice = \DB::table('advice')->select('ida', 'advice_candidate')->orderBy('advice_candidate','asc')->get();
         $assembly = \DB::table('assembly')->select('idas', 'assembly_candidate')->get();
         return view('Usuario.create')->with(['governor' => $governor, 'mayor' => $mayor, 'advice' => $advice, 'assembly' => $assembly]);
      }

}

This brings me these values, about the consultation advice

Anderson carlos jhon Jorge Otro Robert

What can I do to make the word Otro, last and not penultimate

02 Jun
3 weeks ago

daniel21gt left a reply on Problem With Nginx Configuration, Laravel 5.5

When I charge the server ip, it shows me the nginx index instead of the laravel page, will this be the problem?

daniel21gt left a reply on Problem With Nginx Configuration, Laravel 5.5

Thank you very much, you are right, you must open with / login, but even so the nginx says it can not find the page.

daniel21gt started a new conversation Problem With Nginx Configuration, Laravel 5.5

How about, I'm setting laravel on a centos server, I have finished but nginx does not load the project, I have this configuration.

server { listen 80; server_name (nombre_dominio.com); root /var/www/html/testsite/public; index index.php; charset utf-8; gzip on; gzip_types text/css application/javascript text/javascript application/x-javascript image/svg+xml text/plain text/xsd text/xsl text/xml image/x-icon; location / { try_files $uri $uri/ /index.php?$query_string; } location ~ .php { include fastcgi.conf; fastcgi_split_path_info ^(.+.php)(/.+)$; fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; } location ~ /.ht { deny all; } }

which believes in

nano /etc/nginx/conf.d/testsite.conf

But I get this error, open url http://192.168.0.107/votaciones/public/login

The page you are looking for is not found.

and in the logs.

2019/06/03 00:30:58 [error] 4217#0: *3 open() "/usr/share/nginx/html/votaciones/public/login" failed (2: No such file or directory), client: 192.168.0.122, server: _, request: "GET /votaciones/public/login HTTP/1.1", host: "192.168.0.107

I do not understand what I may be missing

my route

Route::get('/', function () { return view('auth/login'); });

Route::get('/panel', '[email protected]'); Route::post('/panel/filtusuario', '[email protected]')->name('usuario.filtusuario'); Route::post('/panel/gestion', '[email protected]')->name('usuario.ugestion'); Route::get('/panel/bestado', '[email protected]')->name('usuario.bestado'); Route::get('/panel/selectord', '[email protected]')->name('usuario.selectord'); Route::get('/panel/revisar', '[email protected]')->name('cuenta.revisar'); Route::post('/panel/estado', '[email protected]')->name('cuenta.cestado'); Route::post('/panel/asignar', '[email protected]')->name('cuenta.asignar'); Route::get('/panel/tareas', '[email protected]')->name('cuenta.tareas'); Route::get('/panel/inactivo', '[email protected]')->name('cuenta.inactivo'); Route::get('/panel/reportes', '[email protected]')->name('cuenta.reportes'); Route::get('/panel/governor', '[email protected]')->name('usuario.governor'); Route::get('/panel/mayor', '[email protected]')->name('usuario.mayor'); Route::get('/panel/advice', '[email protected]')->name('usuario.advice'); Route::get('/panel/assembly', '[email protected]')->name('usuario.assembly'); Route::get('panel/descarga', '[email protected]')->name('products.excel'); Route::get('panel/excelestados', '[email protected]')->name('products.excelestados'); Route::get('panel/excelestadostres', '[email protected]')->name('products.excelestadostres'); Route::get('panel/excelestadoscuatro', '[email protected]')->name('products.excelestadoscuatro'); Route::resource('/panel/ecuentas', 'CuentaController')->except(['show']); Route::resource('/panel/registros', 'RegistrosController'); Route::get('/panel/fecha', '[email protected]')->name('usuario.fecha'); Route::get('/panel/selector', '[email protected]')->name('usuario.selector'); Route::post('/panel/cedula', '[email protected]')->name('usuario.cedula'); Route::get('panel/excelgobernadores', '[email protected]')->name('products.excelgobernadores'); Route::get('panel/excelalcaldes', '[email protected]')->name('products.excelalcaldes'); Route::get('panel/excelconsejales', '[email protected]')->name('products.excelconsejales'); Route::get('panel/excelasamblea', '[email protected]')->name('products.excelasamblea'); Route::resource('/panel/usuario', 'UsuarioController')->except(['show']); Auth::routes();

31 May
3 weeks ago

daniel21gt started a new conversation Server Installation For Laravel 5.5 Project

How are you.

My concern is that I have a project in laravel, which will be used in the company where I work, and my intention is to install my project already finished in larvel, on a linux server, someone knows or knows about some documentation, about how I can prepare a linux to work for laravel page?

19 May
1 month ago

daniel21gt left a reply on Problems With Excel Function. Larvel 5.5

because if I did so $ request-> governore, it brings me a NULL value, so I had to bring the values, separating them from the url, so it works well, the thing is that, I do not know why it works if they download well with the filters that you consult, but in mozilla and google chrome no.

18 May
1 month ago

daniel21gt left a reply on Problems With Excel Function. Larvel 5.5

Maybe my configuration of htacces will have to see?

Options +FollowSymLinks RewriteEngine On

RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^ index.php [L]

daniel21gt started a new conversation Problems With Excel Function. Larvel 5.5

How about, I have an excel function, which when sending any filter like for example, result1 or result2, this generates an excel with one of those two variables, this works very well in browser opera, but does not work in google chrome or mozilla , since these two are left with the first excel that I download, that is, if I filter with another variable, it still downloads the first excel that it downloads, does anyone know what this is?

public function excelgobernadores(Request $request) {

   $registrado = \Auth::user()->tipos_usuarios_id;
   $filtros = \Auth::user()->username;
   

   if($registrado == 1)

    {

      $request->user()->authorizeRoles(['admin']);

    
        $urlgover = request()->headers->get('referer');
         parse_str(parse_url($urlgover)['query'], $output);
          $valorgober = $output['governore'];


        Excel::create('ExcelGobernadores', function($excelgobernadores) use ($valorgober){
            $excelgobernadores->sheet('Excelsheet', function($sheet) use ($valorgober){
    
              $conteogobe = usuarios::join('governor', 'usuarios.gobe_id', '=' , 'governor.idg')->where('gobe_id',$valorgober)->where('asignacion', '<>', '')->select('user_id', 'user_id', 'usuario_ad', 'nombre', 'apellido', 'cedula', 'telefonos', 'direccion', 'barrio', 'lugar_votacion', 'mesa_votacion', 'email', 'ciudad', 'comentario', 'asignacion', 'estado', 'governor.governor_candidate')->get();
              $conteogobe = json_decode( json_encode($conteogobe), true);
              $sheet->fromArray($conteogobe);
              $sheet->setOrientation('landscape');

           });

        })->export('xls');
    
   }

daniel21gt left a reply on Problems With Excel Hosting Reports. Laravel 5.5

It is as if the browser cache is pasted in the first excel report, and will stay there without generating something different.

daniel21gt started a new conversation Problems With Excel Hosting Reports. Laravel 5.5

How about, I have scheduled these reports that work very well locally,

this is, in that when I do a query for a different filter, I click on the button to download excel report, and this download what I have consulted without problems, but now that I upload everything to a hosting, it does not work anymore, because if I consult with different filters, whenever I download the excel I get the first result that I consult and not the following ones that I consult.

the strangest thing is that it only happens with google chrome, and not in other browsers, why did this happen?

       <td style="width:20%;" border="0"> 
        
         @if(Auth::user()->hasRole('admin'))  
          <table style="width:100%;" border="0" >
             <tr><td style="width:50%;" border="0">           
                  <a href="{{ route('products.excelgobernadores') }}" class="btn btn-sm btn-primary">
                     Descargar reporte en Excel
                  </a>
             <td style="width:25%;" border="0"> 
        </table>
        @endif
        @if(Auth::user()->hasRole('gestion'))  
          <table style="width:100%;" border="0" >
             <tr><td style="width:50%;" border="0">           
                  <a href="{{ route('products.excelgobernadores') }}" class="btn btn-sm btn-primary">
                     Descargar reporte en Excel
                  </a>
             <td style="width:25%;" border="0"> 
        </table>
        @endif

Metod

if($registrado == 1)

    {

      $request->user()->authorizeRoles(['admin']);


        $urlgover = request()->headers->get('referer');
         parse_str(parse_url($urlgover)['query'], $output);
          $valorgober = $output['governore'];


        Excel::create('ExcelGobernadores', function($excelgobernadores) use ($valorgober){
            $excelgobernadores->sheet('Excelsheet', function($sheet) use ($valorgober){
    
              $conteogobe = usuarios::join('governor', 'usuarios.gobe_id', '=' , 'governor.idg')->where('gobe_id',$valorgober)->where('asignacion', '<>', '')->select('user_id', 'user_id', 'usuario_ad', 'nombre', 'apellido', 'cedula', 'telefonos', 'direccion', 'barrio', 'lugar_votacion', 'mesa_votacion', 'email', 'ciudad', 'comentario', 'asignacion', 'estado', 'governor.governor_candidate')->get();
              $conteogobe = json_decode( json_encode($conteogobe), true);
              $sheet->fromArray($conteogobe);
              $sheet->setOrientation('landscape');

           });

        })->export('xls');
    
   }
09 May
1 month ago

daniel21gt left a reply on Problem When Running Seeders Laravel 5.5

I've applied it, but I'm still the same.

daniel21gt started a new conversation Problem When Running Seeders Laravel 5.5

I am currently migrating my project to a real hosting, so far everything is fine, the migrations were executed without problems, but at the time of executing the seeder I see this error.

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'winnersc_asambles2019.Mayor' doesn't exist (SQL: insert into Mayor (mayor_candidate, updated_at, created_at) values (AlcaldeUno, 2019-05-10 01:27:21, 2019-0 5-10 01:27:21))

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'winnersc_asambles2019.Mayor' doesn't exist

I do not understand why, the table does exist, the migrations were correct, when I run them on my local server it goes without problems but in the hosting, no one knows why this?

08 May
1 month ago

daniel21gt started a new conversation Problems When Applying Migrations In Hosting With Laravel 5.5

I get this error, when trying to apply a migration, in a hosting.

in connection.php driver (SQL: select * from information_schema.tables where table_schema = winnersc_bdd and table_name=migrations)

in connector.php line 67: could not find driver.

It's the first time that I have put my project on a real hosting, and I do not know what I should do to fix that problem.

daniel21gt started a new conversation Doubt With Installation Of Project In Hosting

My question is the following, if I contract a hosting that supports laravel, this should already have the composer already installed, or should it be installed?

How can I realize that my hosting service really supports laravel 5.5 from linux console by ssh connection?

17 Mar
3 months ago

daniel21gt started a new conversation Problem With Infinite Select, In Laravel 5.5

How about, I have tried to make an infinite select with scroll, since currently the select that I have loads indefinitely many records, but in the end it will be uncomfortable to see such a large list, which is why I want a scroll in the select that loads everything what's in that field of the bd, this is what I have.

<table style="width:100%;" border="0">
    <tr>
        <td style="width:100%;" border="0">

            <select name="tipo" id="tipo" class=" form-control" value="{{ old('tipo') }}" required style="width:150px">
                @foreach($usuariosOpciones as $user_id => $usuario_ad)
                <option value="{{$user_id}}">{{ $usuario_ad }}</option>
                @endforeach
            </select>
        </td>

        <td style="width:50%;" border="1">
            <button type="submit" class="btn btn-primary">enviar</button>
        </td>
    </tr>
</table>

This is my controller.

public function selector(Request $request)

    {   

        $registrado = \Auth::user()->tipos_usuarios_id;
        $filtro = \Auth::user()->username;
        $filid = \Auth::user()->id;

      if($registrado == 1)

      {
        $request->user()->authorizeRoles(['admin']);
        $usuarios=usuarios::where("user_id", $request->tipo)->paginate(10);
        $usuarios->appends(['tipo'=> $request->tipo]);
        $usuariosOpciones=usuarios::pluck('usuario_ad', 'user_id')->unique();
        $conteo=usuarios::where('user_id', $request->tipo)->count();
        return view('usuario.index')->with(["usuarios" => $usuarios, "usuariosOpciones" => $usuariosOpciones, "conteo" => $conteo]);
       }

}

I know there are several ways to do it with ajax or jquery for example, but I'm new to these languages, I still do not understand the logic to implement it in what I have, and thus achieve a simple scroll select.

07 Mar
3 months ago

daniel21gt started a new conversation Problem With Query Insert Into, Laravel 5.5

I have the following code.

$this->validate($request,['user_id', 'gobe_id'=>'required', 'alcal_id'=>'required', 'conse_id'=>'required', 'asam_id'=>'required', 'nombre'=>'required', 'apellido'=>'required', 'cedula'=>'required|max:11|unique:usuarios', 'telefonos'=>'required','direccion'=>'required', 'barrio'=>'required', 'lugar_votacion'=>'required', 'mesa_votacion'=>'required', 'email'=>'required|unique:usuarios', 'ciudad'=>'required', 'estado']);

              usuarios::create($request->all());

When I enter this ID number 4521511210

I get this error

"SQLSTATE[22003]: Numeric value out of range: 1264 Out of range value for column 'cedula' at row 1 (SQL: insert into usuarios (user_id, usuario_ad, nombre, apellido, telefonos, cedula, barrio, lugar_votacion, mesa_votacion, email, ciudad, direccion, gobe_id, alcal_id, conse_id, asam_id, updated_at, created_at) values (3, danielad, velentina, sarmiento, 5142621, 4521511210, cuba, cuba, 32, [email protected], Dosquebradas, cra 12 45 65, 3, 3, 1, 1, 2019-03-08 02:30:44, 2019-03-08 02:30:44))

05 Mar
3 months ago

daniel21gt left a reply on What Are The Ways To Compare NULL Values? In Laravel 5.5

I understand cronix, I just thought maybe there could be another way, but if you say that's fine, then I can rest assured, thank you for your opinion.

daniel21gt started a new conversation What Are The Ways To Compare NULL Values? In Laravel 5.5

How about, I have the following query comparing a NULL value, I do not think it is the most appropriate way, is there a more technical way to compare a null column?

usuarios::where('asignacion', NULL)->where('cedula', $request->cedula)->update(['asignacion' => $gestionUnicos->last()]);

02 Mar
3 months ago

daniel21gt left a reply on Doubt With Implementation Of Dynamic Select In Laravel 5.5

No, dependent, no, I just need a select but infinite

daniel21gt started a new conversation Doubt With Implementation Of Dynamic Select In Laravel 5.5

Can someone advise me, where can I investigate to create an infinite and dynamic select?

24 Feb
4 months ago

daniel21gt left a reply on Configuring Redirection In Laravel 5.5

Thanks jlrdw, that's a very recursive idea, it will do

daniel21gt left a reply on Configuring Redirection In Laravel 5.5

Is there any file that you can see 419.blade.php, to redirect it to login?

daniel21gt started a new conversation Configuring Redirection In Laravel 5.5

so, today I tried to perform a redirect, I pretend that when the session time expires, I automatically redirected to the login path, and not to this path (\ vendor \ laravel \ framework \ src \ Illuminate \ Foundation \ Exceptions \ views \ 419.blade.php

I have done this in the handler, but it does not work, it keeps getting there.

* @param  \Exception  $exception
 * @return void
 */
public function report(Exception $exception)
{
    parent::report($exception);
}

/**
 * Render an exception into an HTTP response.
 *
 * @param  \Illuminate\Http\Request  $request
 * @param  \Exception  $exception
 * @return \Illuminate\Http\Response
 */
public function render($request, Exception $exception)
{
    
      if($this->isHttpException($exception))
    {
        switch ($exception->getStatusCode()) {
            //access denied
            case 401:
                return response()->view('usuario.error', [], 401);  
            break;
            // not found
            case 404:
                return response()->view('usuario.error', [], 404);
            break;
            // internal error
            case 403:
                return response()->view('usuario.error', [], 403);  
            break;
            // internal error
            case 500:
                return response()->view('usuario.error', [], 500);  
            break;
              // internal error
            case 405:
                return redirect()->route('login');
            break;
            // internal error
            case 419:
                return redirect()->route('login');
            break;

            default:
                return $this->renderHttpException($exception);
            break;
        }
    }
    else
    {
        return parent::render($request, $exception);
    }

}

What can I do to achieve this?

14 Feb
4 months ago

daniel21gt started a new conversation Problem When Selecting Laravel 5.5 Columns

How about, I have the following query, in eloquen.

$conteoconsejales = usuarios::join('advice', 'usuarios.conse_id', '=' , 'advice.ida')->where('conse_id',$valorconse)->where('asignacion', '<>', '')->select('user_id', 'usuario_ad')->get();

The problem is that I have a column from another table, called advice, but I want to include it within the -> select (), but I do not know if this can be done?

01 Feb
4 months ago

daniel21gt left a reply on Problems With Select When Sending Data By POST. Laravel 5.5

I found the error, it was necessary to add the id field in the query.

$governor=governor::select('id','governor_candidate')->orderByRaw("FIELD(id, $gobernadorf) DESC")->get();

daniel21gt started a new conversation Problems With Select When Sending Data By POST. Laravel 5.5

I have the following html code, my problem is that in the end I have 4 select, which work well, I extract correct information.

https://paste.laravel.io/01a2ce91-4dc2-4160-b746-b6af50cd42b9

The problem is when I send this by POST to the update driver, since I have this error.

"SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'gobe_id' cannot be null (SQL: update usuarios set gobe_id = , alcal_id = , conse_id = , `a ▶"

I do not understand why, in actuality, the select ones have records, but when sending them, they do not send anything, why could this happen?

daniel21gt started a new conversation Tittle

test

hello

31 Jan
4 months ago

daniel21gt left a reply on Problems With Query Translation Sql To Eloquent, Laravel 5.5

Thank very muchs jlrdw, this is the solutions

governor::select('governor_candidate') ->orderByRaw("FIELD(id, 3) DESC") ->get();

daniel21gt left a reply on Problems With Query Translation Sql To Eloquent, Laravel 5.5

It is a select, when I return the form I want it to show me the values that are already saved by each user, and not that the same select me for all, now, yes, I must see many tutorials, I still do not have an experience like yours

daniel21gt left a reply on Problems With Query Translation Sql To Eloquent, Laravel 5.5

Yes, but a value appears, I explain, in the table I have 4 records, what I'm looking for is that when I change the id I show that as the first value, and then the others.

daniel21gt left a reply on Problems With Query Translation Sql To Eloquent, Laravel 5.5

I understand, but what can I do, if I need the id field to be able to change a value?

daniel21gt started a new conversation Problems With Query Translation Sql To Eloquent, Laravel 5.5

I try to translate this query

select governor_candidate from governor order by governor.id=3 desc;

not work

governor::orderBy ('id=3', 'DESC');

What I'm I missing of?

daniel21gt started a new conversation Problems When Clearing Cache In Laravel 5.5

How about, I made some changes in a view, but these are not reflected, I applied the following commands

php artisan route:clear php artisan cache:clear php artisan view:clear php artisan config:cache

I have deleted the browser history and I have restarted it, but still I do not apply the changes.

It's the first time this happens to me, is it possible to fix it?

30 Jan
4 months ago

daniel21gt left a reply on How To Leave A Value Already Chosen By A Select, Laravel 5.5

I see, this is why

Candidatos gobernador

Gracias Sergiu17

daniel21gt left a reply on How To Leave A Value Already Chosen By A Select, Laravel 5.5

thanks sergiu17, I have tried your suggestion, but still does not retain the value, missing some detail?

daniel21gt started a new conversation How To Leave A Value Already Chosen By A Select, Laravel 5.5

How about, I have a small problem, currently in a simple input field, I have this variable that helps the chosen value remain there, in case the form does not send anything to validate a required field, old ('address'), It works well.

The problem I have with a select, and if I apply old ('gobe_id'), it does not retain the value, this will be possible to do?

[code]

Candidatos gobernador @foreach($governor as $item) {{$item->governor_candidate}} @endforeach
                                    @if ($errors->has('gobe_id'))
                                         <span class="help-block">
                                        <strong>{{ $errors->first('gobe_id') }}</strong>
                                    </span>
                                  @endif  
                               </div>
                            </div>

[/code]

18 Jan
5 months ago

daniel21gt left a reply on Problem Session Expired In Login. Laravel 5.5

Gracias Snapey, Comprendo lo que dices

daniel21gt started a new conversation Problem Session Expired In Login. Laravel 5.5

How are you.

I have a project, that after starting the session, it expires after 15 minutes of inactivity, it works well. The problem is when I leave the login for more 15 minutes, http: //proyectodos.test/login When I login with username and password it tells me that time expires, so I have to update the page to be able to login.

Is there any way to exclude the expiration time to the main login path?

daniel21gt left a reply on Open Session When Closing Browser, Laravel 5.5

Well, sometimes there are careless people who close the browser and believe that their session too.

daniel21gt started a new conversation Open Session When Closing Browser, Laravel 5.5

How are you

What can I do so that when I close the browser, the session is closed, since it is currently open.

I have changed 'expire_on_close' => false, in true but it is still the same

17 Jan
5 months ago

daniel21gt left a reply on How Can I Get The Last Digit In The Url, Laravel 5.5

Thanks eparcel_fi, as I did it works, but as you do it is much more professional, I have a lot to learn.

daniel21gt left a reply on How Can I Get The Last Digit In The Url, Laravel 5.5

Cronix, so I will always get the last number regardless of the number of digits, again thanks for your help.

$valor = request()->headers->get('referer'); $str = $valor; parse_str($str, $output); dd($output['http://proyectodos_test/panel/selectord?valorusuario'][0]);

16 Jan
5 months ago

daniel21gt left a reply on How Can I Get The Last Digit In The Url, Laravel 5.5

I understand perfectly, thank you very much cronix, as always with the correct answer ..

daniel21gt started a new conversation How Can I Get The Last Digit In The Url, Laravel 5.5

How about, I have the following line

dd(request()->headers->get('referer'));

which shows me this

"http://proyectodos.test/panel/selectord?valorusuario=3"

I have no idea if I am possible, but I want to extract the last digit, the number 3, can I?