Difference between revisions of "Adding an Auto-Completer to a non-workflow page"

From EPrints Documentation
Jump to: navigation, search
(Created page with '==Adding an Auto-Completer to a non-workflow page== In a workflow, adding an auto-completer is relatively sinple: <source lang="xml"> <field ref="publication" inpu…')
 
Line 3: Line 3:
 
In a workflow, adding an auto-completer is relatively sinple:
 
In a workflow, adding an auto-completer is relatively sinple:
  
<source lang="xml">
 
 
   <field ref="publication"
 
   <field ref="publication"
 
           input_lookup_url="{$config{perl_url}}/get_journals"/>
 
           input_lookup_url="{$config{perl_url}}/get_journals"/>
</source>
 
  
 
.... and the EPrints application takes care of all the "stuff" on the main page.
 
.... and the EPrints application takes care of all the "stuff" on the main page.
Line 12: Line 10:
 
The return format is fairly simple too:
 
The return format is fairly simple too:
 
An unordered list of records to display, with each "fill-in" item part of a sub-list:
 
An unordered list of records to display, with each "fill-in" item part of a sub-list:
<source lang="html">
+
 
<ul class="journals">
+
  <ul class="journals">
<li class="">University of Leeds<br />
+
  <li class="">University of Leeds<br />
  [University of Leeds] http://iss.leeds.ac.uk/  
+
    [University of Leeds] http://iss.leeds.ac.uk/  
  <ul>
+
    <ul>
  <li id="for:value:component:_oid">17259</li>
+
    <li id="for:value:component:_oid">17259</li>
  <li id="for:value:component:_ocname">University of Leeds</li>
+
    <li id="for:value:component:_ocname">University of Leeds</li>
  <li id="for:value:component:_oname">University of Leeds</li>
+
    <li id="for:value:component:_oname">University of Leeds</li>
  <li id="for:value:component:_ourl">http://iss.leeds.ac.uk/</li>
+
    <li id="for:value:component:_ourl">http://iss.leeds.ac.uk/</li>
  <li id="for:value:component:_oacronym"></li>
+
    <li id="for:value:component:_oacronym"></li>
  <li id="for:value:component:_onamepreferred"></li>
+
    <li id="for:value:component:_onamepreferred"></li>
  <li id="for:value:component:_oaltname">University of Leeds</li>
+
    <li id="for:value:component:_oaltname">University of Leeds</li>
  <li id="for:value:component:_oalturl"></li>
+
    <li id="for:value:component:_oalturl"></li>
 +
    </ul>
 +
  </li>
 +
  <li class="">
 +
    .....
 +
  </li>
 
   </ul>
 
   </ul>
</li>
+
 
<li class="">
 
    .....
 
</li>
 
</ul>
 
</source>
 
  
 
foo
 
foo

Revision as of 09:17, 12 April 2010

Adding an Auto-Completer to a non-workflow page

In a workflow, adding an auto-completer is relatively sinple:

  <field ref="publication"
         input_lookup_url="{$config{perl_url}}/get_journals"/>

.... and the EPrints application takes care of all the "stuff" on the main page.

The return format is fairly simple too: An unordered list of records to display, with each "fill-in" item part of a sub-list:


foo