treilad Posted July 15, 2006 Share Posted July 15, 2006 Simple question with a simple answer, I'm sure.This is my code:[code]<?phpinclude ('db.php');if(isset($_COOKIE['ID_my_site'])){$username = $_COOKIE['ID_my_site'];$pass = $_COOKIE['Key_my_site'];$check = mysql_query("SELECT * FROM users WHERE username = '$username'")or die(mysql_error());while($info = mysql_fetch_array( $check )){if ($pass != $info['password']){ header("Location: loginpage.php");}else{header("Location: links.php");}}}else{header("Location: loginpage.php");}?>[/code]This:[quote]header("Location: links.php");[/quote]I would like to change to have the effect of this:[quote]<meta http-equiv="refresh" content="5;url=http://stuff.com/stuff">[/quote]I just simply don't know how to embed the HTML within the PHP. Quote Link to comment https://forums.phpfreaks.com/topic/14640-html-within-php/ Share on other sites More sharing options...
AndyB Posted July 15, 2006 Share Posted July 15, 2006 OK, I'm confused. What 'effect' do you want? And why? Quote Link to comment https://forums.phpfreaks.com/topic/14640-html-within-php/#findComment-58274 Share on other sites More sharing options...
pixy Posted July 15, 2006 Share Posted July 15, 2006 Why can't you make it a php page and do this:[code]<?phpecho '<meta http-equiv="refresh" content="5;url=link.php">';?>[/code] Quote Link to comment https://forums.phpfreaks.com/topic/14640-html-within-php/#findComment-58279 Share on other sites More sharing options...
treilad Posted July 15, 2006 Author Share Posted July 15, 2006 It already is a PHP page, but yes, that worked. I echoed it and it works fine now. Thanks. :) Quote Link to comment https://forums.phpfreaks.com/topic/14640-html-within-php/#findComment-58288 Share on other sites More sharing options...
pixy Posted July 15, 2006 Share Posted July 15, 2006 Lol, you're funny. Quote Link to comment https://forums.phpfreaks.com/topic/14640-html-within-php/#findComment-58314 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.