function drupal_clone
6.x common.inc | drupal_clone($object) |
Provide a substitute clone() function for PHP4.
5 calls to drupal_clone()
- node_load in drupal-6.x/
modules/ node/ node.module - Load a node object from the database.
- node_preview in drupal-6.x/
modules/ node/ node.pages.inc - Generate a node preview.
- node_unpublish_by_keyword_action in drupal-6.x/
modules/ node/ node.module - Implementation of a configurable Drupal action. Unpublish a node if it contains a certain string.
- theme_node_preview in drupal-6.x/
modules/ node/ node.pages.inc - Display a node preview for display during node creation and editing.
- _system_theme_data in drupal-6.x/
modules/ system/ system.module - Helper function to scan and collect theme .info data and their engines.
File
- drupal-6.x/
includes/ common.inc, line 1779 - Common functions that many Drupal modules will need to reference.
Code
function drupal_clone($object) {
return version_compare(phpversion(), '5.0') < 0 ? $object : clone($object);
}