web front end
-
Zblog (non js) calls the method of discuz post Step 1: In the zblog directory (take b2c topic as an example)/zb_ In the users/theme/b2c/include directory, create new empty files news01.html and news02.html. Step 2: Copy the following code, save it as news.php, and upload it to the source/include/cron/directory of the discuz program.<? phpif(!defined('IN_DISCUZ... two thousand and twenty one thousand four hundred and fifty-five -
The difference between javascript execution before and after elements When writing native js, we found that the script cannot be executed before the dom element, and it needs to be placed after the dom element to be effective. Because the js is executed immediately after loading, we put the code in the window.onload function body, and let the page be loaded completely before execution. Window. onload=function() {//Execute when the page is loaded} The jQuery code placed before and after the page element has no impact on the execution effect two thousand and nineteen one thousand eight hundred and thirty-nine -
Record the optimization process of simple and complex switching font When making zblog themes, in order to increase the function of simple and complex switching, find a simple and complex font database data on the Internet. Because zblog themes use Microsoft Yahei font, some traditional characters are the same as simplified characters. In order to eliminate the same characters, the specific idea is to first change the simplified and traditional characters to take up a single line for each Chinese character, Then find the same item in the two columns of data in Excel and delete it. After the format is restored by Sublime, the final optimized text is obtained,. The detailed method is as follows: 1. First two thousand and seventeen four thousand and fourteen -
Example of jquery price switching with specifications Nowadays, when we browse the product page of e-commerce website, we often see the display of product specifications and prices. Different specifications correspond to different prices. For example, on the hot sale theme page of our website, click on the specifications to display the corresponding prices. The implementation method is very simple, so we wrote a responsive example page to show that prices switch with the specifications. Effect preview: jquery code: $(function() { two thousand and seventeen four thousand three hundred and seventy-six -
Query tool for prohibited words in the new advertising law The new Advertising Law, which came into force on September 1, 2015, clearly stipulates that advertisements shall not contain false or misleading content, and shall not deceive or mislead consumers. It is prohibited to publish tobacco advertisements in mass media or public places; It is prohibited to use advertisements and public service advertisements of other goods or services to publicize the names, trademarks and other contents of tobacco products. This website has written a set of convenient query tools for young partners engaged in e-commerce industry. At present, 420 words have been included. Forbidden words query tools: https://zbp.toyean.com/... two thousand and seventeen eighteen thousand two hundred and fifty-seven -
Two methods of generating order number in PHP When developing a project, there is often a need to generate an order number. Here are two common methods to generate a 20 digit order number. Method 1: The following code is 14 bits of current time plus 6 bits of random number. If you want to increase or decrease the number of bits, just modify the number 6 at the end.<? phpfunction build_ order_ no(){ return date('YmdHis&#... two thousand and seventeen four thousand eight hundred and sixty -
Setting method of apmserv pseudo static APMServ, as a one click software to build a PHP environment, facilitates the development and debugging of local PHP programs. In order to support pseudo static when developing zblog themes or using zblog PHP programs, you need to modify the Apache configuration file. By default, the software does not support pseudo static, and you need to manually modify it, The method is as follows: Open the APMServ software (right click the administrator to run it)>Apache Settings>Modify the configuration file two thousand and seventeen three thousand nine hundred and eighty-two -
Three methods for jQuery to determine whether the checkbox is selected The check box of the form is often judged in the project, and the following three common methods are summarized two thousand and seventeen four thousand four hundred and eleven -
Two Methods of Domain Name Authorization in PHP 01. Online verification of domain name authorization: Client code:<? Php//Get the domain name prefix without port number $servername=trim ($_SERVER ['SERVER_NAME '])// Get the server authorization file to verify $verifyurl=file_ get_ contents('... two thousand and sixteen twelve thousand nine hundred and sixty-nine -
Three methods for JQuery to cancel event bubbling 1. Cancel the default behavior and prevent the event from bubbling by returning false$ (element).click(function(){return false;}); 2. Cancel the default behavior by using the preventDefault() method$ (element).click(function(e){e.preventDefau... two thousand and sixteen six thousand four hundred and sixty-eight -
Right column of e-commerce website Nowadays, more and more websites have added sidebars, especially e-commerce websites, such as Vipshop, Tmall, JD, JumeiYoupin, etc., which use traditional sidebars to indicate with icons, making website navigation clear at a glance, allowing users to focus on side navigation at a glance, achieving good interaction with users and increasing PV, It also shows the noble quality of the website. The following is our sidebar effect. The core code is as follows: LESS: @ c two thousand and sixteen five thousand seven hundred and ninety-four -
Sort out common codes of Tmall JD Dangdang stores Taobao C store 1920 full screen code: two thousand and sixteen five thousand six hundred and forty-seven -
Tuoyuan zblogphp Topic Tag Assistant V1.0 Release Tuoyuan zblogphp topic assistant is a software developed according to the requirements of zbp topic production, covering the commonly used topic tags of zblogphp, so that the theme production can achieve twice the result with half the effort. Tuoyuan zbp theme assistant is green software, pure and non-toxic two thousand and fourteen fifteen thousand one hundred and seventy-four -
The method of implementing classified search in zblog There are many ways for zblog to implement classified search (nonsense). One common way is that there are classified search plug-ins in the application center. After installation and enabling, set the generated code, which can be written into the sidebar or put into the theme file for use; Another method is to implement classification search by YTCMS two thousand and fourteen seven thousand nine hundred and seventy -
Change div into textarea attribute "contenteditable" Today, I checked the implementation effect of arrow on the lovers' home page of QQ Space. I accidentally found that the text field uses the "contenteditable" attribute, making div a textarea effect, which can easily solve the problem that the text box adapts to its height with the content. The contenteditable attribute is a new attribute of HTML5, and it is no inferior in Internet Explorer, so don't worry about compatibility two thousand and fourteen fourteen thousand nine hundred and thirty-two -
Tutorial on using commodity template code of Tuoyuan JD store The activity page of Jingdong store decoration is designed with a red commodity layout, and a set of templates is made with reference to Yi Xun's product list two thousand and thirteen eighteen thousand two hundred and nine -
JQuery implements the effect of mouse sliding delay display Web developers sometimes use delayed user interaction events, such as the product display on the home page of JumeiYoupin website. When the mouse moves into the product for one second, the product details will be displayed, instead of the user's mouse pointer just moving into the element to display the details. For users who do not want to display details, it achieves friendly interaction, Next, we will use jQuery's timer setTimeout two thousand and thirteen fourteen thousand four hundred and five -
Extending CSS style of pop-up background to full screen advertising link Sometimes I visit some material websites and add many fake advertisements to make the advertisement download address too realistic, but the real address is hard to find. Many material websites and software stations are like this, which is very annoying. You will get used to it when you click a download link. If you see setup.exe, in most cases, it is either an advertising software or a trojan program; If it is an exe file with other names, you should also be careful. It is best to use anti-virus software to check and kill it. Maybe some Trojan viruses will be killed two thousand and thirteen seven thousand three hundred and two