| |

VerySource

 Forgot password?
 Register
Search
View: 1382|Reply: 5

echo with document.write problem

[Copy link]

1

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-1-4 21:40:02
| Show all posts |Read mode
A page contains <script language = 'JavaScript' type = 'text / JavaScript' src = '.. / inc / top.php'> </ script>

The code of top.php is:
document.write ('<div class = "nav" align = "center"> </ div>')
<? php
print "document.write ('<div class =' ​​nav 'align =' center '> </ div>')";
?>
Using the one directly above makes it difficult to use the following php code. Why?
Thank you
Reply

Use magic Report

0

Threads

4

Posts

3.00

Credits

Newbie

Rank: 1

Credits
3.00

 China

Post time: 2020-1-5 00:00:02
| Show all posts
print "document.write ('<div class = nav align = center> </ div>')";
Reply

Use magic Report

0

Threads

24

Posts

16.00

Credits

Newbie

Rank: 1

Credits
16.00

 China

Post time: 2020-1-5 01:33:01
| Show all posts
Use escape sign
Reply

Use magic Report

0

Threads

2

Posts

3.00

Credits

Newbie

Rank: 1

Credits
3.00

 China

Post time: 2020-6-5 13:30:01
| Show all posts
Questions in quotes...
Reply

Use magic Report

0

Threads

2

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-31 20:30:01
| Show all posts
document.write ('<div class= "nav "align= "center "> </div>');

<?php
echo "document.write ('<div class ='nav' align ='center'> </div>') ";
?>
Reply

Use magic Report

0

Threads

2

Posts

3.00

Credits

Newbie

Rank: 1

Credits
3.00

 China

Post time: 2020-8-31 21:00:01
| Show all posts
[code=PHP]<?php
echo "document.write('<div class=\"nav\" align=\"center\"> </div>') ";
?> [/code]
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list