dunnsearch Posted September 28, 2008 Share Posted September 28, 2008 I have a Music Search engine called DUNN tunes. You can stream music true my flash player. My player opens in a new php window. Under the flash player in the php page i would like to show a embedded this song on your website/myspace. It should be a iframe. every page has a different url. Every page could have a simple iframe and say above it embedded code. Here is two pages two show you what the urls are like: http://dunnsearch.mobi/listen.php?src=MP3Realm&name=U2-Exit.mp3&url=http://darrenrobbins.com/U2-Exit.mp3 And a different song with a different page http://dunnsearch.mobi/listen.php?src=wrzuta&id=7JBEKHZzfa&name=Madcon%20-%20Beggin The hight of the iframe should only show to logo and player, not the embedded code, and scrolling should be turned off. Please help, as i think this will double my traffic. Thanks Link to comment https://forums.phpfreaks.com/topic/126192-how-do-i-put-an-embed-code-on-every-page-for-users-to-add-to-their-websites/ Share on other sites More sharing options...
dunnsearch Posted September 29, 2008 Author Share Posted September 29, 2008 anyone? please, im really stuck Link to comment https://forums.phpfreaks.com/topic/126192-how-do-i-put-an-embed-code-on-every-page-for-users-to-add-to-their-websites/#findComment-653040 Share on other sites More sharing options...
dunnsearch Posted September 30, 2008 Author Share Posted September 30, 2008 please guys? i really need this I will be sooo thankful Link to comment https://forums.phpfreaks.com/topic/126192-how-do-i-put-an-embed-code-on-every-page-for-users-to-add-to-their-websites/#findComment-654268 Share on other sites More sharing options...
dropfaith Posted September 30, 2008 Share Posted September 30, 2008 <textarea>Code</textarea> or replace the < with < and the > with > theres a few ways depending on if you want them styled and things like that Link to comment https://forums.phpfreaks.com/topic/126192-how-do-i-put-an-embed-code-on-every-page-for-users-to-add-to-their-websites/#findComment-654272 Share on other sites More sharing options...
dunnsearch Posted October 1, 2008 Author Share Posted October 1, 2008 <textarea>Code</textarea> or replace the < with < and the > with > theres a few ways depending on if you want them styled and things like that Thanks So far i have this: <textarea><IFRAME SRC="" WIDTH=294 HEIGHT=75 SCROLLING=NO></IFRAME></textarea> But what will i put in the SRC="" so it will display the page URL? Link to comment https://forums.phpfreaks.com/topic/126192-how-do-i-put-an-embed-code-on-every-page-for-users-to-add-to-their-websites/#findComment-654662 Share on other sites More sharing options...
damianjames Posted October 1, 2008 Share Posted October 1, 2008 If you're looking to insert the full URL of what page the user is on in the SRC attribute, you can use the following (credit to this guy via Google): <?php function selfURL() { $s = empty($_SERVER["HTTPS"]) ? '' : ($_SERVER["HTTPS"] == "on") ? "s" : ""; $protocol = strleft(strtolower($_SERVER["SERVER_PROTOCOL"]), "/").$s; $port = ($_SERVER["SERVER_PORT"] == "80") ? "" : (":".$_SERVER["SERVER_PORT"]); return $protocol."://".$_SERVER['SERVER_NAME'].$port.$_SERVER['REQUEST_URI']; } function strleft($s1, $s2) { return substr($s1, 0, strpos($s1, $s2)); } ?> Then call the function in the textarea. <textarea><IFRAME SRC="<?php print(selfURL()); ?>" WIDTH=294 HEIGHT=75 SCROLLING=NO></IFRAME></textarea> Link to comment https://forums.phpfreaks.com/topic/126192-how-do-i-put-an-embed-code-on-every-page-for-users-to-add-to-their-websites/#findComment-654693 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.