Jquery click and one click event
<p>Basically I have a Jquery function so that when you click 'Return Journey' it checks to see if the <strong>destination</strong> is an Airport. If it is an airport address it prompts the user for their Flight details. When the user clicks 'Return Journey' the text changes to 'One Way' which is why I used the .one click function so that it would not ask you for the flight details when you click it a second time.</p>

<p>Although that works well, if the user then decides to click 'One Way' and then 'Return Journey' for the second time, obviously they will not be prompted for their flight number. Is there a way I could simulate this so it alternates between asking them for the flight number when the text display is 'Return Journey' and not asking the user for the flight details if the text display is 'One Way' ?</p>

<p>Here is the Jquery:</p>

<pre><code>    $('#href-rtn-jny').one('click', function(){

    if (checkIsAirport(label.html()) != null &amp;&amp;
        label.parent().parent().attr('title') == "Dropoff") {

        $('#href-edit-flightno').css('display','block');


        // Flight info dialog
        $("#cp-div-flight-info").dialog({
            autoOpen: false,
            width: 620,
            height: 305,
            modal: true,
            draggable: false,
            resizable: false,
            closeOnEscape: false,
            closeText: 'show',
            show: 'clip',
            title: 'Online Booking',
            close: function() {

                $('#div-flight-info-row').css('display','none');
                $(".ui-dialog-titlebar").show();

                // Give next search box focus
                rowdiv.next().find('.addr-ho-input').focus();

            }

        });

        $('#btn-flight-ok').bind('click', function() {

            $('#cp-div-flight-info').dialog('close');

        });
</code></pre>

<p>Here is the HTML of the clickable <p> element:</p>

<pre><code>&lt;p class="p-row-functions left bg-image-return"&gt;
    &lt;a id="href-rtn-jny" class="bg-link-style" href="#"&gt;Return Journey&lt;/a&gt;
&lt;/p&gt;
</code></pre>

<p>Which changes to: (on click):</p>

<pre><code>&lt;p class="p-row-functions left bg-image-arrowright"&gt;
    &lt;a id="href-rtn-jny" class="bg-link-style" href="#"&gt;One Way&lt;/a&gt;
&lt;/p&gt;
</code></pre>
