Data not showing in the browser view but showing in dev tools

Viewed 23

I was working on an older version of code and everything was working fine then my team gave me the new code and after shifting to the new code I am facing some errors. My goal is to display rating stars for the user in the older version of code it was working fine but in my latest version of code, the stars are not displaying on the screen all of the data I want is coming but the stars are not saying but when I go to chrome dev tools and try to inspect element where all the stars are showing concerning the user.

// This is my view file

                    @php

                    //$rate_num = number_format($ratings_value);
                    $rate_num = $ratings_value;

                    //dd($ratings_value);
                    // $isfloat = $rate_num == $ratings_value && ($ratings_value % 1 !== 0) ;
                @endphp
                    @php

                        $emptyStarsCount=5;

                    @endphp

                        @if ($Isfloat==1)
                        
                        @php

                        $emptyStarsCount=4;

                        @endphp

                        @endif

                        @for ($i=0 ; $i<$rate_num ; $i++)

                        <i class="fa fa-star checked"></i>
                        
                        @endfor

                        @if($Isfloat==1)
                        <i class="fa fa-star-half-o checked"></i>
                        @endif
                        

                        @for ($j=$rate_num+1 ; $j<=$emptyStarsCount ; $j++)

                        <i class="fa fa-star"></i>
                        
                        @endfor
                        
                        <span>

                        @if ($pmc_user_rating->count() > 0)

                        Voters Numbers:({{$pmc_user_rating->count()}})


                        @else

                        No Ratings

                        @endif
                        
                        </span>

                    </div>

Can anybody tell me what is the mistake I am making Thank you.

0 Answers
Related