|
Posted by tihu on 04/25/06 13:40
Tim Roberts wrote:
> "tihu" <tim.n.hunt@gmail.com> wrote:
> >
> >You were spot on about it being javascript, I think the problem is
> >img.src='';
> >
> >Done a quick test and it seems both firefox and explorer refuse to let
> >img.src be a blank string and automatically set img.src to something
> >nonblank if you try. In firefox img.src was set to
> >'http://server/pagedir/testpage.html' immediately after img.src='', in
> >explorer img.src was 'http://server/pagedir/'. (it was x.gif before)
>
> Yes, of course it is. This should not be a surprise, nor should it be
> browser-dependent. This is a relative URL, which means that the blank
> string is relative to the URL of the page it came from.
Why did they come up with different urls?
>
> >I think this is why the php script will be called twice, once when you
> >open the page in your browser, the second time when the setting
> >img.src='' ends up trying to get the current page (why? silly
> >browser..)
>
> Not "silly browser". Silly programmer. That is exactly what is supposed
> to happen.
Patronising git
Navigation:
[Reply to this message]
|