mariokiller64 Posted June 10, 2010 Share Posted June 10, 2010 See, if I go to http://mapleworld.us.to "after going to the agreement and stuff", it leads to "http://mk64.uk.to/mapleworld/index3.php" instead (Would have been my IP address if the URL led to <IP>/mapleworld). I'm wondering how I can make the music player show up while making it mapleworld.us.to/index3.php. my index3.php <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd"> <html> <head> <title>MapleWorld - A New Server, A New World</title> <SCRIPT TYPE="text/javascript"> <!-- if (top.frames.length!=0) top.location=self.document.location; // --> </SCRIPT> </head> <FRAMESET rows="100,*"> <FRAME src="resources/player/player.php" frameborder="0" noresize="noresize" marginheight="0" marginwidth="0"> <FRAME src="index2.php" frameborder="0" noresize="noresize" marginheight="0" marginwidth="0"> </FRAMESET> </body> </html> Also, I'm getting Notice: Undefined variable: HTTP_COOKIE_VARS in C:\wamp\www\Mapleworld\index.php on line 6 Notice: Undefined index: agreement in C:\wamp\www\Mapleworld\index.php on line 7 A part of my index.php <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>MapleWorld Terms of Service Agreement</title> <?php $var = $HTTP_COOKIE_VARS["agreement"]; $var = $_COOKIE["agreement"]; if ( $var == "accepted" ) { echo "<META http-equiv='refresh' content='0;URL=index3.php'>"; } else { echo ""; } Really hope you guys can help, I'm not so good at this lol. Link to comment https://forums.phpfreaks.com/topic/204377-some-small-problems/ Share on other sites More sharing options...
jd307 Posted June 10, 2010 Share Posted June 10, 2010 Your site is most likely changing from the original domain to the mk64 domain because of the way that the DNS is set up for your hosting plan. It "looks" like your hosting is setup with the mk64 domain however the mapleworld one is "pointed" at the index.php page, meaning when you click the link it is directing back to mk64. You would have to check with your hosting service to ensure this is set up correctly and how to manage the domains for what you require. Looking at your errors, I believe you are recieveing these because you are trying to access the data stored in the cookie "agreement". As far as I can see from your code, you haven't set a cookie yet, therefore it is throwing up an error stating that the cookie "agreement" hasn't been defined. You need to use setcookie() before you can read it. Link to comment https://forums.phpfreaks.com/topic/204377-some-small-problems/#findComment-1070375 Share on other sites More sharing options...
mariokiller64 Posted June 10, 2010 Author Share Posted June 10, 2010 There's a cookie.php that does that... <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN"> <html> <head> <title>Saving Your Acceptance</title> <meta http-equiv="refresh" content="2;URL=resources/player/index.php"> <style type="text/css"> body { margin:20px; border:0; font:10px Arial; text-align:center; color:#333!important; } #message { width:300px; border:1px dashed #CCC; padding:15px; } </style> </head> <body> <?php $value = "accepted"; setcookie("agreement", $value); setcookie("agreement", $value, time()+60*60*24*7); /* expire in 1 Week */ echo "<center><div id='message'>Acceptance Saved For One Week. Redirecting.</div></center>"; ?> </body> </html> Also, there just notices I want to get rid of by fixing them instead of them making appear, a pretty small deal. Also, that mk64 thing didn't happen before I added the player....don't know why. player.php <html> <head> </head> <body> <script type="text/javascript" src="swfobject.js"></script> <div id="player">Get Flash Media Player to enjoy MapleWorld's tunes plox.</div> <script type="text/javascript"> var so = new SWFObject('player.swf','mpl','100%','100','9'); so.addParam('allowscriptaccess','always'); so.addParam('allowfullscreen','true'); so.addParam('flashvars','&file=playlist.xml&plugins=revolt&backcolor=ffffff&frontcolor=000000&lightcolor=193e63&playlistsize=24&skin=simple.swf&playlist=bottom&dock=false&autostart=true&shuffle=true&repeat=list'); so.write('player'); </script> </body> </html> Link to comment https://forums.phpfreaks.com/topic/204377-some-small-problems/#findComment-1070461 Share on other sites More sharing options...
mariokiller64 Posted June 13, 2010 Author Share Posted June 13, 2010 Anyone? Link to comment https://forums.phpfreaks.com/topic/204377-some-small-problems/#findComment-1071490 Share on other sites More sharing options...
dodgeitorelse Posted June 13, 2010 Share Posted June 13, 2010 Not sure if it means anything but I see a closing body tag </body> but no opening body tag <body> in code in original post. Link to comment https://forums.phpfreaks.com/topic/204377-some-small-problems/#findComment-1071618 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.