PDA

View Full Version : input tags and the searchbox


steve45king
04-25-2004, 02:26 AM
Hi there!

I installed phpdig in a directory named "search", so all related phpdig files are stored there.
on the mainpage of my website there is a searchbox with the following form action and input tags:

form action="search/search.php" method='get'
input type='hidden' name='template_demo' value=""
input type='hidden' name='site' value=''
input type='hidden' name='path' value=''
input type='hidden' name='result_page' value=""

how can i use these field to use a template (lets say searchresults.htm) file located in the root?

Next problem is, that all links at the resultpage are "converted" to the "search"-directory:

eg:

http://mydomain.com/site.html

is changed to

http://mydomain.com/search/site.html

What is the workaround for this?

thanx!!!

vinyl-junkie
04-25-2004, 08:17 AM
I think what you're looking for is something like this (http://www.phpdig.net/showthread.php?s=&postid=3767#post3767).

steve45king
05-31-2004, 10:39 AM
Hi again!

Sorry, but i've still problems with the resultpage...
is the problem solved in the link you have postet???

if I put the search.php (and all other phpdig files) in a directory (eg: www.mydomain.com/search) all links at the resultpage (which is in the root directory) are converted to the "search"-directory:

the link

http://mydomain.com/site.html

is changed to

http://mydomain.com/search/site.html

need help! :confused:

vinyl-junkie
05-31-2004, 04:26 PM
Originally posted by steve45king
Hi again!

Sorry, but i've still problems with the resultpage...
is the problem solved in the link you have postet???
Yes. You need to code your search box just like the example I gave in that other thread, making sure of course that you change "path/to" values to the appropriate names for your server. Also, be sure to change the template name to whatever template you are using on your server. Note that your template will be located in search/templates/your-template-name.html.

if I put the search.php (and all other phpdig files) in a directory (eg: www.mydomain.com/search) all links at the resultpage (which is in the root directory) are converted to the "search"-directory:

the link

http://mydomain.com/site.html

is changed to

http://mydomain.com/search/site.html

need help! :confused:
Sorry, but you lost me. Are you saying that your search results all have the search folder in the link?

Is this a public internet site you're working with? If so, post the link to your search page and I'll see if I can figure out what the problem is.

Your phpdig files need to preserve the same directory structure they had when you unzipped them. As long as you keep that, you should be able to get this to work.