Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



Reply
display: inline-block;, overflow: hidden; in Iframe not working
Old 08-30-2010, 10:27 PM display: inline-block;, overflow: hidden; in Iframe not working
Sleeping Troll's Avatar
Ultra Talker

Posts: 351
Name: Butch Begy
Trades: 0
Here is the php file:

PHP Code:
<?php
$type
=$_REQUEST["Type"];
$term=$_REQUEST["Term"];
$count=$_REQUEST["Count"];
$menu=$_REQUEST["Menu"];
$ch curl_init(); 
$timeout 0// set to zero for no timeout 
curl_setopt ($chCURLOPT_URL"http://api.bing.net/json.aspx?AppId=F8DA6024CF&Market=en-US&Query=".$term."&Sources=".$type."&".$type.".Count=".$count."&JsonType=raw");
curl_setopt ($chCURLOPT_RETURNTRANSFER1); 
curl_setopt ($chCURLOPT_CONNECTTIMEOUT$timeout); 
$search curl_exec($ch); 
curl_close($ch);
$Response json_decode($search,true);
if (
$term == "")$term "Top News Stories";
$term str_replace("site:","",$term);  
$term explode("."$term);
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
     <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta http-equiv="X-UA-Compatible" content="IE=8" />
    <link href = "style.css" rel = "stylesheet" type = "text/css">
    <script type = 'text/javascript' src = '../scriptaculous/lib/prototype.js'></script>
    <script type = 'text/javascript' src = '../scriptaculous/src/scriptaculous.js'></script>
</head>
<body>
<div id = "container">
<div id = "text1">
<?php
foreach($Response['SearchResponse'][$type]['Results'] as $item)
{
    echo(
"
    <div onmouseover = \"clearInterval(Scroll)\" onmouseout = \"clearInterval(Scroll); Scroll = setInterval ('scroll()', 50)\">        
        <div class = 'Source' style='color:green'><b>
$term[0]</b></div>
        <div class = 'Title'><b><a href='
$item[Url]' target='_blank' style='color:yellow'></b>$item[Title]</b></a></div>
        <div class = 'Description' style='color:#cccccc'>
$item[Snippet]</div>
        <br>
    </div>
        "
);
}
?>
</div>
<div id = "text2">
<?php
foreach($Response['SearchResponse'][$type]['Results'] as $item)
{
    echo(
"
    <div onmouseover = \"clearInterval(Scroll)\" onmouseout = \"clearInterval(Scroll); Scroll = setInterval ('scroll()', 50)\">        
        <div class = 'Source' style='color:green'><b>
$term[0]</b></div>
        <div class='Title'><b><a href = '
$item[Url]' target='_blank' style='color:yellow'></b>$item[Title]</b></a></div>
        <div class='Description' style='color:#cccccc'>
$item[Snippet]</div>
        <br>
    </div>
        "
);
}    
?>
</div>
</div>
<?php
if(file_exists("$menu"))
{
    echo(
"
        <div id = 'menu'>"
.file_get_contents($menu)."</div>
    "
);
}
?>
<script type = "text/javascript">
$("container").style.height = document.viewport.getHeight() - 30 + 'px';
$("container").style.width = document.viewport.getWidth() + 'px';
$('text1').style.top = 0 + 'px';
$('text2').style.top = $('text1').getHeight() + 'px';
var Scroll = setInterval ("scroll()", 50);
function scroll()
{
        if (parseInt($('text1').style.top) <= 0)
        {
            $('text2').style.top = parseInt($('text1').style.top) + $('text1').getHeight() + 'px';
        }
        if (parseInt($('text2').style.top) <= 0)
        {
            $('text1').style.top = parseInt($('text2').style.top) + $('text2').getHeight() + 'px';
        }
        $('text1').style.top = parseInt($('text1').style.top) - 1 +'px';    
        $('text2').style.top = parseInt($('text2').style.top) - 1 +'px';            
}
</script>
And here is the style sheet:
Code:
* 
{
   padding:0;
   margin:0;
}

body 
{
    background-color: transparent;
    color: #ffffff;
    overflow: hidden;
}

#container
{
    overflow: hidden;
}

#menu .ul .li
{
    display: inline-block;
    height: 30px;
    text-align: center;
    background-color: transparent;
}

#text1
{
    position: absolute;
    text-align: left;
    background-color: transparent;
}

#text2
{
    position: absolute;
    text-align: left;
    background-color: transparent;
}
Http://ticktach.com/

Click on the loudspeaker (News)

This url will load page in a browser window instead of an iframe, same problem...

http://ticktach.biz/news/index.php?T...&Menu=menu.txt

I am at a loss and just spinning my wheels at this point, Help greatly appreciated.
__________________
Sleeping Troll, EMUSE, Mind Expansion...Truly serendipity!

Last edited by Sleeping Troll; 08-31-2010 at 01:22 AM..
Sleeping Troll is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Reply     « Reply to display: inline-block;, overflow: hidden; in Iframe not working
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.77971 seconds with 12 queries