Why does the program I wrote look so scattered? Sometimes I can see that other people's programs are very compact, but I feel that my writing is very fragmented. why? Please teach me. ------ Solution -------------------- is the program you wrote not standardized? Poor readability? Cause? ------ Solution ------------------ stand on the shoulders of giants and learn from them slowly. ------ solution ---------------- why does the program I write look so scattered?
Sometimes I can see that other people's programs are very compact, but I feel that my writing is very fragmented. why?
Please teach me.
------ Solution --------------------
Is the program you wrote not standardized?
Poor readability?
Cause?
------ Solution --------------------
Stand on the shoulders of giants and learn from them.
------ Solution --------------------
That's because you wrote it. you didn't want to write it better.
A program, write his four or five lines, and you will be able to understand it.
------ Solution --------------------
Let me have a loose look... it makes me comfortable.
------ Solution --------------------
Loose coupling is the goal of software design ............
------ Solution --------------------
Preliminary planning is very important ....
------ Solution --------------------
Maybe you are writing the framework
------ Solution --------------------
Join the team in a big project and you will know how to write it.
------ Solution --------------------
It is recommended that you check the mvc framework structure. it is really good. I just got started with it.
------ Solution --------------------
Exercise more. I was just learning
------ Solution --------------------
It's okay !~
------ Solution --------------------
Let's look at the code written by others.
------ Solution --------------------
Return $ this-> db-> query ($ SQL)-> result_array ();
------ Solution --------------------
If you don't have a good Design idea, you can look at the book Design Pattern.
------ Solution --------------------
This is a long story.
In short.
I did not write enough.
Second, it cannot be improved.
3. no desire.
There are too few csdn instances ~
------ Solution --------------------
Reference:
This is a long story.
In short.
I did not write enough.
Second, it cannot be improved.
3. no desire.
There are too few csdn instances ~
Article 4 is good, haha
------ Solution --------------------
How to use a framework?
------ Solution --------------------
After reading this, the 27 th floor is the best ....
------ Solution --------------------
public function uList($role)
{
$query = $this->db->query("SELECT * FROM qsj_user_profile
RIGHT JOIN qsj_user ON qsj_user.uid = qsj_user_profile.uid
WHERE qsj_user.role = $role
ORDER BY qsj_user.regdate DESC
");
return $query->result_array();
}
------ Solution --------------------
It would be nice to have a unified standard mode. it would be nice to write more ,,