Function __global->has_js

Definitions

sources/global3.php

  • Determine whether the user's browser supports JavaScript or not.Unfortunately this function will only return true once a user has been to the site more than once... JavaScript will set a cookie, indicating it works.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: bool

Returns

  • Whether the user has definitely got JavaScript
  • Type: boolean
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Determine whether the user's browser supports JavaScript or not.Unfortunately this function will only return true once a user has been to the site more than once... JavaScript will set a cookie, indicating it works.
 *
 * @return boolean Whether the user has definitely got JavaScript
 */

function has_js() : bool