PHP Code confusion

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
togotutor
Forum Newbie
Posts: 2
Joined: Sat Nov 06, 2010 1:33 am

PHP Code confusion

Post by togotutor »

Team,
I have this current code in my website.

public function showLeaderboard($action)
{
$action->element('img',
array('width' => 720,

'height' => 90,
'src' => common_path('plugins/BlankAd/redpixel.png')),
'');
}


Instead of the image --> 'redpixel.png' I want to add an html file. But It`s not happening. Please let me know how is it going to be posssible.
User avatar
twinedev
Forum Regular
Posts: 984
Joined: Tue Sep 28, 2010 11:41 am
Location: Columbus, Ohio

Re: PHP Code confusion

Post by twinedev »

Well since we have no idea how this code is being used, all I can do is offer the suggestion to :

Code: Select all

public function showLeaderboard($action)
{
    $action->element('iframe',
                     array('width' => 720,
                           'height' => 90,
                           'src' => 'http://www.cnn.com'
                          ),
                     ''
                    );
}
Again this is just guessing that what ever is using this function can handle it (kinda like saying, "my GPS says to turn left on step 10 of 20 directions to get to point A, but which way do i turn in step 10 to get to point B")
togotutor
Forum Newbie
Posts: 2
Joined: Sat Nov 06, 2010 1:33 am

Re: PHP Code confusion

Post by togotutor »

Thanks and Appreciated!!! ...Is there any alternate of iframe. As iframe is looking wiered when i put addinto it.
Post Reply