- Once you're in heaven, do you get stuck wearing the clothes you were
buried in for eternity?
- Once you're in heaven, do you get stuck wearing the clothes you were
buried in for eternity?
" The value of a diamond depends on whether you char it to ash or wear it in a crown."
--- Written in 2008 by Gunalan Ramachandiran
geez.....it's not test data....and I was given the database as it is....hmmm, can't I alter it with the data in it?
here it is...
(I am using MySQL Query Browser)
gem.
The color of my hair is ___________.
my table create statement???
these are really pretty.....geez, I wish I had talent like that!!!
same as before...
Result:
Resource id #6account,service,date,time,timebandtype,destination,callednumber,mins,airtimecharge,tollcharge,amt,privatenumber
:D
Ok, let me try...
still no change...here is the result:
Resource id #6account,service,date,time,timebandtype,destination,callednumber,mins,airtimecharge,tollcharge,amt,privatenumber
nope, they are in the format 'dd-mm-yyyy'
Here is the result:
Resource id #6account,service,date,time,timebandtype,destination,callednumber,mins,airtimecharge,tollcharge,amt,privatenumber
I do have data with the dates falling into the range I selected while testing...
my dates are being selected from a javascript....datetimepicker.js
ok, so I echoed the query
// Start our query of the database
$sql = mysql_query("SELECT * FROM tsttbills where date >= '$sDate' and date <= '$eDate'", $conn) ;
echo $sql;
Here is the result:
Resource id #6account,service,date,time,timebandtype,destination,callednumber,mins,airtimecharge,tollcharge,amt,privatenumber
only the column names are displayed...
Just the column headers
hmmm.....well I put in and it displays the form now...I will check it now for functionality...
I just tested it, and the .csv file is cleaned of the code...so I am seeing the table headers now....but no data....I verified that there is data stored in the table for the particular date range selected for testing...
what is varname?
Yea, I did and there's still a blank page...
from the file testGCR.php....with the following piece of code....isn't there supposed to be an open and closed square brackets?
<?
include("./gcrFunction.php");
if(count($_POST[]) == 0)
{
?>
Hi,
When I applied the changes you did, I only get a blank page and not the page to select the dates...
liked the way you used
$head[] = mysql_field_name($sql, $i); gonna have to try that.
Thanks...
May
Hi, here are the 2 files...
Instead of having it output into the csv file, when i echoed it to the screen, it only shows the column headings...
testGCR.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Test Document</title>
<script language="javascript" type="text/javascript" src="datetimepicker.js">
//Date Time Picker script- by TengYong Ng of http://www.rainforestnet.com
//Script featured on JavaScript Kit (http://www.javascriptkit.com)
//For this script, visit http://www.javascriptkit.com
</script>
</head>
<body>
<?php
include("./gcrFunction.php");
?>
<form method="post">
<table>
<tr>
<td width="747">
<p align="left"><span class="style4 style25 style28 style6">Generate Chargeback Report</span></p>
<p align="left"><span class="style21 style29 style5">The Chargeback Reporter works in 2 steps.</span></p>
</td>
</tr>
<tr><td><p> </p></td></tr>
<tr>
<td>
<table width="648" border="0" align="center" cellpadding="1" cellspacing="0" bordercolor="#FFFFFf">
<tr>
<td bgcolor="#99bebe" colspan="4">
<p align="left" class="style8 style7 style32"><strong>
<span class="style21 style33 style11">Step 1: Select Start and End Date</span></strong></p>
</td>
</tr>
<tr>
<td width="100" bgcolor="#99bebe" scope="row">
<div align="left" class="style8 style7 style31 style29 style13">
<div align="right"><strong>Start Date: </strong></div>
</div> </td>
<td width="220" bgcolor="#99bebe">
<input name="sDate" id="sDate" type="text" size="25">
<a href="javascript:NewCal('sDate','ddmmyyyy')">
<img src="images/cal.gif" width="16" height="16" border="0" alt="Pick a Start Date">
</a> </td>
<td width="100" bgcolor="#99bebe" scope="row">
<div align="left" class="style8 style7 style31 style29 style13">
<div align="right"><strong>End Date: </strong></div>
</div> </td>
<td width="220" bgcolor="#99bebe">
<input name="eDate" id="eDate" type="text" size="25">
<a href="javascript:NewCal('eDate','ddmmyyyy')">
<img src="images/cal.gif" width="16" height="16" border="0" alt="Pick an End Date">
</a> </td>
</tr>
<tr>
<td bgcolor="#99bebe" colspan="4">
<p align="left" class="style5">
<span class="style21 style30 style11">Step 2: Generate the Chargeback Report </span></p> </td>
</tr>
<tr>
<td bgcolor="#99bebe"><p> </p></td>
<td bgcolor="#99bebe" colspan="3"> …
heroes -> Captain Planet
(huh?!?)
No
Have you ever driven until you ran out of gas?
Norbit
Hello,
I am trying to do an export from a table within a mysql database into a csv file where my parameters are a start date and end date...but I am experiencing a few problems...
Background:
I have 2 files; testGCR.php and gcrFunction.php.
testGCR.php has my form where the user enters the relevant dates (I have a inserted calender to enter the dates...the date when chosen from the calender looks like "dd-mm-yyyy"), this is to be passed to the query...
gcrFunction.php has the validation of the data entered in the date boxes as well as the export code (which I got off the net :icon_redface: )
Problem 1:
when the date is entered in the select query, only the column names are displayed with no data in the csv (even though the table has alot of data)
Problem 2:
in the csv file, just above the column names are the entire chunk of code from testGCR.php....it's not supposed to do that...it's only supposed to show me the results...
Any suggestions/comments are most welcome...
Thanks in advance
May
Have you ever seen a pig fly
Unhappy beaver's with their offspring started spanking New Zealand polices and failed to annex Australia.
Serve
Ever
Rev
nomenclature
pretty
This is as good as ______.
4602
^ Not originally mine:
Child: "Mom, why do you have strands of grey hair mixed in with your dark hair?"
Mother: "Every time you disobey, I get one strand of grey hair. If you want me to stay pretty, you better obey."
Child after some thinking: "Mom, why is Grandma's hair all grey?"
< I hope you enjoyed the joke... :)
v Tell us something about you that we don't know...
Catwoman --> Batman
(A Hindi Movie ) -> Yarana
away he went, from his parents
Welcome to Daniweb...hope to see you around...:)
Welcome to Daniweb...hope to see you around...:)
Welcome to Daniweb...hope to see you around...:)
Welcome to Daniweb...hope to see you around...
Welcome to Daniweb...hope to see you around...
Up To Date
Submitted by: Peace
Author: Robert Byers
A 28k modem is slower than fate
A 386 is a paperweight
A 4x CD is not so great
But my love for you is up to date
A 5 inch floppy is hard to find
A 12 inch screen will leave you blind
An all DOS system is way behind
But my love for you is the modern kind
The pace of change is getting faster
The new technology is hard to master
Today's new computer will be out to pasture
But losing you would be real disaster
I can make it fine with my old stuff
So much of the new is merely fluff
I'll never be a technology buff
But since I have you I have enough.
HOUSE BOY: BAKARI
Bakari is a house boy who every day drinks the wine of his Boss and puts water in the bottle to replace what he drank. But the Boss having suspicions as for the quality of the wine, he decides to buy pastis (a French wine that changes colour if you add water).
Bakari as usual, takes a mouthful and add water to replace what he drank however, soon after he added water the pastis became milky.
When the Boss came back and noticed it, he was sure he had managed to nail Bakari as thief!!! At that same moment Bakari realized he was in trouble and decided to go into the kitchen.
The Boss told his wife, 'Mary, you will see today,he will be obliged to acknowledge'. So he calls Bakari.
He shouted: 'Bakari!'
Bakari answered: 'Yes, Boss'
Boss: 'Who drank my pastis?'
No answer.
The Boss reiterated his question: 'Who drank my wine?'Still;
No answer.
Then the Boss went to fetch Bakari from the kitchen and says to him:
You insane or what? Why when I call you, you say yes boss' but when I ask you a question you don't
answer me?
Bakari retorted that 'It is that boss, when you are in the kitchen there, you don't hear anything at
all, except the name.
Then to prove that Bakari lies, the Boss says to him: 'You stay beside …
It's not the wound that shapes our lives, it's the
choice we make as adults between embracing
our wounds or raging against them.
-- Unknown
Why is it that when someone tells you that there are over a billion stars in the universe, you believe them, but if they tell you there is wet paint somewhere, you have to touch it to make sure.
I techinally "Knew them all" but i didnt know thier names :D
I also 'technically knew all' but not the names of most of them...
:)