We understand that your ecommerce site is crucial to the success of your business, from time to time issues and questions can arise and you need to have the assurance there will be someone on hand to help resolve these in a timely fashion so you can spend your time driving your own business forward.

So if you are looking for faster responses to your questions or would like the assurance there is someone on hand for you to contact, fear not we have a number of paid support options that are available to you that can give your organisation the peace of mind knowing a member from the Cart Viper team will always be available to assist!

Purchase a Support Plan

Community Support

HomeHomeIssues and Supp...Issues and Supp...Installation & ...Installation & ...cart contact info populationcart contact info population
Previous
 
Next
New Post
12/11/2014 4:24 PM
 

Is there a way to prevent the cart from populating with contact information from previous order or DNN profile?

I have a customer who wants a site where they will have one login for several customers that will be in different location, and they want the contact info to be blank at each checkout.

 
New Post
12/12/2014 11:22 AM
 

Hi Donald,

As you point out we initially look to see if a user has placed an order and populate the billing address based upon that, if we cant find a previous order we will fall back to the DNN user profile information (if they are logged in). As your going to using the same DNN account we will always grab the previous order.

Without making a code change the only way I could see todo this is if you modify SinglePageCheckout.ascx and add in some jQuery to clear the billing address fields so it will always appear empty when the page loads.

Regards
Nigel.

 
New Post
12/15/2014 3:31 PM
 

Thank you. I added this code to SinglePageCheckout.ascx

        <script type="text/javascript">  
    $.fn.clearForm = function() {
      return this.each(function() {
        var type = this.type, tag = this.tagName.toLowerCase();
        if (tag == 'form')
          return $(':input',this).clearForm();
        if (type == 'text' || type == 'password' || tag == 'textarea')
          this.value = '';
        else if (type == 'checkbox' || type == 'radio')
          this.checked = false;
        else if (tag == 'select')
          this.selectedIndex = -1;
      });
    };
$(':input').clearForm()
</script>

And that seems to work. However, when I create a file SinglePageCheckout.Portal-52.ascx to apply this change to only this store, then it stops working. Any idea how I can apply this change to only this store, and not all the others in the same DNN?

Thanks!
 

 

 
New Post
12/15/2014 10:51 PM
 

Hi,

We cant switch out ascx files on a portal by portal basic using that naming convention, however using the below property you should be able to get the current portal ID. So you can add in an if statement to your function so it only executes your code on portal 52:

<%= PortalId %>

Regards

 
New Post
12/16/2014 10:00 PM
 

Thank you!

In the unlikely event that someone else is trying to do the same thing, this is the code that seems to be working for me:

 

<script type="text/javascript">
function DoSomething() {
    $.fn.clearForm = function() {
      return this.each(function() {
        var type = this.type, tag = this.tagName.toLowerCase();
        if (tag == 'form')
          return $(':input',this).clearForm();
        if (type == 'text' || type == 'password' || tag == 'textarea')
          this.value = '';
        else if (type == 'checkbox' || type == 'radio')
          this.checked = false;
        else if (tag == 'select')
          this.selectedIndex = -1;
      });
    };
$(':input').clearForm();
}
</script>

<% if (PortalId == 52)
           {
               Page.ClientScript.RegisterStartupScript(this.GetType(), "viper", "DoSomething()", true);
           }
 %>

 
Previous
 
Next
HomeHomeIssues and Supp...Issues and Supp...Installation & ...Installation & ...cart contact info populationcart contact info population


 

We use cookies on our website to improve our service to you, by continuing you agree to our use of cookies. However you are able to update your settings at any time.

Cookie Policy

A cookie, also known as an HTTP cookie, web cookie, or browser cookie, is a piece of data stored by a website within a browser, and then subsequently sent back to the same website by the browser. Cookies were designed to be a reliable mechanism for websites to remember things that a browser had done there in the past, which can include having clicked particular buttons, logging in, or having read pages on that site months or years ago.

Strictly Necessary Cookies

These cookies cannot be disabled

These cookies are necessary for the website to function and cannot be switched off. They are normally set in response to your interactions on the website e.g. logging in etc.

Cookies:
  • .ASPXANONYMOUS
  • .DOTNETNUKE
  • __RequestVerificationToken
  • authentication
  • CV_Portal
  • CV_Store_Portal_Cart_0
  • CV_USER
  • dnn_IsMobile
  • language
  • LastPageId
  • NADevGDPRCookieConsent_portal_0
  • userBrowsingCookie

Performance Cookies

These cookies allow us to monitor traffic to our website so we can improve the performance and content of our site. They help us to know which pages are the most and least popular and see how visitors move around the site. All information these cookies collect is aggregated and therefore anonymous. If you do not allow these cookies we will not know when you have visited or how you navigated around our website.

Cookies:
  • _ga
  • _gat
  • _gid

Functional Cookies

These cookies enable the website to provide enhanced functionality and content. They may be set by the website or by third party providers whose services we have added to our pages. If you do not allow these cookies then some or all of these services may not function properly.

Cookies:

Currently we are not utilizing these types of cookies on our site.

Targeting Cookies

These cookies may be set through our site by our advertising partners. They may be used by those companies to build a profile of your interests and show you relevant adverts on other sites. They do not store directly personal information, but are based on uniquely identifying your browser and internet device. If you do not allow these cookies, you will experience less targeted advertising.

Cookies:

Currently we are not utilizing these types of cookies on our site.

Feedback