1.Magento with the shell at the time of indexing, sometimes error:
General error: 1205 Lock wait timeout exceeded
This time, because of the reason for the row lock, in the table you directly use SQL to perform the update, will report this error, that is, this error is MySQL newspaper.I need it. Table Index_process UnlockIf you want to quickly solve, then, the table import, modify, delete the database index_process table, re-import, OK, row loc
This article will show you how to get the quantity and price of the shopping cart products and how to use Magento. I will give you a detailed introduction below.
Obtain information about all products in the shopping cart.
The Code is as follows:
Copy code
// $ Items = Mage: getModel ('checkout/cart')-> getQuote ()-> getAllItems ();$ Items = Mage: getSingleton ('checkout/session')-> getQuote ()-> getAllItems (); foreach ($ items
Magento Mobile Admin650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M02/89/0C/wKiom1gF7Q6jwtXbAAD3n-kfBMI102.png-wh_500x0-wm_3 -wmp_4-s_3903577549.png "title=" Logo2_7_1.png "alt=" Wkiom1gf7q6jwtxbaad3n-kfbmi102.png-wh_50 "/>by phone automatically (iphone,ipad,android Mobile or PC/MAC), your inventory and product prices. define attributes, barcode numbers, and products assigned to you. open Mobileadmin and go to inventory.Scan barcodes with USB
(1) Installation Magento times lack of PHP extensionsInstall the corresponding extension(2) Some directories are not writable when installing MagentoTerminal Run command changes file permissions for root directoryChmod-r 777 {Directory Address}(3) After changing the file permissions, git prompt file changesNeed to modify git local configurationTerminal open git local configuration fileVim. Git/configModify FileMode = False(4) 502 ErrorFPM not installe
The default Magento only has the English language pack, so if you want to also display Chinese, you will need to install the Chinese language pack.Steps:1. First, go to http://www.magentocommerce.com/langs/list/download Chinese package extract to Magento directory, it copied to two directories: one is app\design\frontend\default\ Default\locale, the other is App\locale.2. Go to System--configuration, then t
Often someone encounters Magento backstage, entered the correct account password. Do not log on properly, and do not prompt for errors. is to continue to jump to the login interface.
There are many solutions on the web, most of which are to comment out a piece of code.
I am a stand-alone server, according to the online method, annotate the code, also can not log in.
Then I emptied the cache and after the session. Can log in. But only for a while. A
The idea is that, to generate the order number, the theory is to generate the order code when the order is saved. So trace the code to the Mage_sales_model_order Save () method. And then tracked down to mage_sales_model_resource_order_abstract this, in view of the characteristics of Magento, or mainly to see _beforesave, save,_aftersave these 3 things are almost, and check to see if there are events,
It is found that the _beforesave of this class is
1. Because the example in
2. Code segmentation Module
Code
Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->Import operator
Def segment (text ):
"Return a list of words that is the best segmentation of text ."
If not text: return []
Candidates = ([first] + segment (rem) for first, rem in splits (text ))
Return max (candidates, key = Pwords)
Def splits (tex
In any fast iteration project, it is a headache to ensure the synchronization of development and production (current network) databases. Magento provides a system for creating resource migration versions, which can help us deal with this problem that is constantly encountered during the development process. Www.2cto.com we created the weblogpost model last time. This time, we execute create table directly. We will not create a Setup Resource for our m
Magento adds the "new" or discount quantity label magentonewlabel. discountlabel to the product. The bottom of the article is. Add a new tag to the new product. Shows the quantity of discounts for discount products. You can add a piece of code to the bottom of the cata article in the template folder.
Add the "new" label to the new product. Shows the quantity of discounts for discount products.
You can add a piece of code to the catalog/product/list.
Step I Add a occupation/title field to the user registration page, almost 54 lines in register.html, add a occupation display code below the email
Code:
This is, if you go to the User registration page, you will see the new fields. Step 2 Also in edit.phtml, add occupation display block
Code:
Step 3, open model/entity/setup.php almost 93 lines, below the email, add the relevant code of
Use only $collection->addfieldtofilter (), do not use Addattributetofilter () or zend_db_expr (can be used for more complex where statements) such as: collection- >getselect ()->where (New zend_db_expr ("E.created_at > ' 2013-01-01 00:00:00 ' OR e.created_at $_collection Array $weight )) (array$weight));OR relationship------------------------------------------------------min_weight > $weight or$weight > Max_weight$_collection-addfieldtofilter (array(' min_weight ', ' max_weight '), array (
Cause analysisThe order price of Magento is calculated by executing the set pricing model under the global/sales/quote/totals node configured in config in sequence, the execution sequence is controlled by the after and before nodes of each model. For example, we can see the following code in the native app/code/core/Mage/Tax/etc/config. xml configuration file:.........We can note that the before node of the tax model specifies grand_total, which means
System records all access data into the database, including visitors and machine access (such as search engine crawlers), machine access will typically account for a large part of the data, so that will produce a small amount of additional server performance costs, including Web services, MySQL database service; This part of the data can not be seen. The database tables responsible for logging access logs are: Log_customer, Log_quote, Log_summary, Log_summary_type, Log_url, Log_url_info, Log_vis
In the checkout page, if you want to determine whether the customer has the use of coupon code, you can judge by checkout session.The following code returns the coupon code used in checkout or returns Null (when no coupon code is used)1PHP2 3 $coupon _code= Mage::getsingleton (' checkout/session ')->getquote ()->getcouponcode ();if($coupon _code){ 4 Echo"Coupon used"; 5}Else{ 6 Echo"Coupon Not used"; 7 } 8 9?>magento--Determine if coup
Use Magento to make product list?? Can be added directly to MQ shopping cart
There are a few questions, please ask the experts.
1. The list of restaurants is displayed on the left. Click on a restaurant to expand its menu below.
2. Click on a category to display the detailed menu on the right.
3. There is a check box on each of the dishes on the right. If clicked, the number will be displayed on the right side of the price, the default
"1", click "+
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.