Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: flash_uploader

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
1353      global $type, $tab;
1354
1355      $flash_action_url = admin_url('async-upload.php');
1356
1357      // If Mac and mod_security, no Flash. :(
1358      $flash = true;
1359      if ( false !== strpos(strtolower($_SERVER['HTTP_USER_AGENT']), 'mac') && apache_mod_loaded('mod_security') )
1360           $flash = false;
1361
1362      $flash = apply_filters('flash_uploader', $flash);
1363      $post_id = isset($_REQUEST['post_id']) ? intval($_REQUEST['post_id']) : 0;
1364
1365 ?>
1366 <script type="text/javascript">
1367 //<![CDATA[
1368 var uploaderMode = 0;
1369 jQuery(document).ready(function($){
1370      uploaderMode = getUserSetting('uploader');
1371      $('.upload-html-bypass a').click(function(){deleteUserSetting('uploader');uploaderMode=0;swfuploadPreLoad();return false;});