<commit_before><?php
use \Concrete\Package\VividStore\Src\VividStore\Utilities\Price as Price;
defined('C5_EXECUTE') or die(_("Access Denied.")); ?>
<?php if($controller->getTask() == "view" || $controller->getTask() == "failed"){?>

<div class="clearfix">

    <div class="checkout-form-shell">
        <h1><?=t("Checkout")?></h1>

        <?php
            if ($customer->isGuest() && ($requiresLogin || $guestCheckout == 'off' || ($guestCheckout == 'option' && $_GET['guest'] != '1'))){
        ?>
        <div class="checkout-form-group" id="checkout-form-group-signin">

            <?php 
                if ($guestCheckout == 'option' && !$requiresLogin) { 
                    $introTitle = t("Sign in, Register or Checkout as Guest");
                } else { 
                    $introTitle = t("Sign in or Register");
                } 
            ?>
            
            <h2><?=$introTitle?></h2>
            <div class="checkout-form-group-body col-container clearfix">
                
                <div class="vivid-store-col-2">
                    <p><?=t("In order to proceed, you'll need to either register, or sign in with your existing account.")?></p>
                    <a class="btn btn-default" href="<?=View::url('/login')?>"><?=t("Sign In")?></a>
                    <a class="btn btn-default" href="<?=View::url('/register')?>"><?=t("Register")?></a>    
                </div>
                <?php if ($guestCheckout == 'option' && !$requiresLogin) { ?>
                <div class="vivid-store-col-2">
                    <p><?=t("Or optionally, you may choose to checkout as a guest.")?></p>
                        <a class="btn btn-default" href="<?=View::url('/checkout/?guest=1')?>"><?=t("Checkout as Guest")?></a>
                    
                </div>
                <?php } ?>
                
            </div>
            
        </div>
        <?php } else {   ?>
        <form class="checkout-form-group" id="checkout-form-group-billing" action="">
            
            <h2><?=t("Billing Address")?></h2>
            <div class="checkout-form-group-body col-container clearfix">
                <div class="clearfix">
                    <div class="vivid-store-col-2">
                        <div class="form-group">
                            <label for="checkout-billing-first-name"><?=t("First Name")?></label>
                            <?php echo $form->text('checkout-billing-first-name',$customer->getValue("billing_first_name")); ?>
                        </div>
                   </div>     
                   <div class="vivid-store-col-2"><commit_msg>remove register button if registration isn't enabled<commit_after><?php
use \Concrete\Package\VividStore\Src\VividStore\Utilities\Price as Price;
defined('C5_EXECUTE') or die(_("Access Denied.")); ?>
<?php if($controller->getTask() == "view" || $controller->getTask() == "failed"){?>

<div class="clearfix">

    <div class="checkout-form-shell">
        <h1><?=t("Checkout")?></h1>

        <?php
            if ($customer->isGuest() && ($requiresLogin || $guestCheckout == 'off' || ($guestCheckout == 'option' && $_GET['guest'] != '1'))){
        ?>
        <div class="checkout-form-group" id="checkout-form-group-signin">

            <?php 
                if ($guestCheckout == 'option' && !$requiresLogin) { 
                    $introTitle = t("Sign in, Register or Checkout as Guest");
                } else { 
                    $introTitle = t("Sign in or Register");
                } 
            ?>
            
            <h2><?=$introTitle?></h2>
            <div class="checkout-form-group-body col-container clearfix">
                
                <div class="vivid-store-col-2">
                    <p><?=t("In order to proceed, you'll need to either register, or sign in with your existing account.")?></p>
                    <a class="btn btn-default" href="<?=View::url('/login')?>"><?=t("Sign In")?></a>
                    <?php if (Config::get('concrete.user.registration.enabled')) { ?>
                    <a class="btn btn-default" href="<?=View::url('/register')?>"><?=t("Register")?></a> 
                    <?php } ?>   
                </div>
                <?php if ($guestCheckout == 'option' && !$requiresLogin) { ?>
                <div class="vivid-store-col-2">
                    <p><?=t("Or optionally, you may choose to checkout as a guest.")?></p>
                    <a class="btn btn-default" href="<?=View::url('/checkout/?guest=1')?>"><?=t("Checkout as Guest")?></a>
                </div>
                <?php } ?>
                
            </div>
            
        </div>
        <?php } else {   ?>
        <form class="checkout-form-group" id="checkout-form-group-billing" action="">
            
            <h2><?=t("Billing Address")?></h2>
            <div class="checkout-form-group-body col-container clearfix">
                <div class="clearfix">
                    <div class="vivid-store-col-2">
                        <div class="form-group">
                            <label for="checkout-billing-first-name"><?=t("First Name")?></label>
                            <?php echo $form->text('checkout-billing-first-name',$customer->getValue("billing_first_name")); ?>
                        </div>
                   </div>     
                   <div class="vivid-store-col-2">
{'fraction_non_alphanumeric': 0.1882527329998147, 'fraction_numerical': 0.004817491198814156, 'mean_word_length': 1.7084796788760663, 'pattern_counts': {'":': 0, '<': 117, '<?xml version=': 0, '>': 127, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '782365', 'n_tokens_mistral': 1602, 'n_tokens_neox': 1535, 'n_words': 287}