tags:

views:

27

answers:

1

hi

I have a problem with "all" of my form submission "search form, login form, register form,.."

the problem shows when I submit the form it doesn't take me to the action page, instead it tack me to my root page :"http://localhost/project/Home/"

this is a sample of my search form witch search members or groups as the user choose and it can be submitted by clicking search.jpg

<form name="searchform"  action='Searchb.php'  method='GET' >
    <a href="">
        <img src="img/search.jpg"  width="60" height="49" onClick="searchform.submit()" style="border-style: none">
    </a>
    <input  type="text" name="Search" />&nbsp;
    <label>member</label><input name="radio1" type="radio" value="Member"  />&nbsp;
    <label>Group</label> &nbsp;<input name="radio1" type="radio" value="Group"   />
</form>"
+2  A: 

You have this in your code that is probably the problem:

<a href="">
 <img src="img/search.jpg"  width="60" height="49" onClick="searchform.submit()" style="border-style: none">
</a>

As you can see there is an empty link tag, and when you click on it, it takes you to your root localhost file...

You could try doing this:

<a href="#" onClick="searchform.submit(); return false;">
 <img src="img/search.jpg"  width="60" height="49" style="border-style: none">
</a>

Try it and let me know Ladislav

Ladislav
tanx it works :)
basma