I am facing a challenge with my AngularJS search application. The search box is located on a standard HTML page that is not part of the AngularJS framework. Here is how the input field looks:
<form accept-charset="UTF-8" name="search" id="search" action="/search/app/#/results" method="get" >
<legend class="title">Search everything!</legend>
<input type="text" class="styledTextInput" name="q" placeholder="Keywords" />
<button class="btn btn-search" type="submit">Search</button>
</form>
Upon submitting the form, the URL displays as follows:
myapp.com/search/app/?q=medical#/results
To ensure proper functionality, I need the URL structure to be:
myapp.com/search/app/#/results?q=medical
I have attempted different methods to rewrite the URL in Apache, but without success (not my strong suit). Should I focus on the web server or AngularJS to resolve this issue? Most examples I've come across assume that the form is within the AngularJS app itself (which is not the case for me).