I'm trying to get a two tiered pricing structure into my store. Essentially I need every product to have two prices. There's the main price but there's also a secondary price that get's triggered if the customer has more than 14 products in their cart. I can't do an across the board discount, it has to be specific prices per product.  Say product one has a main price of $20 but a hidden secondary price of $15 and product two has a main price of $50 but a hidden secondary price of $30. This will be defined on the product itself. It's all arbitrary pricing set for every product.  I figured out how to set a rule where 14 products will trigger it but I can't work out how to add a secondary price to a product then activate that price.
I have a shop created with drupal commerece modules,I enabled 2 currency in my shop , but only show one of them, I want to show price in 2 currency       something like this price :  10$  / 20 IRR I use multi currency module to achieve this job, but  I my problem is in payment  phase, I use multi currency module to achieve this job,in multicurrency  module's setting I don't want  use  synchronize method, if you want have two field in my product , one form $ and another for IRR, I did this job by this method     first enable IRR currency in  admin/commerce/config/currency  then in  admin/commerce/config/currency/handling under Enable dedicated price fields for Product check Iranian Rial  by doing this  another field added you my product ( ** Price for IRR** ), this is good , after this I enable  *currency selector * block ,in checking out process by switching the currency I don't see any change in current currency of billing and cart. :( why changing currency not changing cart currency?
How to plot and solve the numerical solution of a integro-differential equation I'm running a witcheling, a changeling witch who, because of a GM's homebrew magic ring, can transform into a .  What effects does this pixie transformation have? Specifically...   Since I'm now Small, do I apply +1 to AC, +1 to attack rolls, –1 to CMB and CMD and +4 to Stealth? Am I able to cast spells while transformed? Do I lose my racial benefits while transformed? Am I still able to use weapons such as staff, longsword, or greatsword? I had a look at Knuth's The Art of Computer Programming, book 1. In chapter 1, section 1.2.2, exercise 25, he presents the following algorithm for calculating logarithm:  given $x\in[1,2)$, do the following:  L1: [Initialize] Set $y\leftarrow0$, $z\leftarrow x/2$, $k\leftarrow1$.  L2: [Test for end] If $x=1$, stop.  L3: [Compare] If $x-z&lt;1$, go to L5.  L4: [Reduce values] Set $x\leftarrow x-z$, $z\leftarrow x/2^k$, $y\leftarrow y+\log_b(2^k/(2^k-1))$, and go to L2.  L5: [Shift] Set $z\leftarrow z/2$, $k\leftarrow k+1$, and go to L2.  (The algorithm needs an auxiliary table which stores $\log_b2$, $\log_b(4/3)$, and so on, to as many values as the precision of the computer.  Then Knuth concludes: this exercise is to explain why the above algorithm will terminate and why it computes an approximation of $y=\log_b x$.  Well, I see that it works, but I am not able to explain why... CPT Template Not Showing - Getting 404 I'm developing a Custom Post Type plugin, which works fine in dev. Now that I've moved it to production, I'm getting a 404 when I try to display the template for the CPT.   So, two questions:  1- Is there some mechanism to determine the path WP took to get through the hierarchy?  2- Why wouldn't it just give me the single or index page?  I've dumped $wp_query and a stacktrace at the end of the 404. Here's part of what I found:  [query] =&gt; Array     (         [page] =&gt;          [pagename] =&gt; refletters/proximity     )  [request] =&gt; SELECT   wp_posts.* FROM wp_posts  WHERE 1=1  AND (wp_posts.ID = '0') AND wp_posts.post_type = 'page'  ORDER BY wp_posts.post_date DESC  [posts] =&gt; Array     (     )  [queried_object] =&gt;  [queried_object_id] =&gt; 0   And the stack trace:  2013-04-27 22:16:41 - 24.52.197.40 - TRACE - index.php - 404.php[39] -      wordpress/wp-content/themes/notoriousconsultant/404.php[39] - aaLog-&gt;logtrace     wordpress/wp-includes/template-loader.php[50] - include     wordpress/wp-blog-header.php[16] - require_once     wordpress/index.php[17] - require   Thanks for your help. Do I have to recompile my application when I upgrade a third party jar? I want to block Facebook (the Facebook site) for concentrating purposes, but I don't want to break the share or like buttons on other pages (like a good article or a nice clip on YouTube I want to like or share). How can I do that? I use both Windows and Linux. Make clear which profile data is visible to whom A gold reviewer badge? For your continued efforts in reviewing posts, even though the system sometimes messes up and doesn't let you actually review things and keeps displaying them over and over and over. So also, for your patience in putting up with the glitches in the review panel too! Haha  Anyways, a gold reviewer badge: 20000 reviews, over 4000 actioned  I just multiplied both numbers by 20. Think those numbers seem challenging? Is anyone up near those numbers or should it be multiplied by 10 instead? I prefer the higher amount because it would be gold and something harder to work for. :) But we also have to consider the longevity of when all these posts are eventually reviewed and it's only new posts being created.  Anyways, my stats for those who are interested (I wouldn't get the badge to start because I only have ~2000 actioned):  Upvoted            189 Downvoted          11 Edited             926 Commented          127 Voted to Close     44 Flagged            447 Reviewed           21609   As far as the name of the badge, I really like "The Owl is Watching" but not sure if that would be too long. Sounds snazzy though. Ideas?    Personally, I was on a quest to try and clear out all the posts in a single tab before it started showing me the same things over and over (and over) and then it got frustrating because I wasn't even making progress. Quest denied. :(    Lately I've noticed a massive build-up of unreviewed posts. When the review panel was first implemented, there would only ever be maybe 50 unreviewed posts at a time (in a given tab) for my monthly view. Now I log in and there's a thousand or two thousand pending. I think a lot of people quit reviewing after the first badge, so having a gold badge with a high threshold would really improve activity in the review panel and keep people going to improve the community. What's the best way to take a segment out of a text file? What's a good way of extracting say, lines 20 -45 out of a huge text file. Non-interactively of course! Regarding the `book`, `report`, and `article` document classes: what are the main differences? I get it after updating in Synaptic Manager  I recently did a clean install of Ubuntu 17.04 from 16.10.  error message:-  W: Download is performed unsandboxed as root as file '/var/cache/apt/archives/partial/samba-libs_2%3a4.5.8+dfsg-0ubuntu0.17.04.1_i386.deb' couldn't be accessed by user '_apt'. - pkgAcquire::Run (13: Permission denied) Today I found something strange on my newly installed Windows 7 OS - my "users" folder C:\Users was shared and "Everyone" had full access... I disabled that and now it seems fine, however I'm a bit scared actually, I'd like to know what caused that and if my system is compromised. Terminal icon in window titlebar is stretched out over window control buttons A while ago I upgraded from Ubuntu 17.04 to Ubuntu 17.10 and everything is working fine except for the fact that the icon in the window title bar of my Terminal seems to be stretched out to some ridiculous size.    This only seems to happen in the Terminal window. The Nautilus icon is completely fine.    The problem seems to go away if I login into an Xorg session instead of a Wayland one. I've looked around and didn't find any immediate solution to this. Any help would be greatly appreciated. How to write (La)TeX (with parentheses) [or any other TeX-related logo] I have this run.sh file, and I've create a symbolic link into my desktop.   When I double-click on it the file the following dialog appearsr    And I have to click on "run" each time. How can I create a link that runs by default? VBA Hide Rows that contain N/A Finding files by only knowing extension? What does accepting an answer actually convey (2015 edition)? How to know number of cores of a system in Linux? I wanted to find out how many cores my system has, so I searched the same question in Google. I got some commands such as the lscpu command. When I tried this command, it gave me the following result:  $ lscpu Architecture:          x86_64 CPU op-mode(s):        32-bit, 64-bit Byte Order:            Little Endian CPU(s):                4 On-line CPU(s) list:   0-3 Thread(s) per core:    1 Core(s) per socket:    4 Socket(s):             1 NUMA node(s):          1 Vendor ID:             GenuineIntel CPU family:            6 Model:                 23 Stepping:              10 CPU MHz:               1998.000 BogoMIPS:              5302.48 Virtualization:        VT-x L1d cache:             32K L1i cache:             32K L2 cache:              2048K NUMA node0 CPU(s):     0-3   In particular, this output shows:   CPU(s): 4 Core(s) per socket: 4 CPU family: 6   Which of those indicates cores of a Linux system?  Is there any other command to tell the number of cores, or am I assuming it is completely wrong? How to keep processes running after ending ssh session? Let's say I launch a bunch of processes from a ssh session. Is it possible to terminate the ssh session while keeping those processes running on the remote machine?