| Server IP : 172.67.201.108 / Your IP : 216.73.216.11 Web Server : Apache/2.4.68 (Amazon Linux) OpenSSL/3.5.5 System : Linux ip-172-31-69-123.ec2.internal 6.1.176-223.369.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Jul 24 13:34:27 UTC 2026 x86_64 User : ec2-user ( 1000) PHP Version : 8.4.23 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/home2/cgny/public_html/newadmin/ |
Upload File : |
<cfinclude template="header.cfm">
<link href="../plugins/bower_components/datatables/jquery.dataTables.min.css" rel="stylesheet" type="text/css" />
<link href="https://cdn.datatables.net/buttons/1.2.2/css/buttons.dataTables.min.css" rel="stylesheet" type="text/css" />
<cfif parameterexists(url.winner)>
<cfquery name="upds" dataSource="#ds#">
update cgsurvey set iswinner = 1
where id = #url.winner#
</cfquery>
<Cfquery name="getwinner" dataSource="#ds#">
select email from cgsurvey where id = #url.winner#
</Cfquery>
<Cfquery name="gete" datasource="#ds#">
select title,copy from columntable where id = 157059
</Cfquery>
<CFMAIL
TO="#getwinner.email#"
SUBJECT="#gete.title#"
FROM="CG <[email protected]>"
type="html"
SERVER="127.0.0.1"
>
#gete.copy#
</cfmail>
<cfquery name='getlosers' dataSource="#ds#">
select email from cgsurvey
where id <> #url.winner# and iswinner = 0
</cfquery>
<Cfquery name="gete" datasource="#ds#">
select title,copy from columntable where id = 157060
</Cfquery>
<Cfoutput query="getlosers">
<cftry>
<CFMAIL
TO="#getlosers.email#"
SUBJECT="#gete.title#"
FROM="CG <[email protected]>"
type="html"
SERVER="127.0.0.1"
>
#gete.copy#
</cfmail>
<cfcatch></cfcatch>
</cftry>
</Cfoutput>
<cfquery name="upds" dataSource="#ds#">
update cgsurvey set iswinner = -1
where id <> #url.winner# and iswinner = 0
</cfquery>
<cflocation url="data-table-survey.cfm" addtoken="no">
</cfif>
<div id="page-wrapper">
<div class="container-fluid">
<div class="row bg-title">
<div class="col-lg-3 col-md-4 col-sm-4 col-xs-12">
<h4 class="page-title">Survey Stats</h4>
</div>
<div class="col-lg-9 col-sm-8 col-md-8 col-xs-12">
<ol class="breadcrumb">
<li><a href="#">Dashboard</a></li>
<li><a href="#">Calendar</a></li> <li class="active">Today</li>
</ol>
</div>
<!-- /.col-lg-12 -->
</div>
<!-- /row -->
<div class="row">
<div class="col-sm-12">
<div class="white-box">
<a href="https://www.cityguideny.com/newadmin/data-table-survey-openended.cfm">Open Ended</a><p></p>
<!--- <p class="text-muted m-b-30">Export data to Copy, CSV, Excel, PDF & Print</p>
---> <div class="table-responsive">
<link href="../plugins/bower_components/bootstrap-datepicker/bootstrap-datepicker.min.css" rel="stylesheet" type="text/css" />
<Cfset newdatetime = #dateformat(currentdatetime,'yyyy-mm-dd')#>
<Cfset newdatetime = #dateadd('d',-7,today)#>
<Cfset newdatetime = #dateformat(newdatetime,'yyyy-mm-dd')#>
<Cfset newdatetime = '2025-01-01'>
<cfset today = #dateformat(currentdatetime,'yyyy-mm-dd')#>
<Cfset tomorrow = #dateadd('d',1,today)#>
<cfset tomorrow = #dateformat(tomorrow,'yyyy-mm-dd')#>
<form action="data-table-survey.cfm?requesttimeout=5000" method="post" name="calme" enctype="multipart/form-data">
<Table><tr><td>
From:
<input class="form-control" id="datepicker-autoclose" placeholder="mm/dd/yyyy" name="dater" label="Block out starts" style="width:115px;" data-date-format="yyyy-mm-dd" <Cfif parameterexists(form.daterend)>value="<cfoutput>#dateformat(dater,'yyyy-mm-dd')#</cfoutput>" <cfelse> value="<cfoutput>#dateformat(newdatetime,'yyyy-mm-dd')#</cfoutput>"</Cfif>>
</Td><td>
To:
<input name="daterend" class="form-control" id="datepicker-autoclose" placeholder="mm/dd/yyyy" style="width:115px;" data-date-format="yyyy-mm-dd" <Cfif parameterexists(form.daterend)>value="<cfoutput>#dateformat(daterend,'yyyy-mm-dd')#</cfoutput>" <cfelse> value="<cfoutput>#dateformat(tomorrow,'yyyy-mm-dd')#</cfoutput>"</Cfif>>
</td><Td style="padding-top: 14px;">
<button class="btn btn-success btn-mini">SEARCH <i class="icon-save"></i></button>
</Td></tr></table>
</form>
<table id="example23" class="display nowrap" cellspacing="0" width="100%">
<thead>
<tr>
<th>date</th>
<th>sourcecode</th>
<th>plansvisit</th>
<th>whilepurchase</th>
<th>didpurchase</th>
<th>ai_general</th>
<th>ai_sightseeing</th>
<th>ai_broadway</th>
<th>ai_restaurants</th>
<th>ai_museums</th>
<th>ai_other</th>
<th>discountpurchase</th>
<th>usecityguide</th>
<th>whichattractions</th>
<th>whereeat</th>
<th>wherefrom</th>
<th>partycount</th>
<th>timesinnyc</th>
<th>daysstaying</th>
<th>whendecide</th>
<th>wherestaying</th>
<th>howmuchspend</th>
<th>CG help plan</th>
<th>age</th>
<th>agenew</th>
<th>first</th>
<th>last</th>
<th>zip</th>
<th>country</th>
<th>email</th>
<th>winner</th>
</tr>
</thead>
<tbody>
<cfset today = #dateformat(currentdatetime,'yyyy-mm-dd')#>
<Cfquery name="Geter" dataSource="#ds#">
select * from cgsurvey
where 1 =1
<cfif parameterexists(form.dater)>
and currentdatetime > '#form.dater#'
</cfif>
<cfif parameterexists(form.daterend)>
and currentdatetime < '#form.daterend#'
</cfif>
group by email
order by id
</cfquery>
<Cfoutput query="geter"> <tr>
<Td>#dateformat(currentdatetime,'yyyy-mm-dd')#</td>
<Td>#sourcecode#</td>
<Td>#plansvisit#</td>
<Td>#whilepurchase#</td>
<Td>#didpurchase#</td>
<Td>#ai_general#</td>
<Td>#ai_sightseeing#</td>
<Td>#ai_broadway#</td>
<Td>#ai_restaurants#</td>
<Td>#ai_museums#</td>
<Td>#ai_other#</td>
<Td>#discountpurchase#</td>
<Td>#usecityguide#</td>
<Td>#whichattractions#</td>
<Td>#whereeat#</td>
<Td>#wherefrom#</td>
<Td>#partycount#</td>
<Td>#timesinnyc#</td>
<Td>#daysstaying#</td>
<Td>#whendecide#</td>
<Td>#wherestaying#</td>
<Td>#howmuchspend#</td>
<Td>#helpplan#</td>
<Td><cfif len(trim(age)) and left(age,1) eq "<">&##8203;</cfif>#age#</td>
<Td><cfif len(trim(agenew)) and left(agenew,1) eq "<">&##8203;</cfif>#agenew#</td>
<Td>#first#</td>
<Td>#last#</td>
<Td>#zip#</td>
<Td>#country#</td>
<Td>#email#</td>
<td>
<a href="data-table-survey.cfm?winner=#id#" onClick="return confirm('Are you sure?');"><cfif #iswinner# eq 0>Unassigned</cfif> </a>
<cfif #iswinner# eq 1>Winner</cfif>
<cfif #iswinner# eq -1>Loser</cfif>
</td>
</tr>
</Cfoutput> </tbody>
</table>
</div>
</div>
</div>
</div>
<!-- /.row -->
<cfinclude template="footer.cfm">
<script src="../plugins/bower_components/datatables/jquery.dataTables.min.js"></script>
<!-- start - This is for export functionality only -->
<script src="https://cdn.datatables.net/buttons/1.2.2/js/dataTables.buttons.min.js"></script>
<script src="https://cdn.datatables.net/buttons/1.2.2/js/buttons.flash.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/2.5.0/jszip.min.js"></script>
<script src="https://cdn.rawgit.com/bpampuch/pdfmake/0.1.18/build/pdfmake.min.js"></script>
<script src="https://cdn.rawgit.com/bpampuch/pdfmake/0.1.18/build/vfs_fonts.js"></script>
<script src="https://cdn.datatables.net/buttons/1.2.2/js/buttons.html5.min.js"></script>
<script src="https://cdn.datatables.net/buttons/1.2.2/js/buttons.print.min.js"></script>
<!-- end - This is for export functionality only -->
<!-- end - This is for export functionality only -->
<script>
$(document).ready(function(){
$('#myTable').DataTable();
$(document).ready(function() {
var table = $('#example').DataTable({
"columnDefs": [
{ "visible": false, "targets": 2 }
],
"order": [[ 2, 'asc' ]],
"displayLength": 25,
"drawCallback": function ( settings ) {
var api = this.api();
var rows = api.rows( {page:'current'} ).nodes();
var last=null;
api.column(2, {page:'current'} ).data().each( function ( group, i ) {
if ( last !== group ) {
$(rows).eq( i ).before(
'<tr class="group"><td colspan="5">'+group+'</td></tr>'
);
last = group;
}
} );
}
} );
// Order by the grouping
$('#example tbody').on( 'click', 'tr.group', function () {
var currentOrder = table.order()[0];
if ( currentOrder[0] === 2 && currentOrder[1] === 'asc' ) {
table.order( [ 2, 'desc' ] ).draw();
}
else {
table.order( [ 2, 'asc' ] ).draw();
}
});
});
});
$('#example23').DataTable( {
dom: 'Bfrtip',
buttons: [
'copy', 'csv', 'excel', 'pdf', 'print'
]
});
</script>
<!-- jQuery -->
<script src="../plugins/bower_components/jquery/dist/jquery.min.js"></script>
<!-- Bootstrap Core JavaScript -->
<script src="bootstrap/dist/js/bootstrap.min.js"></script>
<!-- Menu Plugin JavaScript -->
<script src="../plugins/bower_components/sidebar-nav/dist/sidebar-nav.min.js"></script>
<!--slimscroll JavaScript -->
<script src="js/jquery.slimscroll.js"></script>
<!--Wave Effects -->
<script src="js/waves.js"></script>
<!-- Custom Theme JavaScript -->
<script src="js/custom.min.js"></script>
<!-- Plugin JavaScript -->
<script src="../plugins/bower_components/moment/moment.js"></script>
<!-- Clock Plugin JavaScript -->
<script src="../plugins/bower_components/clockpicker/dist/jquery-clockpicker.min.js"></script>
<!-- Color Picker Plugin JavaScript -->
<script src="../plugins/bower_components/jquery-asColorPicker-master/libs/jquery-asColor.js"></script>
<script src="../plugins/bower_components/jquery-asColorPicker-master/libs/jquery-asGradient.js"></script>
<script src="../plugins/bower_components/jquery-asColorPicker-master/dist/jquery-asColorPicker.min.js"></script>
<!-- Date Picker Plugin JavaScript -->
<script src="../plugins/bower_components/bootstrap-datepicker/bootstrap-datepicker.min.js"></script>
<!-- Date range Plugin JavaScript -->
<script src="../plugins/bower_components/timepicker/bootstrap-timepicker.min.js"></script>
<script src="../plugins/bower_components/bootstrap-daterangepicker/daterangepicker.js"></script>
<script>
// Clock pickers
$('#single-input').clockpicker({
placement: 'bottom',
align: 'left',
autoclose: true,
'default': 'now'
});
$('.clockpicker').clockpicker({
donetext: 'Done',
})
.find('input').change(function(){
console.log(this.value);
});
$('#check-minutes').click(function(e){
// Have to stop propagation here
e.stopPropagation();
input.clockpicker('show')
.clockpicker('toggleView', 'minutes');
});
if (/mobile/i.test(navigator.userAgent)) {
$('input').prop('readOnly', true);
}
// Colorpicker
$(".colorpicker").asColorPicker();
$(".complex-colorpicker").asColorPicker({
mode: 'complex'
});
$(".gradient-colorpicker").asColorPicker({
mode: 'gradient'
});
// Date Picker
jQuery('.mydatepicker, #datepicker').datepicker();
jQuery('#datepicker-autoclose').datepicker({
autoclose: true,
todayHighlight: true
});
jQuery('#date-range').datepicker({
toggleActive: true
});
jQuery('#datepicker-inline').datepicker({
todayHighlight: true
});
// Daterange picker
$('.input-daterange-datepicker').daterangepicker({
buttonClasses: ['btn', 'btn-sm'],
applyClass: 'btn-danger',
cancelClass: 'btn-inverse'
});
$('.input-daterange-timepicker').daterangepicker({
timePicker: true,
format: 'MM/DD/YYYY h:mm A',
timePickerIncrement: 30,
timePicker12Hour: true,
timePickerSeconds: false,
buttonClasses: ['btn', 'btn-sm'],
applyClass: 'btn-danger',
cancelClass: 'btn-inverse'
});
$('.input-limit-datepicker').daterangepicker({
format: 'MM/DD/YYYY',
minDate: '06/01/2015',
maxDate: '06/30/2015',
buttonClasses: ['btn', 'btn-sm'],
applyClass: 'btn-danger',
cancelClass: 'btn-inverse',
dateLimit: {
days: 6
}
});
</script>
<!--Style Switcher -->
<script src="../plugins/bower_components/styleswitcher/jQuery.style.switcher.js"></script>
</body>
</html>