Changeset 136 for trunk/bin/module_maker/skel/public.php
- Timestamp:
- Jun 3, 2006 7:47:48 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bin/module_maker/skel/public.php
r111 r136 34 34 35 35 // Get requested record. 36 $qid = DB::query("36 $qid = $db->query(" 37 37 SELECT * FROM %DB_TBL% 38 WHERE %PRIMARY_KEY% = '" . DB::escapeString(getFormData('%PRIMARY_KEY%')) . "'38 WHERE %PRIMARY_KEY% = '" . $db->escapeString(getFormData('%PRIMARY_KEY%')) . "' 39 39 AND publish = 'true' 40 40 <##>AND (publish_date <= CURDATE() OR publish_date = '0000-00-00') … … 42 42 "); 43 43 if (!$item = mysql_fetch_assoc($qid)) { 44 App::raiseMsg(_("Sorry that %ITEM_TITLE% could not be found"), MSG_WARNING, __FILE__, __LINE__);45 App::dieBoomerangURL();44 $app->raiseMsg(_("Sorry that %ITEM_TITLE% could not be found"), MSG_WARNING, __FILE__, __LINE__); 45 $app->dieBoomerangURL(); 46 46 } 47 47 48 48 // Update the hit counter for this record. 49 DB::query("49 $db->query(" 50 50 UPDATE %DB_TBL% 51 51 SET hit_count = hit_count + 1 52 WHERE %PRIMARY_KEY% = '" . DB::escapeString(getFormData('%PRIMARY_KEY%')) . "'52 WHERE %PRIMARY_KEY% = '" . $db->escapeString(getFormData('%PRIMARY_KEY%')) . "' 53 53 "); 54 54 … … 61 61 // Get the DEFAULT list. 62 62 $%NAME_SINGULAR%_list = array(); 63 $qid = DB::query("63 $qid = $db->query(" 64 64 SELECT * 65 65 FROM %DB_TBL% … … 79 79 // Get the FEATURED list. 80 80 $featured_list = array(); 81 $qid = DB::query("81 $qid = $db->query(" 82 82 SELECT * 83 83 FROM %DB_TBL% … … 92 92 // Get the POPULAR list. 93 93 $popular_list = array(); 94 $qid = DB::query("94 $qid = $db->query(" 95 95 SELECT * 96 96 FROM %DB_TBL% … … 104 104 // Get the RECENT list. 105 105 $recent_list = array(); 106 $qid = DB::query("106 $qid = $db->query(" 107 107 SELECT * 108 108 FROM %DB_TBL%
Note: See TracChangeset
for help on using the changeset viewer.