Dialoge opens like a link
Hello!
I have a problem with the jquery mobile dialoges.
Here is my definition of the Link to open the popup:
- <a data-icon="add" data-rel="dialog" id="addAttachment" href="#attachmentDialogue">Attachment add</a>
Here is the code for the popup inside the same html file:
- <div id="attachmentDialogue" data-role="page">
<div data-role="header" data-theme="d" data-position="inline">
<h1>Attachment hinzufügen</h1>
</div>
<div data-role="content" data-theme="c">
<form id="uploadAttachment" action="" method="post">
<input type="hidden" name="_rev" value="{{_rev}}">
<p><label>Bitte wählen Sie eine Datei für den Upload aus:</label><input type="file" name="_attachments"></p>
<p><button type="submit">Upload</button></p>
<a href="#" data-role="button" data-rel="back" data-theme="c">Abbrechen</a>
</form>
</div>
</div>
With this, there are 2 problems:
- Wrong transition effekt (the dialogue comes from the right side but it should pop up)
- The $('#attachmentDialogue').dialog('close'); doesn't work if I call it.
I hope somebody can help me!
Best regards!