我试图回显该按钮,但是该链接不起作用,因此我认为href链接有问题,请提供帮助。
echo "<input class='button_normal' type='button' value='entertainment' onclick='window.location..href=<Electronic and Entertainment Products.php>'>";
@ james_91下面的代码应该可以解决问题:
<?php
echo "<input class=\"button_normal\" type=\"button\" value=\"entertainment\" onclick=\"window.location.href='Electronic and Entertainment Products.php'\">";
?>
我建议您不要在文件名中使用空格,因此建议使用下划线。
PHP中按钮内的JS最适合使用转义引号,在位置和href之间也有两个点,如Fred -ii-所评论
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句