Download the PHP package steve-erdelyi/hubspot-user-php without Composer

On this page you can find all versions of the php package steve-erdelyi/hubspot-user-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package hubspot-user-php

hubspot-user-php

This package allows you to seamlessly integrate with user data stored in Hubspot CRM. You can easily access user data via PHP or JavaScript with some minor additional setup.

Before You Get Started

You will need a Hubspot API key in order to use this package. If you don't already have an API key, you can learn how to generate one here.

Installation

This package can be installed using composer: composer require steve-erdelyi/hubspot-user-php

Quick Start

To use this package, the first thing you need to do is ensure you have already required the autoload file in your PHP template file: require 'PATH_TO_YOUR_INSTALLATION/vendor/autoload.php';

Next, tell PHP to use the class namespace: use HubspotUser/HubspotUser;

And finally, initialize the HubspotUser class and access a variable: $hubspot_user = new HubspotUser('YOUR_HUBSPOT_API_KEY'); $first_name = $hubspot_user->name->first; $last_name = $hubspot_user->name->last; $full_name = $hubspot_user->name->full; $email = $hubspot_user->email;

Use User Variables via JavaScript

You might want to access these variables from JavaScript so you can easily perform client-side personalizations. In order to use variables via JavaScript, you must output the HubspotUser data to the page by adding the following line somewhere inside your page's <head> tag: <?= $hubspot_user->output(); ?>

After adding the output function inside your <head> tag, you can simply call the variables globally via JavaScript: let first_name = hubspot_user.name.first; let last_name = hubspot_user.name.last; let full_name = hubspot_user.name.full; let email = hubspot_user.email;

Changing Your Hubspot UTK Cookie Name

By default, this package relies on the standard Hubspot UTK cookie name hubspotutk. If you need to override the cookie name used to find your Hubpot UTK, you can simply pass a string variable containing your custom name as the second parameter when initializing your class: $hubspot_user = new HubspotUser('YOUR_HUBSPOT_API_KEY', 'YOUR_CUSTOM_UTK_COOKIE_NAME');


All versions of hubspot-user-php with dependencies

PHP Build Version
Package Version
Requires php-curl-class/php-curl-class Version ^9.17
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package steve-erdelyi/hubspot-user-php contains the following files

Loading the files please wait ...