title: Get param from html to java function call
body: <p>I am working with a java generated dynamic webpage, and I'm printing links from a query to a JDO. But I don't understand how can I get and use the parameter from the url.</p>
  
  <p>My html objects are printed like this</p>
  
  <pre><code> print = print + "Nome:&lt;a href='displayFotos?album="+results.get(i).nome+ "'&gt;"+ 
   results.get(i).nome+ "&lt;/a&gt;&lt;/br&gt;";
  </code></pre>
  
  <p>The results in having for example:</p>
  
  <pre><code>Nome:&lt;a href='displayFotos?album=album1'&gt;album1&lt;/a&gt;
  </code></pre>
  
  <p>So, in my head when clicked it should be calling the address of the dynamic webpage album like this and should get the parameter. In this case it would be the album1.</p>
  
  <pre><code>  else if (address.indexOf("/dinamicas/album") != -1)   {
          String album = param1;
          System.out.println("did it work? "+album);
      }
  </code></pre>
  
  <p>And I have in the beginning of the class a general parameter that I use to get text from html forms.</p>
  
  <pre><code>  String param1 = req.getParameter("param1");
  </code></pre>
  
  <p>I understand this might be an easy question but I'm not getting there by myself.</p>