VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: kratzi on May 23, 2014, 15:34:16 PM

Title: editaddresscheckoutBT view
Post by: kratzi on May 23, 2014, 15:34:16 PM
Hi,

I need to make changes to the site when the editaddresscheckoutBT layout is active.

Usually I change the style for views with this command:

<?php if (JRequest::getVar('view')=='cart') { ?>

<style type="text/css">


div#123 {}
</style>

<?php
}
?>


However "editaddresschekout" does not seem to be a view. Does one of you know what the correct definiton is to define this "view".


Thank you

kratzi
Title: Re: editaddresscheckoutBT view
Post by: GJC Web Design on May 23, 2014, 18:58:58 PM
I normally just add them inline in the actual view template e.g.   

components/com_virtuemart/views/user/tmpl/edit_address_userfields.php  (over ride of course)

or detect the task

<?php if ((JRequest::getVar('task')=='editaddresscart')&&(JRequest::getVar('view')=='user')) { ?>

etc
Title: Re: editaddresscheckoutBT view
Post by: kratzi on May 23, 2014, 20:10:47 PM
Hey that is great. Exactly what I thought about. Thumb up for you!

Just one correction: the task must be editaddresscheckout
<?php if ((JRequest::getVar('task')=='editaddresscheckout')&&(JRequest::getVar('view')=='user')) { ?>


Regards

kratzi



Title: Re: editaddresscheckoutBT view
Post by: kratzi on June 12, 2014, 17:38:37 PM
Hi

could you please help me out with one more task.

I am using this in edit.php

<?php if ((JRequest::getVar('task')=='editaddress')&&(JRequest::getVar('view')=='user')&&(JRequest::getVar('addrtype')=='ST')) { ?>

edit.php is the file when customers go to their profile (not from cart)

This code does not work unfortunately. However  the following works fine in edit_address.php (when coming from cart)

<?php if ((JRequest::getVar('task')=='editaddresscart')&&(JRequest::getVar('view')=='user')&&(JRequest::getVar('addrtype')=='ST')) { ?>

I would appreciate to know how to solve this.

Thank you

kratzi