{* DO NOT EDIT THIS FILE! Use an override template instead. *}
{*?template charset=latin1?*}

<form enctype="multipart/form-data" method="post" action="{$script}">

  <div align="center">
    <h1>{"Site package"|i18n("design/standard/setup/init")}</h1>
  </div>

{if $message}
    <blockquote class="message">

    <p>{$message|wash}</p>

    </blockquote>
{else}
  <p>
    {"Please choose a site package you would like to test or base your site on."|i18n("design/standard/setup/init")}
  </p>
{/if}
{section show=$error}
<div class="error">

 <blockquote class="error">
   <h2>{"Error"|i18n("design/standard/setup/init")}</h2>
   <p>{$error|wash}</p>
   <p>Remote repository URL: <a href={$index_url}>{$index_url|wash}</a></p>
 </blockquote>

</div>
{/section}

<table class="sitepackages" cellspacing="0">
{if is_set( $site_packages )}
    {foreach $site_packages as $package_info}
    {if and( is_set( $message ), $message )}
       {if not( and( $chosen_package, eq( $package_info.name, $chosen_package ) ))}
         {continue}
       {/if}
    {/if}
    <tr>
    <td>
     {if is_set( $package_info.url )}
      <input{if and( is_set( $message ), $message )} class="hide"{/if} id="{$package_info.name|wash}" type="radio" name="eZSetup_site_type" value="{$package_info.name}|{$package_info.url}" {if or( eq($package_info.name,$chosen_package), $site_packages|count|eq( 1 ) )} checked="checked"{/if}/>
     {else}
      <input{if and( is_set( $message ), $message )} class="hide"{/if} id="{$package_info.name|wash}" type="radio" name="eZSetup_site_type" value="{$package_info.name}" {if or( eq($package_info.name,$chosen_package), $site_packages|count|eq( 1 ) )} checked="checked"{/if}/>
     {/if}
     </td>
    <td>
    {if is_set( $package_info.thumbnail_path )}
          <img class="site-type" src={$package_info.thumbnail_path|ezroot} alt="{$package_info.name|wash}" title="{$package_info.summary|wash}" />
    {elseif is_set( $package_info.thumbnail_url )}
          <img class="site-type" src="{$package_info.thumbnail_url}" alt="{$package_info.summary|wash}" title="{$package_info.summary|wash}"/>
    {else}
      <img class="site-type" src={"design/standard/images/setup/eZ_setup_template_default.png"|ezroot} alt="{$package_info.name|wash}" title="{$package_info.summary|wash}"  />
        {/if}
    </td>
    <td>
        <h2>{$package_info.summary} (ver. {$package_info.version})</h2>
    {$package_info.description}
    </td>

    <td class="importstatus">
    {if $package_info.status}
        <em class="imported">{'Imported'|i18n('design/standard/setup/init')}</em>
    {else}
        <em class="notimported">{'Not imported'|i18n('design/standard/setup/init')}</em>
    {/if}
    </td>
    </tr>

    <tr>
     <td></td>
     <td></td>
     <td>
     <h3>Dependencies</h3>
     </td>
     <td></td>
    </tr>
    {if is_set( $package_info.requires )}
        {foreach $package_info.requires as $req_name => $req_info}
        <tr>
        <td></td>
        <td></td>
        <td>
        {$req_name} (ver.{$req_info.version}):
        </td>
        <td>
        {if $req_info.status}
            <em class="imported">{'Imported'|i18n('design/standard/setup/init')}</em>
        {else}
            <em class="notimported">{'Not imported'|i18n('design/standard/setup/init')}</em>
        {/if}
        </td>
        </tr>
        {/foreach}
    {else}
    <tr>
     <td></td>
     <td></td>
     <td>
        {if not( $package_info.status )}
            {'Unknown'|i18n('design/standard/setup/init')}.
        {else}
            {'No dependencies'|i18n('design/standard/setup/init')}.
        {/if}
     </td>
     <td></td>
    </tr>
    {/if}

    {/foreach}
{else} {* !$remote_site_packages *}
<tr><td colspan="4">None.</td></tr>
{/if}
</table>

{if not($message)}
<fieldset>
  <legend>{'Upload package'|i18n( 'design/standard/setup/init' )}:</legend>
  <input class="file" name="PackageBinaryFile" type="file" />
  <input type="submit" name="UploadPackageButton" value="{'Upload'|i18n("design/standard/setup/init")}" />
</fieldset>
{/if}

  {include uri="design:setup/persistence.tpl"}

  {include uri='design:setup/init/navigation.tpl'}

</form>

