Include if (??display:"block"??) is true
Posted: Tue Mar 08, 2011 12:06 pm
Hi,
I have an for me tricky situation. I have a fairly large file that is positioned inside a div that is hidden by css due to display: "none". Then I have a javascript that changes display: "none" to display:"block". The javascript is working fine, but I would like this large page to only load when somebody clicks to execute the the javascript and makes the nested1 div visible.
I like to include another page only when the CSS item #nested1 have display: "block"; and not if it has the value display: "none";
Is ther a way to let a PHP script get the display information from the item #nested1 in the css file and only include LargePage.php when the value is set to block.
<div id="nested1"> </div>
<?php
here we like to extract som data from #nested1 located in iBoxar.CSS :
if (condition )
include('LargePage.php'); ?>
</div>
An bonus would be to ad an else if, that includes the large page if everyting else is loaded.
Many thanks
Jakob
I have an for me tricky situation. I have a fairly large file that is positioned inside a div that is hidden by css due to display: "none". Then I have a javascript that changes display: "none" to display:"block". The javascript is working fine, but I would like this large page to only load when somebody clicks to execute the the javascript and makes the nested1 div visible.
I like to include another page only when the CSS item #nested1 have display: "block"; and not if it has the value display: "none";
Is ther a way to let a PHP script get the display information from the item #nested1 in the css file and only include LargePage.php when the value is set to block.
<div id="nested1"> </div>
<?php
if (condition )
include('LargePage.php'); ?>
</div>
An bonus would be to ad an else if, that includes the large page if everyting else is loaded.
Many thanks
Jakob