ID:               26370
 Comment by:       stanprog at stanprog dot com
 Reported By:      kreny at dalouis dot com
 Status:           Bogus
 Bug Type:         MySQL related
 Operating System: Linux (Redhat 9.0)
 PHP Version:      4.3.4
 New Comment:

I have the same problem with <SCRIPT> and src=

Here is what I found (This is block of one my class):

The following code didn't work:
foreach($this->addJS as $srcLocation) {
  $head .= '<script src="'.$srcLocation.'" />';
}

But the following works fine:
foreach($this->addJS as $srcLocation) {
  $head .= '<script src="'.$srcLocation.'"></script>';
}

In the beginning, I thought that the problem is with the way I close
the SCRIPT element, but the following works too (I just remove forech
loop):
$head .= '<script src="'.$srcLocation.'" />';

If instead src= I write sra= it works(I mean didn't crash), also if I
write srca= instead src= it works too. 

So now I think that it's a bug, some kind of conflict between src= and
foreach loop, something internally may be.
I try this without classes and the problem is the same, it's not in the
class context.

Best Regards!
Stanislav Yordanov


Previous Comments:
------------------------------------------------------------------------

[2004-01-11 14:01:07] kreny at dalouis dot com

Thank you Dodu. Your comment is really a new idea to me.
I have checked my Error 404 page. As my Error 404 page also quote the 
"write logfile" function so I think that is just the reason! I think
we've found it out.

BTW, although the broken image code make a redirection to 404 page, but
in my page, I have several broken images. But why it effects just one
time? Maybe because of the configuration?

I also added your commend to my full page at 
http://linux.dalouis.com/php4.3.4_bug.htm

Regards!

------------------------------------------------------------------------

[2004-01-11 13:46:46] dodu at hotmail dot com

Hello, I got a very similar issue.

Decription :

1. On my first page, I included a "write logfile" instructions such as
:
----------------------------------------------------
if (@$file_stat=fopen('../stat/stat.txt, 'a')) {
$p_stat = fputs($file_stat, 'pageview=1 and so on; ');
fclose($file_stat);
}

2. On another page it appears I had a broken image

Although my "write logfile" instruction does exist only in first page,
when loading the second one, the stat logfile was incremented !

Furthermore, in case the broken image was located in first page, then
the logfile were incremented twice at each request of the page !

Explanation :
-------------
I must say I took several hours to understand the logic behind :)
Actually, it was a very easy issue :(

My first page is set up as the default target for Error 404
redirection, that is the reason why all broken items (even images)
perform a request to it ... and then increment my logfile :) That's it
:)

You can easily check it by logging the $REQUEST_URI (At that way you
will get the name of the original requested item :) Also, this is a way
to track the broken links. Isn't it ?

Regards.

------------------------------------------------------------------------

[2003-12-14 00:09:42] kreny at dalouis dot com

New address:

http://linux.dalouis.com/php4.3.4_bug.htm

------------------------------------------------------------------------

[2003-12-05 13:44:15] kreny at dalouis dot com

Anyone who has the idea please feel free to contact me at
[EMAIL PROTECTED], or write the feedback at
http://www.dalouis.com/en/feedback.php
I also want to take part in the Chinese Man Page Project and
Chinese-translation project for any open source, so anybody please feel
free to ask me to translate the English man page or introduction for
OPEN SOURCE. 
BTW, the lastest source of bug is at
http://www.dalouis.com/~kreny/php4.3.4_bug.htm
Thank you!

------------------------------------------------------------------------

[2003-11-24 00:31:27] yuanhuanglin at hotmail dot com

Thank you very much for your reply.
I also hope that it is not a bug, but may I have your attention again
that wheather a non-mysql-script-connected page can run a MySQL query
in the pages? This pages just start with the code I posted in 
http://www.s.fpu.ac.jp/t-yuan/php4.3.4_bug.htm
On that page I wrote some more details of my problem. It will be very
nice of you to read my problem description.

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/26370

-- 
Edit this bug report at http://bugs.php.net/?id=26370&edit=1

Reply via email to