CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion »
  • APIs and Hooks (Moderator: Donald Lobo) »
  • Rebuilding menus inside PHP
Pages: [1]

Author Topic: Rebuilding menus inside PHP  (Read 738 times)

SarahG (FountainTribe)

  • Ask me questions
  • ****
  • Posts: 782
  • Karma: 29
  • CiviCRM version: 4.4.7
  • CMS version: Drupal 6, Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.3
Rebuilding menus inside PHP
April 19, 2012, 08:21:26 pm
I would like to do the equivilent of the URL "/index.php?q=civicrm/menu/rebuild&reset=1"  from inside a PHP script. Which API/function should be called?

Did I help you? Please donate to the Civi-Make-It-Happen campaign  CiviCRM for mobile devices! 

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Rebuilding menus inside PHP
April 20, 2012, 12:29:57 am
Don't think there is now.

You could look at the code and wrap it into an API?

In general, we are going to work on exposing more of the config/admin options to the API. Could you contribute (time/code/money/use cases)?

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

demeritcowboy

  • Ask me questions
  • ****
  • Posts: 570
  • Karma: 42
  • CiviCRM version: Always the latest!
  • CMS version: Drupal 6 mostly, still evaluating 7.
  • MySQL version: Mix of 5.0 / 5.1 / 5.5
  • PHP version: 5.3, usually on Windows
Re: Rebuilding menus inside PHP
April 20, 2012, 08:38:49 am
Might not be an api, but take a look at CRM_Core_Invoke::invoke()

SarahG (FountainTribe)

  • Ask me questions
  • ****
  • Posts: 782
  • Karma: 29
  • CiviCRM version: 4.4.7
  • CMS version: Drupal 6, Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.3
Re: Rebuilding menus inside PHP
April 29, 2012, 08:34:13 pm
Thanks for the help - The code within CRM_Core_Invoke::invoke() showed the appropriate functions to call.
Did I help you? Please donate to the Civi-Make-It-Happen campaign  CiviCRM for mobile devices! 

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion »
  • APIs and Hooks (Moderator: Donald Lobo) »
  • Rebuilding menus inside PHP

This forum was archived on 2017-11-26.