1. Read
  2. Vote
  3. Old
  4. New
  5. Hot
  6. Reply

Wiki: Topnew Data Docs

TODO
Cat: CMS | Read: 6373 | 11/11/2018

SQL row sum

Given an SQL table

ID Amt
-- ---
1 100
2 200
3 300

Please write a MySQL statement to produce the following result:

ID Amt Total
-- --- -----
1  100 100
2  200 300
3  300 600

And here is an example SQL:

SELECT a.ID, a.Amt, sum(b.Amt) AS Total
FROM tab AS a
JOIN tab AS b ON a.ID >= b.ID
GROUP BY 1,2
Cat: SIDU | Read: 13757 | 02/11/2018

Wiki: Topnew Form Helper

Wiki: Topnew\Util\Form v 2026.04.04

Topnew Form is a view helper class used to generate HTML form elements programmatically.

pre{font-family:'Droid Sans Mono',monospace;font-size:.8em;background:#eee;padding:10px}b,.b{font-weight:700}


Sample Usage:
Cat: CMS | Read: 67138 | 01/03/2026 | Like: 5
Tags: CMS , Wiki

Topnew CMS - User Database

Today we are going to make a user system, which will be used for login, user management, role permission, page access control etc.

1 - team

CREATE TABLE team (
id int NOT NULL AUTO_INCREMENT PRIMARY KEY,
id_up int NOT NULL DEFAULT 0, -- parent team id
name varch
Cat: CMS | Read: 1172 | 05/06/2022

Topnew CSS v 2023 JS related

6 - Javascript related

There are a list of CSS class binded with jQuery

6.1 span of any width / height

class=span data-w=300px

class=span data-w=30% data-h=100px
Cat: CMS | Read: 1572 | 16/04/2022
Tags: CSS
  1. 1
  2. 2
  3. 3
  4. 4
  5. »

Category