title: Curl redirect link cut after "*.pdf"
body: <p>I have a Problem with curl and for the moment I can give you just examples of the links. I hope you can help me with this.
  I have a URL "<a href="https://www.myexample/documents/15611" rel="nofollow noreferrer">https://www.myexample/documents/15611</a>"
  This link will be redirected to somthing like "<a href="https://myexample/" rel="nofollow noreferrer">https://myexample/</a><em>/</em>.pdf?*sometrashwithmanymanychars".</p>
  
  <p>Not working</p>
  
  <pre><code>curl -L -O https://www.myexample/documents/15611 
  </code></pre>
  
  <p>not working either:</p>
  
  <pre><code>curl -L -O https://myexample/*/*.pdf?*sometrashwithmanymanychars
  </code></pre>
  
  <p>This is working</p>
  
  <pre><code>curl -L -O https://myexample/*/*.pdf
  </code></pre>
  
  <p>So my idea was:
  Do</p>
  
  <pre><code>curl -L -O https://www.myexample/documents/15611 
  </code></pre>
  
  <p>But cut the redirected link after ".PDF?"</p>
  
  <p>Is something like this possible?
  Zio</p>