Bring Your Business to Life › Support › Image Store › Hook To Modify Customer Registration Form?
- AuthorPosts
- March 20, 2014 at 3:23 pm #57130jcharrisParticipant
I see there is a hook to add new customer fields to the database. Good!
However, is there a hook to also modify the existing customer-edit.php form that I’m not seeing (ie. add input fields to the form?) OR is there a hook to -replace- customer-edit.php with my own form and not break the core code?
TIA,
—JC
March 22, 2014 at 2:06 pm #57149Xpark MediaKeymasteryou can add additional values using the ims_cutomer_data_row hook.
if you want to complete rewrite the form use ims_include_{file_name}
March 24, 2014 at 12:37 pm #59142jcharrisParticipantThanks.
Now…. I’m coming from Drupal where hooks are quite different. Can you -please- pretty please flesh out your example for “use ims_include_{file_name}”
I’m clearly not getting how one passes the dir and filename parameters. The doc doesn’t seem to be a working example, is it?
TIA,
—JC
March 31, 2014 at 9:48 pm #70223Xpark MediaKeymasterNo, is not a working example, try this. Change the path to the full path of your file.
function ims_change_customer_edit_file( $file, $dir ) { return "full/path/to/new/file.php"; } add_filter('ims_include_customer-edit', 'ims_change_customer_edit_file', 10, 2);
- AuthorPosts
- You must be logged in to reply to this topic.