title: get variable javascript in wicket event
body: <p>First of all I want to mention that I am a beginner when it comes to js and wicket.</p>
  
  <p>I am trying to retrieve a variable that is defined in javascript on my page. I want to retrieve this variable when an event is triggered on my page.</p>
  
  <p>I use this code to retrieve the variable but it is not working (this is my wicket panel java class): </p>
  
  <pre><code>...
      add(new AjaxEventBehavior("onclick") {
          private static final long serialVersionUID = 1L;
  
          protected void onEvent(AjaxRequestTarget target) {
          if(target != null) {
                  String value = RequestCycle.get().getRequest().getParameter("i");
              }
          }
      });  
  </code></pre>
  
  <p>Could someone point me in the right direction?</p>
  
  <p>Thank you in advance.</p>