2 Replies - 558 Views - Last Post: 09 November 2009 - 03:31 PM

#1 MusicDev  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 08-November 09

Is this even possible?

Posted 08 November 2009 - 06:57 PM

I posted this in the Java forum and probably belongs over here instead.

Here is what I am trying to do. I have 2 links/code for embedding a flash audio player. One in html and one in bbcode. The html one uses onclick and works the way I want it to. It just pops up a flash audio player with the artists music in the correct window size and new window. This brings me to the wonderful bbcode! Unfortunately bbcode does not allow a target="_blank" or "onclick" so what happens is the flash player opens in the same window and opens full screen. So you have this 540x270 px flash player surrounded by a ton of real estate.

I have done some research and found a script that will resize the browser window when opening. This actually is not real great because since it does not open in a new window, if they are using firefox with 6 tabs open for example, all of them resize. I would rather just go with the full screen if that is the case.

The question becomes, is there a way in java to take a specific page and when called from a link, load it in a new browser window with a specific size? So when someone posts on a forum that only allows bbcode and the url link looks like
 [url=http://mysite.com/myplayercode&songid_300]song name[/url]
that when myplayercode is called, a new small popup will open?

Thanks for the help!

Is This A Good Question/Topic? 0
  • +

Replies To: Is this even possible?

#2 Fratyr  Icon User is offline

  • D.I.C Head

Reputation: 5
  • View blog
  • Posts: 139
  • Joined: 10-April 08

Re: Is this even possible?

Posted 09 November 2009 - 03:19 PM

Well, it's not possible as you want it, but if I were you, I'd do something like ( in index.php, if it's your main file and treats the mplayercode&songid get parameters ):

At the top of the page:
<?
if ( isset( $_GET[ 'w' ] && $_GET[ 'w' ] == 1 )
{
$param_n = (int) $_GET['w'];
?>
<script type="text/javascript">
 function newWin( _param )
{
  if ( parseInt(_param) == 1 )
  {
	window.open(....);
  }
}

newWin( <?= $param_n ?> );
</script>
<?
}
?>



And then song name

w=1 means param = 1, MEANS run the function IF statement ( new window with your config )

Hope this somehow helps.

This post has been edited by Fratyr: 10 November 2009 - 02:03 AM

Was This Post Helpful? 0
  • +
  • -

#3 Gorian  Icon User is offline

  • ninja DIC
  • member icon

Reputation: 120
  • View blog
  • Posts: 1,681
  • Joined: 28-June 08

Re: Is this even possible?

Posted 09 November 2009 - 03:31 PM

umm...

:code:
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1