The wonderful use of extract function in PHP bilberryextract vanilla extract regexp extract

WBOY
Release: 2016-07-29 08:54:11
Original
1540 people have browsed it

PHP’s extract() function, its main function is to expand the array, the key name is used as the variable name, and the element value is the variable value. It can be said that it provides another convenient tool for array operations. For example, it can be very convenient Extraction of POST or For the _GET element, the content submitted by the form must be assigned one by one

<code><?php
extract(<span>$_POST</span>);
<span>//</span>相当于<span>$username</span> = <span>$_POST</span>[<span>'username'</span>];
<span>//</span><span>$password</span> = <span>$_POST</span>[<span>'password'</span>];
?></code>
Copy after login
').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i ').text(i)); }; $numbering.fadeIn(1700); }); });

The above has introduced the wonderful uses of the extract function in PHP, including the extract aspect. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!