~tsep-dev/tsep/0.9-beta

« back to all changes in this revision

Viewing changes to branches/symfony/app/views/profiles/admin_create.ctp

  • Committer: geoffreyfishing
  • Date: 2011-01-11 23:46:12 UTC
  • Revision ID: svn-v4:ae0de26e-ed09-4cbe-9a20-e40b4c60ac6c::125
Created a symfony branch for future migration to symfony

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<h2>Create a New Indexing Profile</h2>
 
2
<?php 
 
3
        echo $form->create('Profile');
 
4
?>
 
5
<fieldset>
 
6
        <dl>
 
7
                <dt>Profile Name</dt>
 
8
                <dd><?php echo $form->input('name',array('label'=> false))?></dd>
 
9
        </dl>
 
10
        <dl>
 
11
                <dt>Start URL</dt>
 
12
                <dd>
 
13
                        <?php echo $form->input('url',array('label'=> false))?>
 
14
                        <em>The URL to the document root of your website.</em>
 
15
                </dd>
 
16
        </dl>
 
17
        <dl>
 
18
                <dt>Regular Expression</dt>
 
19
                <dd>
 
20
                        <?php echo $form->input('regex',array('label'=>false,'disabled' => 'disabled',))?>
 
21
                        <em>This field is currently automatically generated.</em>
 
22
                </dd>
 
23
        </dl>
 
24
</fieldset>
 
25
<?php 
 
26
        echo $form->end(array(
 
27
                'div'=> array(
 
28
                        'class' => 'button'
 
29
                ),
 
30
                'label' => 'Create Profile'
 
31
        ));
 
32
?>
 
33
<br />
 
34
<b>You must index the new Profile before it will appear in the search results.</b>
 
35
 
 
36
<script type="text/javascript">
 
37
        $("#ProfileUrl").change(function () {
 
38
                var value = $(this).val();
 
39
 
 
40
                var a = document.createElement('a');
 
41
 
 
42
                a.href = value;
 
43
 
 
44
                $("#ProfileRegex").val(a.hostname);
 
45
        });
 
46
 
 
47
        $("#ProfileAdminCreateForm").submit(function () {
 
48
                $("#ProfileUrl").change();
 
49
                $("#ProfileRegex").attr("disabled","");
 
50
        });
 
51
 
 
52
 
 
53
</script>
 
 
b'\\ No newline at end of file'