[SOLVED]Strange </script> problem!!

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
mjseaden
Forum Contributor
Posts: 458
Joined: Wed Mar 17, 2004 5:49 am

[SOLVED]Strange </script> problem!!

Post by mjseaden »

Dear All

Of the all the problems I have had in making code, this has got to be the strangest.

I have a <SCRIPT> clause like this

Code: Select all

<SCRIPT LANGUAGE='JavaScript'> ...my javascript code generated by PHP/MySQL... </SCRIPT>
Notice the capitals in </SCRIPT>. Now here's the bizarre thing....

On my page, when I execute it, the code comes up as text. When I look at the source code on my browser to check it out, after the

Code: Select all

<SCRIPT LANGUAGE='JavaScript'>
Immediately comes a

Code: Select all

</script>
Which explains why the code comes up as text - but this is something I have not typed in and is not present on the original PHP script before heading to the client! However, I have check and rechecked the code, even deleted the <SCRIPT> clause and retyped it manually again and deleted lines above and before it, and yet the strange </script> code keeps on appearing.

Can someone explain what is going on? This is weird!

Many thanks

Mark
mjseaden
Forum Contributor
Posts: 458
Joined: Wed Mar 17, 2004 5:49 am

Post by mjseaden »

/solved
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Post by John Cartwright »

You should always post the solution so other people that have the same problem can see.
User avatar
launchcode
Forum Contributor
Posts: 401
Joined: Tue May 11, 2004 7:32 pm
Location: UK
Contact:

Post by launchcode »

Phenom - most the time I would agree, but this is too specific and is obviously a user error somewhere to be of much use to us :)
mjseaden
Forum Contributor
Posts: 458
Joined: Wed Mar 17, 2004 5:49 am

Post by mjseaden »

No it isn't actually

The 'solution' was to take exactly the same code and copy and paste it from another spot - I don't actually know why this 'solved' it.

Mark
mjseaden
Forum Contributor
Posts: 458
Joined: Wed Mar 17, 2004 5:49 am

Post by mjseaden »

And can some specific people stop whinging at me about some Section 8(b)(i) Part 1 Paragraph 2 Subset 2 Section 2.1b of the forum 'etiquette'.

Many thanks

Mark
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

mjseaden wrote:And can some specific people stop whinging at me about some Section 8(b)(i) Part 1 Paragraph 2 Subset 2 Section 2.1b of the forum 'etiquette'.

Many thanks

Mark
:lol:

My copy of the forum etiquette has only one paragraph: RTFM
The nice thing is: it's truly universal ;)

Would be interesting to hear what other people's copy includes... :lol:
mjseaden
Forum Contributor
Posts: 458
Joined: Wed Mar 17, 2004 5:49 am

Post by mjseaden »

RTFM - Read the f****** manual?

The PHP manual makes no mention of the problem - hence the need to ask other experienced PHP users if they have any ideas from their own experience.
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

mjseaden wrote:RTFM - Read the f****** manual?

The PHP manual makes no mention of the problem - hence the need to ask other experienced PHP users if they have any ideas from their own experience.
It wasn't meant personally at all, man ;) I meant it generally, not directed at you at all. I'm just curing last night's hangover ;)
mjseaden
Forum Contributor
Posts: 458
Joined: Wed Mar 17, 2004 5:49 am

Post by mjseaden »

np patrik
Post Reply