News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Move "register" and "cancel" buttons to bottom of registration page

Started by gringo211985, August 19, 2015, 17:24:44 PM

Previous topic - Next topic

gringo211985

Hi there,

I'm wanting to move my "register" and "cancel" buttons from the top right of the VM registration form to the bottom of the VM registration form.

I have found a few old threads and they mentioned editing the following php /views/user/tmpl/edit.php and edit_address.php but both seem to do nothing when I change them. I tried both override and direct overwrite in /components

Could someone please point me in the direction of the file that I need to edit in order to achieve this?

Thanks,
Richard

VM 3.0.9
Joomla 3.4.3

ak1lon

I know this is an old thread but the solution is to edit the edit_shopper file. Just copy the code of the buttons to the bottom, make the proper adjustments, and you are done.
:)

GJC Web Design

GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

ch1vph

<?php
/**
 *
 * Modify user form view, User info
 *
 * @package VirtueMart
 * @subpackage User
 * @author Oscar van Eijk
 * @link ${PHING.VM.MAINTAINERURL}
 * @copyright Copyright (c) 2004 - 2010 VirtueMart Team. All rights reserved.
 * @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.php
 * VirtueMart is free software. This version may have been modified pursuant
 * to the GNU General Public License, and as distributed it includes or
 * is derivative of works licensed under the GNU General Public License or
 * other free or open source software licenses.
 * @version $Id: edit_shopper.php 9413 2017-01-04 17:20:58Z Milbo $
 */

// Check to ensure this file is included in Joomla!
defined('_JEXEC') or die('Restricted access');

if(!
$this->userDetails->user_is_vendor){ ?>

<div class="buttonBar-right">
<button class="button" type="submit" onclick="javascript:return myValidator(userForm, true);" ><?php echo $this->button_lbl ?></button>
&nbsp;
<button class="button" type="reset" onclick="window.location.href='<?php echo JRoute::_('index.php?option=com_virtuemart&view=user'FALSE); ?>'" ><?php echo vmText::_('COM_VIRTUEMART_CANCEL'); ?></button>
</div>

<?php }
if( 
$this->userDetails->virtuemart_user_id!=0) {
    echo 
$this->loadTemplate('vmshopper');
}

echo 
$this->loadTemplate('address_userfields');

if (
$this->userDetails->JUser->get('id') ) {
  echo 
$this->loadTemplate('address_addshipto');
}

if(!empty(
$this->virtuemart_userinfo_id)){
echo '<input type="hidden" name="virtuemart_userinfo_id" value="'.(int)$this->virtuemart_userinfo_id.'" />';
}
?>

<input type="hidden" name="task" value="saveUser" />
<input type="hidden" name="address_type" value="<?php echo $this->address_type?>"/>

<div class="buttonBar-right">
<button class="button" type="submit" onclick="javascript:return myValidator(userForm, true);" ><?php echo $this->button_lbl ?></button>
&nbsp;
<button class="button" type="reset" onclick="window.location.href='<?php echo JRoute::_('index.php?option=com_virtuemart&view=user'FALSE); ?>'" ><?php echo vmText::_('COM_VIRTUEMART_CANCEL'); ?></button>
</div>