Guest Posted September 6, 2005 Share Posted September 6, 2005 this is from the "links manager contribution" i want the "notify recipient" to be automatically checked and be hidden field, so nobody can uncheck the box. here's the code for the "link status notify" <?php $link_statuses = array(); $links_status_array = array(); $links_status_query = tep_db_query("select links_status_id, links_status_name from " . TABLE_LINKS_STATUS . " where language_id = '" . (int)$languages_id . "'"); while ($links_status = tep_db_fetch_array($links_status_query)) { $link_statuses[] = array('id' => $links_status['links_status_id'], 'text' => $links_status['links_status_name']); $links_status_array[$links_status['links_status_id']] = $links_status['links_status_name']; } echo tep_draw_pull_down_menu('links_status', $link_statuses, $lInfo->links_status); if ($action == 'edit' || $action == 'update') { echo ' ' . ENTRY_LINKS_NOTIFY_CONTACT; echo tep_draw_checkbox_field('links_notify'); } ?></td> any help would be greatly appreciated :) Link to comment Share on other sites More sharing options...
Beer Monster Posted September 6, 2005 Share Posted September 6, 2005 I recently looked for a way to make a hidden checkbox and discovered that it cant be done. I suspect that it may be possible with some fancy css work but I didn't find any examples during my exhaustive search. This should do the same job assuming the value is tested for simple true/false when it's posted (1==true) tep_draw_hidden_field('links_notify', '1') Light, in the absence of eyes, illuminates nothing. Link to comment Share on other sites More sharing options...
Guest Posted September 6, 2005 Share Posted September 6, 2005 i just tried your example. while it hid the checkbox, it didn't send off the email notices :( Link to comment Share on other sites More sharing options...
Beer Monster Posted September 6, 2005 Share Posted September 6, 2005 i just tried your example. while it hid the checkbox, it didn't send off the email notices :( <{POST_SNAPBACK}> try: tep_draw_hidden_field('links_notify', 'on') Light, in the absence of eyes, illuminates nothing. Link to comment Share on other sites More sharing options...
Guest Posted September 6, 2005 Share Posted September 6, 2005 same thing happened. so far i've tried (instead of 1 or on) yes, true, checked Link to comment Share on other sites More sharing options...
Beer Monster Posted September 6, 2005 Share Posted September 6, 2005 same thing happened.so far i've tried (instead of 1 or on) yes, true, checked <{POST_SNAPBACK}> I've just tried this myself and it works, make sure you've still got the echo before it! echo tep_draw_hidden_field('links_notify', 'on') ; Light, in the absence of eyes, illuminates nothing. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.