You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
448 B

  1. <?php /* -*- php -*- */
  2. function fulcrm_apiv2_install() {
  3. try {
  4. $url = $GLOBALS[ 'base_url' ];
  5. $url = parse_url( $url, PHP_URL_HOST );
  6. $url = explode( '.', $url );
  7. $url = array_reverse( $url );
  8. } catch ( Exception $e ) {
  9. $url = array();
  10. }
  11. $url[] = fulcrm_uuid_uuid4();
  12. $url = array_reverse( $url );
  13. $url = implode( '.', $url );
  14. variable_set( 'fulcrm_apiv2_client_id', $url );
  15. }