hhisc383 Posted February 4, 2007 Share Posted February 4, 2007 Hey everyone. I'm going to see if I can word this correctly! Here's the problem...I use the code below to load content into my web site. I recently added a streaming mp3 player to the site, and when someone clicks a link on the site, the mp3 player starts over again. I want it to be able to continue playing without interruption when people are browsing around the site. I thought that with the code below, the only thing that changes on the page is the new content that comes in from that request. <?php if ($_GET['go']=='shows') { include 'content/contentShows.php'; } elseif ($_GET['go']=='journal') { include 'content/contentJournal.php'; } elseif ($_GET['go']=='audio') { include 'content/contentAudio.php'; } elseif ($_GET['go']=='video') { include 'content/contentVideo.php'; } elseif ($_GET['go']=='merch') { include 'content/contentMerch.php'; } elseif ($_GET['go']=='bio') { include 'content/contentBio.php'; } elseif ($_GET['go']=='photos') { include 'content/contentPhotos.php'; } elseif ($_GET['go']=='contact') { include 'content/contentContact.php'; }else{ include 'content/contentNews.php'; } ?> Link to comment https://forums.phpfreaks.com/topic/37053-solved-loading-content/ Share on other sites More sharing options...
Orio Posted February 4, 2007 Share Posted February 4, 2007 Use frames. Orio. Link to comment https://forums.phpfreaks.com/topic/37053-solved-loading-content/#findComment-176953 Share on other sites More sharing options...
hhisc383 Posted February 4, 2007 Author Share Posted February 4, 2007 yea i was thinking about doing that...but is there any way that you can think of to get it to work like it is currently set up? Link to comment https://forums.phpfreaks.com/topic/37053-solved-loading-content/#findComment-176955 Share on other sites More sharing options...
corbin Posted February 4, 2007 Share Posted February 4, 2007 You could use some simple ajax to replace the content of the page, but I try to avoid ajax for things like that at all costs. Link to comment https://forums.phpfreaks.com/topic/37053-solved-loading-content/#findComment-176965 Share on other sites More sharing options...
Orio Posted February 4, 2007 Share Posted February 4, 2007 When you press a link (in a website with no frames) the whole page reloads, including the mp3 player. The only simple solution will be putting the mp3 player in an frame, and loading only the other frame/s. Orio. Link to comment https://forums.phpfreaks.com/topic/37053-solved-loading-content/#findComment-176973 Share on other sites More sharing options...
hhisc383 Posted February 4, 2007 Author Share Posted February 4, 2007 ok. i guess i will try that. thanks for your help Link to comment https://forums.phpfreaks.com/topic/37053-solved-loading-content/#findComment-176974 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.