WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )
apply_filters( "hook_name", "what_to_filter" )
.Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
Line | Code |
---|---|
502 |
|
503 | $this->blogs[$importing_blog]['comments_start_index'] = (int) $q['start-index']; |
504 | $this->save_vars(); |
505 | } while ( !empty( $query ) && $this->have_time() ); |
506 | } |
507 | $this->blogs[$importing_blog]['mode'] = 'authors'; |
508 | $this->save_vars(); |
509 | if ( !$this->blogs[$importing_blog]['posts_done'] && !$this->blogs[$importing_blog]['comments_done'] ) |
510 | die('nothing'); |
511 | do_action('import_done', 'blogger'); |
512 | die('done'); |
513 | } |
514 |
|
515 | function convert_date( $date ) { |
516 | preg_match('#([0-9]{4})-([0-9]{2})-([0-9]{2})T([0-9]{2}):([0-9]{2}):([0-9]{2})(?:\.[0-9]+)?(Z|[\+|\-][0-9]{2,4}){0,1}#', $date, $date_bits); |
517 | $offset = iso8601_timezone_to_offset( $date_bits[7] ); |
518 | $timestamp = gmmktime($date_bits[4], $date_bits[5], $date_bits[6], $date_bits[2], $date_bits[3], $date_bits[1]); |
519 | $timestamp -= $offset; // Convert from Blogger local time to GMT |
520 | $timestamp += get_option('gmt_offset') * 3600; // Convert from GMT to WP local time |