So I’ve got the site up and running: https://qa.rechord.xyz/
It might or might not load the first time. For me and others, it doesn’t seem it load the first time they hit the link, but after they refresh it.
Another thing I’ve noticed is that every first load, I get this:
After I refresh it, it loads.
I have no idea why. Its also first time it happen. What could be the issue for this?
This is what the page.blade.php looks like, could this be the issue?
@extends('layouts.app')
@section('content')
{{--
$flexibleContentPath = dirname(__FILE__) . '\\blocks\\';
{{-- $flexibleContentPath = " /var/www/html" --}}
<?php
$flexibleContentPath = "xxx/wp-content/themes/RechordTheme/resources/views/blocks/";
//$flexibleContentPath = "C:\\Users\\44775\\Desktop\\WebDevelopment\\Clients\\Level5\\rechord\\wp-content\\themes\\RechordTheme\\resources\\views\\blocks\\";
$count = 0;
?>
@if ( have_rows( 'flexible_content' ) )
@while ( have_rows( 'flexible_content' ) ) <?php the_row(); ?>
{{-- for ($index = 0; $index <= $flexibleContentLength - 1; $index++) { --}}
{{-- need to build a custom loop --}}
<x-section container="{{ $page[$count]['container'] }}" reverseColumnOnMobile="{{ $page[$count]['reverseColumnOnMobile'] }}" paddingTop="{{$page[$count]['paddingTop']}}" paddingBottom="{{$page[$count]['paddingBottom']}}" sectionImage="{{ $page[$count]['sectionImage'] }}" bgColor="{{ $page[$count]['backgroundColor'] }}">
@if ( have_rows( 'row' ) )
@while ( have_rows( 'row' ) ) <?php the_row(); ?>
@if ( have_rows( 'column' ) )
@while ( have_rows( 'column' ) ) <?php the_row(); ?>
<div class="w-full lg:{{ $page[$count]['columnWidth'] }}">
<?php
$layout = get_row_layout();
$layoutConverted = str_replace( '_', '-', $layout);
$file = ( $flexibleContentPath . str_replace( '_', '-', $layout) . '.blade.php' );
?>
@if( file_exists( $file ))
<?php include($file) ?>
{{-- @include('blocks.' . $layoutConverted) --}}
{{-- @include('blocks.', $layoutConverted) --}}
@else
<?php echo "No file exists" ?>
@endif
</div>
@endwhile
@endif
@endwhile
@endif
</x-section>
<?php $count++ ?>
@endwhile
@endif
@endsection