Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- session_start();
- ?>
- <html>
- <head>
- <meta http-equiv="refresh" content="1" />
- </head>
- <?php
- $username="changeme";
- $password="changeme";
- $database="changeme";
- $dbc = mysql_connect(localhost,$username,$password);
- if (!$dbc) {
- die (mysql_error());
- }
- $db = mysql_select_db($database);
- if (!$db) {
- die( "Unable to select database");}
- $sql3 = "SELECT * FROM `request` WHERE `status` = '3'";
- $res3 = mysql_query($sql3) or die(mysql_error());
- $row1 = mysql_fetch_assoc($res3);
- if(!isset($_SESSION['sang'])) {
- $_SESSION['sang'] = $row1['url'];
- }else{
- if($_SESSION['sang'] != $row1['url']){
- ?>
- <script type='text/javascript'>
- my_window = window.open ("<?php echo $row1['url'];?>","Spotify");
- </script>
- <?php
- $_SESSION['sang'] = $row1['url'];
- }
- }
- ?>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement