javascriptinternet-explorer-7submitaol

AOL 9.0 IE7 javascript Submit problem


I'm having some problems with AOL and IE 7. Some members on my site have this setup and I'm having trouble getting some forms to work for them. The html/javascript is this

<li ><a href="javascript:;" onclick="photo_user_award_give();">Award</a></li>

<form action="" name="form_user_award_give" method="post">
                <input type="hidden" name="action" value="Give Award"/>
            </form>

function photo_user_award_give() {
    //simple function to submit a form
    document.form_user_award_give.submit();
}

I've just taken the main bits just to give you a flavour.

I also have another problem with another button. here is the code.

<li>
                    <form action="#edit_box" id="edit_photo_form" method="post">
                        <a onclick="document.getElementById('edit_photo_form').submit();" style="background-image:url('http://www.ephotozine.com/v5/images/site/pencil.png');" href="javascript:void(0)">Edit</a>
                        <input type="hidden" name="action" value="Edit"/>
                    </form>

                    </li>

I need to keep the elements as they for style are which is why I haven't used a submit button. Does anyone have any ideas? Or a place to download AOL 9.0?

Thanks Richard


Solution

  • Got the answer instead of href="javascript:;" or href="javascipt:void;" use href="#" as the page is refreshing anyway this seems to do the trick. or event #nogo to keep the screen where it is