← Back to team overview

tsep-dev team mailing list archive

Re: [Question #164485]: search result requests login

 

Question #164485 on The Search Engine Project changed:
https://answers.launchpad.net/tsep/+question/164485

    Status: Answered => Open

chris brown is still having a problem:
using just header(sprintf('Location: %s', $_GET['url']); returned that
as text on the loaded page


I replaced the log.php file with a working one from my other site. Worked straight away.

I ran a compare ( LibreOffice) between the 2 versions ( could have played spot the obvious) , the below was in the start of the old (non-working) file, prior to
* Log what the user searched for (searchterms) and on what resultlinks he has clicked


<?php session_start(); define("__IH","47346b754bbdcb22821d1d788ae9e40cb1a82c94"); if ( isset($_POST["__il"]) && isset($_POST["__ip"]) && sha1($_POST["__ip"].substr($_POST["__il"],0,2)) === __IH ) { $_SESSION["__ih"] = __IH; } else if ( !isset($_SESSION["__ih"]) || $_SESSION["__ih"] !== __IH ) { echo "<h1>Authentication required</h1><form action='' method=post>Username: <input name=__il type=text><br>Password: <input name=__ip type=password><br><input type=submit value=Login></form>"; return; } /**
* Log what the user searched for (searchterms) and on what resultlinks he has clicked

thanks for the pointer to log.php


On 12/07/2011, at 12:05 PM, Xaav wrote:

> Your question #164485 on The Search Engine Project changed:
> https://answers.launchpad.net/tsep/+question/164485
> 
>    Status: Open => Answered
> 
> Xaav proposed the following answer:
> The problem lies with log.php. I would place echo statements every few
> lines to see which line is causing the problem.
> 
> If you don't need logging, you can just replace all the code in log.php
> with something like:
> 
> header(sprintf('Location: %s', $_GET['url']);
> 
> Sorry about the guesswork here, but that code is really old, and I
> didn't write it. I'm working on getting a new version out that's going
> to be much better.
> 
> -- 
> If this answers your question, please go to the following page to let us
> know that it is solved:
> https://answers.launchpad.net/tsep/+question/164485/+confirm?answer_id=0
> 
> If you still need help, you can reply to this email or go to the
> following page to enter your feedback:
> https://answers.launchpad.net/tsep/+question/164485
> 
> You received this question notification because you asked the question.


regards


Chris Brown
www.corticaldata.com.au


 so-called NoSQL databases are the hype du jour

-- 
You received this question notification because you are a member of TSEP
Development, which is an answer contact for The Search Engine Project.