Advertisement
Guest User

Untitled

a guest
Jun 27th, 2013
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.17 KB | None | 0 0
  1. <!DOCTYPE HTML>
  2. <html>
  3. <head>
  4. <title>PHP function availability check</title>
  5. <link href="style.css" rel="stylesheet" type="text/css">
  6. <link rel="stylesheet" href="colorbox.css" />
  7. <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
  8. <script src="jquery.colorbox.js"></script>
  9. <script>
  10. $(document).ready(function(){
  11. $(".iframe").colorbox({iframe:true, width:"80%", height:"80%"}); // My work
  12. });
  13. </script>
  14. </head>
  15. <body>
  16. <?php
  17. error_reporting(E_ALL);
  18. include_once('simple_html_dom.php');
  19. $html = file_get_html('http://php.net/quickref.php');
  20.  
  21. $arr = array();
  22. $prevLabel = null;
  23. foreach($html->find('#quickref_functions') as $element)
  24. {
  25. foreach($element->find('a') as $element1)
  26. {
  27. $currLabel = strtoupper(substr($element1->plaintext, 0, 1));
  28. if( $currLabel !== $prevLabel )
  29. {
  30. echo "<div style='border:1px solid red;margin:10px 0;'>";
  31. echo $currLabel;
  32. echo '</div>';
  33. $prevLabel = $currLabel;
  34. }
  35. echo "<span class='phpfun'>";
  36. echo "<a class='iframe' href='http://php.net".$element1->href."'>", $element1->plaintext,"</a>";
  37. echo '</span>';
  38. }
  39. }
  40.  
  41. ?>
  42. </body>
  43. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement