Can you just switch the order?
Instead of...
define("SOME_CONSTANT","Generic Value");
define("SOME_CONSTANT","Override Value");
Why not do...
define("SOME_CONSTANT","Override Value");
if(!defined("SOME_CONSTANT")) { define("SOME_CONSTANT","Generic Value"); }
This should avoid any r
While perhaps unlikely in "common users" it is also possible to
prevent your browser from sending the referrer. IIRC, the referrer can
also get mangled when passing through HTTPS (although I don't remember
on which side, HTTP->HTTPS or HTTPS->HTTP or both)
Matt
On Thu, Jan 12, 2012 at 1:11 AM, Ro
On Thu, Dec 8, 2011 at 7:16 AM, Richard Quadling wrote:
> On 2 December 2011 21:00, Matt Neimeyer wrote:
>> Is there (or is there a way to compile) a DOS CLI version of a fairly
>> recent version of PHP? I have not been able to find one using the
>> powers of Google.
&g
Is there (or is there a way to compile) a DOS CLI version of a fairly
recent version of PHP? I have not been able to find one using the
powers of Google.
Not a Windows Command Prompt CLI but an actual CLI version of PHP that
can be made to run in a real DOS environment?
I'm sure I could find anot
I know I could possibly hack something together using the Tidy
libraries... (maybe...) but are there any existing php libraries /
projects that already have the ability to take some HTML and
"downgrade" the version of HTML being used.
One example: turn this...
Blah
... into ...
Blah
This
, it makes it simple to just dump row after row of data
into it for exports and simple reports.
Matt
On Mon, Feb 22, 2010 at 4:14 AM, Rene Veerman wrote:
> just curious, why did you choose to use it from behind a stream wrapper?
>
> On Sun, Feb 21, 2010 at 11:03 PM, Matt Neimeyer wr
I created a stream wrapper around the php_writeexcel library found at
http://www.bettina-attack.de/jonny/view.php/projects/php_writeexcel/
My code can be seen at http://www.pastebin.com/m7212eaa2
I'm trying to add an option that will allow us to lower or uppercase
the column headers we create by
If the scanning device hooks into the keyboard somehow it should be
easy. I believe that's called a "keyboard wedge". Basically, you scan
and it types.
My only exposure to this is using one of the old CueCat scanners to
index my personal library into a php app I cobbled together. The
CueCat hooked
> How many PHP scripts correspond to these 4 steps? Is it one script (or
> more) for each step? For example:
> Or is it just one "dispatcher" script:
> Or something in-between?
It's a dispatcher script that can call multiple files. For example
(without pulling up code)... (each dispatch job would
> In circumstances like this, I would "instrument" the code with
> echo/print statements all around where you think the problem is.
We did that with no luck. We only saw one call to the initialize
function which is why I switched to tracer emails because we "knew"
the initialize function was "the
> If it were prefetching, or another request clobbering your current request
> then you would see a second hit in your server logs.
I will admit... I have made (at least) one assumption... Since...
1. This is a difference between IE and Firefox/Safari...
2. I was seeing a tracer email for each hi
> No answers - just more questions to maybe point you in a direction you
> haven't been
Anything is appreciated...
> Is it possible that the query/script is taking too long to build the
> response page and FireFox/Safari is asking for an empty query result?
I don't think so... the tr
no other explanation of why it DOES matter... I've
tried disabling prefetching in Firefox (thinking MAYBE the browser was
prefetching the "bailout" link back to step 1 from step 3). The
initialize in step 1 fixed another problem we were having but I did
try disabling it temporarily to no av
I finally got a chance to play with this and it looks like it is
exactly what I need.
Thanks!
On Fri, Jul 31, 2009 at 11:50 PM, German Geek wrote:
> have you tried mysqldiff?
>> I want to be able to compare the structure of two different clients
>> databases that might be on different servers tha
I know I CAN hack something together but I hate to reinvent the wheel.
I want to be able to compare the structure of two different clients
databases that might be on different servers that are firewalled away
from each other. Given the two structures it will list all the SQL
commands needed to mak
I like it... Thanks!
On Thu, Jul 30, 2009 at 8:04 PM, Ben Dunlap wrote:
>> I don't THINK I need to worry about circular mappings... but I'm not
>> sure how to check for it if I did...
> Would the following work? It avoids recursion entirely and also checks for
> circular mappings. You can plug in
I'm cleaning up some inherited code in our data import module. For a
variety of reasons we have to support old standards of the import
format. Since some of those old versions were created we have since
renamed some fields in our data structure. So right now I've a hard
map for some field names...
>> $Ret = mysql_fetch_array($result); if(!$Ret) { } else { return $Ret; }
> I'm assuming that you are calling my_fetch_array() in a loop of some
> sort and so at some point there are no more records in the result.
Oh... Um... Yeah... Well...
So... Checking the docs... "Returns an array of string
e"
[1]=>
string(11) "Sample Cust"
["value"]=>
string(11) "Sample Cust"
}
On Tue, Jul 28, 2009 at 2:56 PM, Eddie Drapkin wrote:
> On Tue, Jul 28, 2009 at 2:48 PM, Matt Neimeyer wrote:
>> Background: I'm converting a webapp from Visual
Background: I'm converting a webapp from Visual FoxPro as a backend to
MySQL... However one part of our app (a system status checker) is
common code between the versions.
I've got the following function... In English (in case it's not
apparent), if the version of the app is 2.0 or higher, then use
> You might even be able to convert EMPTY(X) to COALESCE(X, '') = ''.
> MySQL seems to be pretty forgiving with its implicit type-casting.
Hmm... The new system I've written properly handles the datatype and
EMPTY... So this would be a hack to much around with regexs to replace
EMPTY in customer b
me)
Matt
On Tue, Jul 21, 2009 at 1:54 PM, Ashley
Sheridan wrote:
> On Tue, 2009-07-21 at 13:46 -0400, Matt Neimeyer wrote:
>> Has anyone come across / written a script that will convert one
>> "flavor" or Dialect of SQL to another?
>>
>> I need to convert Visu
Thanks for the information. I'll look into using ODBTP. I noticed
> you mentioned the problem with memos. I currently have that problem with
> the set up we're using and it is a pain!
>
> Thanks!
> Floyd
>
> On Jul 20, 2009, at 3:22 PM, Matt Neimeyer wrote
Has anyone come across / written a script that will convert one
"flavor" or Dialect of SQL to another?
I need to convert Visual FoxPro 6.0 style WHERE clauses to MySQL.
For the most part the problems are converting VFP functions to the
equivalent SQL. For example, Visual FoxPro has a function inl
> We currently use the Easysoft ODBC Bridge to connect to a remote FoxPro
> database. The problem is that the bridge, after a while, starts consuming a
> ton of system resources and we have to reboot the machine. Afterwards, it
> can take upwards to two hours before everything is running quickly
I'm probably just not Googling right... Short version: How can I
launch a program for the current user sitting in front of a windows
web server?
Longer version: I've written a PHP app to migrate data from the FoxPro
version of our product to the upcoming MySQL version. I have a self
contained setu
On Jul 1, 2009, at 11:33, Ashley Sheridan
wrote:
On Wednesday 01 July 2009 16:25:29 Matt Neimeyer wrote:
We've got a project
where "Date Of Attendance" is moving from a single type in
character field to an automatically built field based on a
DateBegin date field and
I haven't been able to find anything by googling... Does anyone know
of any libraries that will split up date ranges? We've got a project
where "Date Of Attendance" is moving from a single type in character
field to an automatically built field based on a DateBegin date field
and a DateEnd date fie
I know this is a bit OS specific but it's for PHP so I'm hoping
someone here has run into it before and can answer.
I've compiled php_gd.so for use on an XServe running OSX 10.4. It
works fine there. When I copy it to another XServe it fails because of
missing dependencies (don't remember the exac
I'd have to check...
But am I to understand that no-cache works with pre-caching? I always
assumed it basically meant "when you get this page, don't keep it for
next time"?
Thanks!
On Fri, Jun 12, 2009 at 2:04 AM, Manuel C. wrote:
> Matt Neimeyer a écrit :
>>
>&g
I'm at a complete loss... So I'm hoping someone can point me in the
right direction to even start looking.
We have an application written in PHP that lets users send out emails.
The basic process is as follows.
1. Go to "start" screen. (This resets anything currently in process
for the current lo
On Wed, Apr 29, 2009 at 1:30 PM, Shawn McKenzie wrote:
> Philip Thompson wrote:
>> On Apr 29, 2009, at 11:42 AM, Matt Neimeyer wrote:
>>
>>> I have a function that currently takes a boolean value as a parameter.
>>> But now I want to expand it to 3 options...
I have a function that currently takes a boolean value as a parameter.
But now I want to expand it to 3 options... So if I have...
function doFooBar($doFoo = false)
{
if($doFoo)
{ echo "Did Foo"; }
else
{ echo "Did Bar"; }
}
Is it as "simple" as changing it like follows t
I know this isn't exactly what you were probably looking for but...
If you have a Windows machine available I would recommend taking a
look at the ODBTP project at http://odbtp.sourceforge.net. ODBTP
stands for Open DataBase Transport Protocol. The short version is that
you add a client module to
On Tue, Mar 24, 2009 at 9:15 AM, Per Jessen wrote:
> TG wrote:
>
>> I don't think that would be a problem, the size of the array. I've
>> used implode at least once or twice on fairly large arrays. More
>> likely is something weird with your data.
>
> Yeah, like the odd backspace or carriage ret
I just recently got a new Onkyo TX-SR706 Audio Receiver that has an
RS232 interface and I thought... cool... Build a Web Interface so I
can control it from several rooms away.
The code below works using PHP 5.2.8 under Apache (XAMPP) on Windows
XP to change the current input of my Audio Receiver.
I'm trying to sanitize some numeric data that's coming to us from
another system which I have no control over where all fields are
character fields with no formatting from the end user so data is a
mishmash of clean and mixed types of dirty.
I know I can use intval and floatval to sanitize if the
Wow! Thanks guys! Here's what I ended up doing... To get...
Black on White - 1
White on Black - 2
Black on White - 3
Black on White - 3
White on Black - 2
Black on White - 3
I had to do something like...
function doStuff()
{
static $callCount = 0;
$callCount++;
if($c
Is there a way to tell if a function has been called that has resulted
in a call to the same function?
We have an in-house CRM app that has a function that draws a tabbed
panel on a screen... BUT if there are sub-sub-tabbed panels we want to
invert the tab colors and panel colors...
So...
DrawSu
he directory where you
>are trying to create the database? PHP runs as the web server when
>installed as a module and it needs permission to write in that
>directory.
>
>---John Holmes...
>
> > -Original Message-
> > From: Matt Neimeyer [mailto:[EMAIL PROTECTE
Hey All,
I'm trying to build a DBF for exporting selected data as a download to the
end users... But I can't get further than this...
error_reporting(E_ALL);
$DBFName = "Test.dbf";
$Fields = array( array ("Test","C",32) );
if(dbase_create($DBFName, $Fields))
41 matches
Mail list logo