PHP Novice Ask a function
I was looking at the source of a little doubt, first there is such a function
function Submitcheck ($var = "") {
if (empty ($_post)) {
return false;
}
if ($_server[' request_method ') = = ' POST ' && (Empty ($_server['
How does this simple function that involves the regularization be implemented?
Judge a string (the string can contain only the following three characters)
1.26 Letters of English
2. "0,1,2,3,4,5,6,7,8,9" 10 digits
3. "-" (conjunction number in
Ask an array of PHP questions
Define an array in PHP
$sz = Array ();
If you add a specific name element to the array, I write it this way.
$sz [A] = "123456";
And then use the Echo $sz [' a '] to output nothing what is this for? Is there any other
Why does this SQL statement always fail?
$idinfo =mysql_fetch_array ("select * from Tb_yonghu where name= ' $name ' and id= ' $id '") or Die ("Access failed");
Is the statement itself a problem? Is there any relationship between $name and $id plus
Are you familiar with the business or PDO? Always rollback, delete data
Database type: SQLite
No prompt error, one line test, there is no error, why always rollback? Always rollback, delete data
What do you suppose is the reason?
Here is the
How data in action is shared
In the code, within a controller, containing multiple actions, I want to set the relevant variable in one action for another action read, how to do it.
Class Indexcontroller extends Zend_controller_action {
Public
Why are some Chinese characters not submitted to the database??
My database uses MySQL.
Database test code is gb2312 inside there is a table news, encoding is also gb2312, there is a field title type is varchar
Now I submit data to form news, I
Circular problem--help
For advice
Table 1:
Db_1
Fid
Fup
Name
---------------
Table 2:
Db2
Fid
Subject
---------------
FID (table db_1) =fid (table db_2)
--------------------------------
I want to loop through the name of fup=0 in table 1 and the
Online, etc., simple questions!
The MySQL database has a good table with the following fields:
GOOD_ID (auto-grow), good_name
Among them good_id (13, 、.....) is the number, Good_name is the Chinese character (Tian Nan Xing, atractylodes ...) )
FCKeditor direct input is not garbled, paste from word garbled, how the whole
Page encoding is UTF-8.
------Solution--------------------
Upgrade to the latest.
------Solution--------------------
Because the encoding you use in Word is inconsistent
Smarty List Plugin displays title length and connection
Now write a station, to write a list plugin in the Smarty plug-in, to intercept the title length.
PHP Code
Pageexecute ($sql, $pagesize, $page); $rs = $rs->getrows ();
How is the query statement written in thinkphp?
Similar to the kind of QQ, a user information table, the user has some friends, how can I query the user's friend information displayed on the page. Thank you, GGMM!
------Solution--------------------
Ask a smarty question.
Smarty There is no such as in PHP In_array () judgment, if not how to add in? If so, how to write?
------Solution--------------------
This is not Smarty's life, what do you want to throw to Smarty? I don't
HTML parsing error:unable To modify the parent container element before the CHI
When I pass 2 parameters to the page, I'm going to go back to the wrong page.
It was reported.
Message: HTML parsing error:unable To modify the parent container element
PHP code prohibits search engine spiders
In fact, robots.txt is not a total can stop spiders crawling your site, I combined some data to write a small piece of code, seemingly can completely solve the problem, the wrong place please give us a lot of
To ask the regular expression!!
Testtesttes
You want to use the Preg_replace function to leave the table properties only two of the rowspan=6 and colspan=4, the function of the regular how to write??
------Solution---------
PHP uses regular expressions to intercept characters "help"
Which expert to help see: I want to extract from the following code
{Dede:field name= ' keywords '} {/dede:field}
{Dede:field name= ' description '} {/dede:field}
{Dede:field name= ' title '
How long is the cache appropriate?
For example, Memcache, the cache period of data does not change, such as 30 minutes, this is not good, but the cache time set small meaning is not big, such as 30 seconds, cache this thing, in the end to set how
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.