1{*
2 * $Revision: 16235 $
3 * Read this before changing templates!  http://codex.gallery2.org/Gallery2:Editing_Templates
4 *}
5<div class="gbBlock">
6  <p class="giDescription">
7    {g->text text="Enter a URL below to a webcam or other live image anywhere on the net."}
8  </p>
9
10  {if empty($form.imageUrl) || !empty($form.error)}
11    <h3> {g->text text="URL"} </h3>
12
13    <input type="text" size="60"
14     name="{g->formVar var="form[imageUrl]"}" value="{$form.imageUrl}"/>
15
16    {if isset($form.error.imageUrl.missing)}
17    <div class="giError">
18      {g->text text="You must enter a URL to an image"}
19    </div>
20    {/if}
21    {if isset($form.error.imageUrl.invalid)}
22    <div class="giError">
23      {g->text text="The URL entered must begin with http:// or file://"}
24    </div>
25    {/if}
26    {if isset($form.error.imageUrl.unavailable)}
27    <div class="giError">
28      {g->text text="The image URL you specified is unavailable"}
29    </div>
30    {/if}
31    {if isset($form.error.imageUrl.notImage)}
32    <div class="giError">
33      {g->text text="The image URL you specified is not an image type"}
34    </div>
35    {/if}
36
37    <input type="submit" class="inputTypeSubmit"
38     name="{g->formVar var="form[action][checkUrl]"}" value="{g->text text="Check URL"}"/>
39
40  {else}
41
42    <strong>
43      {g->text text="URL: %s" arg1=$form.imageUrl}
44      <a href="{g->url arg1="view=core.ItemAdmin" arg2="subView=core.ItemAdd"
45	 arg3="itemId=`$ItemAdmin.item.id`" arg4="addPlugin=ItemAddWebCam"}">
46	{g->text text="change"}
47      </a>
48    </strong><br/>
49
50    <img src="{$form.imageUrl}" alt="{$form.imageUrl}"/>
51    <br/>
52
53    <input type="hidden" name="{g->formVar var="form[imageUrl]"}" value="{$form.imageUrl}"/>
54</div>
55
56<div class="gbBlock gcBackground1">
57  <input type="submit" class="inputTypeSubmit"
58   name="{g->formVar var="form[action][addWebCam]"}" value="{g->text text="Add Image"}"/>
59  {/if}
60</div>
61