News:

Looking for documentation? Take a look on our wiki

Main Menu

No Link to Terms of Services

Started by freeme, January 28, 2012, 18:19:18 PM

Previous topic - Next topic

freeme

Joomla 1.7.3.
VM 2.0

On the checkout page, there is a checkbox for the Terms of Service and also saying "Please read and accept the terms of service."

But there is no link to a popup with the Terms of Service.

Is this a VM 2.0 bug, or a feature, I have to switch somewhere on?

Milbo

The TOS is directly shown above. The 2.0.1 version has also a vendor view for the tos.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

freeme

Please see screenshot: there is the checkbox with text "Please read and agree to the terms of service" but there is no link to the terms...

TOS are defined in the backend, I did it under "Shop / Seller / Terms of Service"

[attachment cleanup by admin]

Milbo

Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

freeme

Following conditions:

Testsite at my webhoster: Joomla 1.7.3, VM 2.0.1:
Tested with template Beez, Atomic and Rockettheme Momentum;

Testsite locally on XAMPP: Joomla 2.5, VM 2.0.1:
Tested with template Beez, Atomic and Joomlashack Scenica;

RESULTS: under all conditions, link to TOS was not shown. So I don´t think its template related.

It must be something with VM?!?

fmp.martins

I have the same problem.
Plus, in the admin should be a link to an article instead of writing it there.

jenkinhill

Using unedited VM2.0.1 on a test site the TOS is shown on the checkout page. If your requirement is for a link you could edit the view, components/com_virtuemart/views/cart/tmpl/default.php  (use template override).

The current code is <?php echo JText::_('COM_VIRTUEMART_CART_TOS'); ?>

[attachment cleanup by admin]
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

freeme

Quote from: jenkinhill on January 29, 2012, 13:37:42 PM
Using unedited VM2.0.1 on a test site the TOS is shown on the checkout page. If your requirement is for a link you could edit the view, components/com_virtuemart/views/cart/tmpl/default.php  (use template override).

The current code is <?php echo JText::_('COM_VIRTUEMART_CART_TOS'); ?>
p
Thx for the hint Kelvin. Will go for that probably. But seems i am not the only one with that issue. So lets See what Can be found out furthermore. on both of my testsites i havent installed so much yet and also didnt change any code in VM css or php.

dnlvsci

I made IT! (Note -> VM 2.0.1)

Here is my solution:
Insert the following code under the // vmdebug('cart',$this->cart); (line 24)
1.
$url = JRoute::_('index.php?option=com_virtuemart&view=vendor&layout=tos&virtuemart_vendor_id=' . $this->cart->vendor->virtuemart_vendor_id.'&tmpl=component');
$document = &JFactory::getDocument();
$document->addScriptDeclaration("
   jQuery(document).ready(function($) {
      $('a.tos').click( function(){
         $.facebox({
            iframe: '".$url."',
            rev: 'iframe|550|550'
         });
         return false ;
      });
   });
");

2.
Replace this code <?php echo $this->cart->vendor->vendor_terms_of_service;?>
to <a class="tos" href="<?php echo $url ?>" ><?php echo JText::_('COM_VIRTUEMART_CART_TOS') ?></a>

You are finished :)

Now the TOS will open popup box like "ask a question". You can make some css style for the link and you get shomething like the attachment :)

[attachment cleanup by admin]

Milbo

Nice, we also just add similar to the core :-)
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Studio 42

I have do it so

JHTML::script('facebox.js', 'components/com_virtuemart/assets/js/', false);
JHTML::stylesheet('facebox.css', 'components/com_virtuemart/assets/css/', false);

JHtml::_('behavior.formvalidation');
$document = &JFactory::getDocument();
$document->addScriptDeclaration("
   jQuery(document).ready(function($) {
      $('div#full-tos').hide();
      $('span.terms-of-service').click( function(){
         //$.facebox({ span: '#full-tos' });
         $.facebox( { div: '#full-tos' }, 'my-groovy-style');
      });
   });
");
$document->addStyleDeclaration('#facebox .content {display: block !important; height: 480px !important; overflow: auto; width: 560px !important; }');

and added
<div id="full-tos">
            <h2><?php echo JText::_('COM_VIRTUEMART_CART_TOS'); ?></h2>

to have only the tos TEXT and TITLE in modal box

freeme

#11
Joomla 2.5.1
VM 2.0.2


Hi to all,
as far as I understood, that was a bug in VM2.0.1 (as the Terms of Services were shown up in the previous VM1.x) and it will be added in the next stable version. So I waited for VM 2.0.2 stable, which was just released, but I still have the same issue: the text "agree to the Terms..." is shown, but not a link to the Terms of Services ot the TOS itself at all, so the customer would have to agree to something, which he couldn´t verify.

Before I am now integrating the extra code manually as described as above (thx again :) - am I really the only one, where the Terms are not shown, or is this really a general bug, which will be fixed in one of the next releases?

I want to avoid to add adding extra codes as much as possible - otherwise every upgrade of VM will get a pain in the neck, when I need to recap what/how/when I changed....

Thx!

lipes

We also dont have the Link to Terms & Conditions of Service in The Main/Principal Registration Page ....

You could see here that we dont have this here:
http://virtuemart.cloudaccess.net/my-account

And could be done something like this :
https://demo.cubecart.com/cc5/index.php?seo_path=register&PHPSESSID=39de577a71394939024d87451efcb0db

(but in a popup... or opening a slide down jquery area .. with the full text, dont you agree?)
VM V. online: J2.5.14 | VM 2.0.20a | SQL 5.1.70 | PHP 5.3.25

freeme

Is it possible that it is somehow related to a Java conflict? Often it is related to the template, as Milbo said. But I already tested it with the standard Joomla template.

If I am right, than in order to localize the problem, I would have to deactivate every plugin and then reload the checkout page of VM - right? Which is not a funny job, as it will take some time to do it with all plugins... :( 

Would there be any other way to check? Cheers.

freeme

Quote from: dnlvsci on January 31, 2012, 14:29:36 PM
I made IT! (Note -> VM 2.0.1)

Here is my solution:
Insert the following code under the // vmdebug('cart',$this->cart); (line 24)
1.
$url = JRoute::_('index.php?option=com_virtuemart&view=vendor&layout=tos&virtuemart_vendor_id=' . $this->cart->vendor->virtuemart_vendor_id.'&tmpl=component');
$document = &JFactory::getDocument();
$document->addScriptDeclaration("
   jQuery(document).ready(function($) {
      $('a.tos').click( function(){
         $.facebox({
            iframe: '".$url."',
            rev: 'iframe|550|550'
         });
         return false ;
      });
   });
");

2.
Replace this code <?php echo $this->cart->vendor->vendor_terms_of_service;?>
to <a class="tos" href="<?php echo $url ?>" ><?php echo JText::_('COM_VIRTUEMART_CART_TOS') ?></a>

You are finished :)

Now the TOS will open popup box like "ask a question". You can make some css style for the link and you get shomething like the attachment :)

Hi,
I tried your solution now and added the code below line 37 (in VM2.0.2) and added the line. No change. I am really desperate now. The site is still not live and still some stuff to do, but I dont want launch it with the full TOS text shown on the checkout site (this works). It must be in a pop up window.

I am sure it works somehow, but dont know where else to look/search for... :(