Professional CodeIgniter
Chapter 6: Creating a Dashboard 178 The deleteProduct() function looks suspiciously like the deleteCategory() function created i ...
Chapter 6: Creating a Dashboard 179 $Q = $this- > db- > getwhere(‘admins’,$options,1); if ($Q- > num_rows() > 0){ $d ...
Chapter 6: Creating a Dashboard 180 Creating the User Home Page The user home page is called with the index() function. Just as ...
Chapter 6: Creating a Dashboard 181 Figure 6-12 Creating the User Create Page Here ’ s the create() function for the admin/admin ...
Chapter 6: Creating a Dashboard 182 echo “ < p > < label for=’uname’ > Username < /label > < br/ > ”; $d ...
Chapter 6: Creating a Dashboard 183 Creating the User Edit Page Without belaboring the obvious, here ’ s the edit() function in ...
Chapter 6: Creating a Dashboard 184 Figure 6-14 Creating the Admin Delete Function Finally, here ’ s the delete() function in th ...
Chapter 6: Creating a Dashboard 185 You ’ re going to remedy that situation very quickly while you ’ re working inside the user ...
Chapter 6: Creating a Dashboard 186 $_SESSION[‘username’] = $row[‘username’]; }else{ $this- > session- > set_flashdata(‘er ...
Chapter 6: Creating a Dashboard 187 It ’ s always OK to work incrementally. Just because you don ’ t have the perfect set of fie ...
...
Improving the Dashboard In Chapter 6 , you built a rudimentary administrative dashboard that allows the client to manage categor ...
Chapter 7: Improving the Dashboard Chapter 7: Improving the Dashboard 190 < h1 > < ?php echo $title;? > < /h1 > ...
Chapter 7: Improving the Dashboard 191 To make the category dropdown work, you will need to update the index() function of the a ...
Chapter 7: Improving the Dashboard 192 Here ’ s a simple batchmode() function that uses print_r() to reveal the structure and co ...
Chapter 7: Improving the Dashboard 193 with array_values() and implode() (using the comma as a glue) and feed that list to the $ ...
Chapter 7: Improving the Dashboard 194 If you edit any of the products you processed, you ’ ll see that the category and groupin ...
Chapter 7: Improving the Dashboard 195 All you need in this instance is a result set object, which you hand off to the csv_from_ ...
Chapter 7: Improving the Dashboard 196 Figure 7-3 If you have a spreadsheet tool (like Numbers on the Mac or the more ubiquitous ...
Chapter 7: Improving the Dashboard 197 Please note that the SQL query is now pulling from the Products table. Here ’ s the contr ...
«
6
7
8
9
10
11
12
13
14
15
»
Free download pdf