Soul Coder
Soul Coder

Reputation: 804

How to escape the double quotes and open brackets in laravel?

enter image description here I tried to get the value from the Bus Stop Table which is the same id by using

{{ \App\Busstop::where('id',$order->bus_stops)->pluck('busstop') }}

But this codes is showing me like the json data or curly brackets.I only want to get plain words witout double quotes and curly brackets.

Upvotes: 1

Views: 923

Answers (1)

Maraboc
Maraboc

Reputation: 11093

You can use implode instead of pluck like so :

{{ \App\Busstop::where('id',$order->bus_stops)->implode('busstop', ', '); }}

Upvotes: 1

Related Questions