Anyone who experience this issue with anchor tags at laravel , I encounter an issue which href shows correct url href="job
but the properties value shows = jobs/jobs
. I don’t have any issue with this anchor tags when I’m in different routes.
I used this route
<code>Route::get('/jobs/{id}', function ($id) {
$job = Job::find($id);
return view('job',['job'=>$job]);
});
</code>
<code>Route::get('/jobs/{id}', function ($id) {
$job = Job::find($id);
return view('job',['job'=>$job]);
});
</code>
Route::get('/jobs/{id}', function ($id) {
$job = Job::find($id);
return view('job',['job'=>$job]);
});
enter image description here
enter image description here
I try to look for any similar issue here but I found nothing. the anchor tag is reusable , I did used a static anchor tag but both shows values /jobs/jobs but the href is /jobs only
@props([‘active’ => false])
<code><a class="{{ $active ? 'bg-gray-900 text-white' : 'text-gray-300 hover:bg-gray-700 hover:text-white' }} rounded-md px-3 py-2 text-sm font-medium"
aria-current="{{ $active ? 'page' : 'false' }}"
{{ $attributes }}
>{{$slot}} </a>
</code>
<code><a class="{{ $active ? 'bg-gray-900 text-white' : 'text-gray-300 hover:bg-gray-700 hover:text-white' }} rounded-md px-3 py-2 text-sm font-medium"
aria-current="{{ $active ? 'page' : 'false' }}"
{{ $attributes }}
>{{$slot}} </a>
</code>
<a class="{{ $active ? 'bg-gray-900 text-white' : 'text-gray-300 hover:bg-gray-700 hover:text-white' }} rounded-md px-3 py-2 text-sm font-medium"
aria-current="{{ $active ? 'page' : 'false' }}"
{{ $attributes }}
>{{$slot}} </a>