-
-
Save Nor1m/db3181748df65bd746a9fe0ca0f217be to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// если пост на стене группы | |
if ( strpos( $this -> link , '-') !== false ) { | |
$this -> owner_id = '-' . explode ( '-', explode('_', $this -> link)[0] )[1]; | |
$this -> item_id = explode( '_', $this -> link )[1]; | |
} | |
// если пост на стене юзера | |
else { | |
$this -> owner_id = explode ( '_', explode('wall', $this -> link)[1] )[0]; | |
$this -> item_id = explode ( '_', explode('wall', $this -> link)[1] )[1]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment