We have all been exposed to this mess. Just create a bunch of menus and menu items (using devel_generate), then add these menus as available for a content type, and finally try to either edit an existing piece of content, or create a new. Switch to the "Menu settings" vertical tab and check the "Provide a menu link" checkbox.

...here's what the "Parent item" and "Weight" drop-down menus look like:


We can do better than that! Here's a couple of Drupal contributed modules that try to address this problem:
https://www.drupal.org/project/menu_select
Replaces Drupal's stock node parent menu item selector with a hierarchal collapsible unordered list. Offers a breadcrumb preview of the menu item's location and an optional autocomplete search.

https://www.drupal.org/project/menuux
...adds a menu browser to the content forms. Users don't choose "parent" and "weight" for the menu item they are adding. Instead they choose a menu, and the menu gets loaded using ajax. The users then places the menu item inside the menu by clicking on the item they want to place the menu below.

https://www.drupal.org/project/menu_link_weight
...replaces the standard numeric weight dropdown widget for menu links in the node form with a tabledrag widget that lists all children for the selected parent.

https://www.drupal.org/project/bettermenus (never realized as an actual module)
Improves the Drupal menu item creation workflow by replacing the standard menu creating widget with a javascript powered tree menu.

Recent comments
Thanks Alejandro. That was the clues I needed.
Ubercart - Programmatically add product to cart and straight to Checkout
Have you tried uc_cart_add_item()? You need to provide the nid of the product. Then you can use backdrop_goto('cart/checkout'); to send the user to the checkout screen. uc_cart_add_item...
Ubercart - Programmatically add product to cart and straight to Checkout
No problem, let's see how it evolves. I'd be happy to provide a suggested version if i could. I will keep that in mind and try learn this hook chain hopefully very soon. I will...
File hashing uploads made through TinyMCE