Hi,
I'm curious if it's bad coding style for a function to return a value on
success, or simply "false" on fail. Here's what I mean:
Is this ok?
Thank you,
Beau
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
> I think that some of the above question might help you out. However,
> from a programming standpoint i like to make sure that my functions
> return the same type at least. Some feel different about this and
> return various type (ie, int, strings, arrays)...
I agree that it should return a cons
Hi,
I'm trying to separate my database query code from my application logic.
I want to do this by creating a small application-level library with
functions that INSERT, DELETE and UPDATE specific information in a mysql
database. So I created a file called news_mysql.lib.php and put it in a
/libra
Hi,
I'm working on a system that allows users to upload and then download
pdf files. Each file is related to a mySQL database entry. To keep
things simple and consistent, I'd like to store the pdf files like this
on the server:
[PRIMARY_KEY].pdf
But when a user downloads the file, I'd like them
Hi,
Recently, my php app has started to throw these warnings:
Warning: write failed: Disk quota exceeded (122) in Unknown on line 0
Warning: Failed to write session data (files). Please verify that the
current setting of session.save_path is correct (/tmp) in Unknown on
line 0
I narrowed it do
This function:
function getmicrotime()
{
list($usec, $sec) = explode(" ",microtime());
return ((float)$usec + (float)$sec);
}
is provided on this page:
http://www.php.net/manual/en/function.microtime.php
and is needed for the code below to work properly.
Beau
> $timerOn = 1; // s
> The admin users will need to run long processes that take about
> 5-15 minutes each. They cannot timeout and they must be done
throughout the day
> while general users are working in the application as well. Is
> there a big problem with this? What steps should I take to ensure
> t
> I guess that this means I am out of luck here. Anyone know a cleaner
> method for delivering spreadsheets?
Can you get the server to write it to a file, and then let the client
download the file normally?
Beau
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http:/
> Can you get the server to write it to a file, and then let the client
> download the file normally?
> [/snip]
>
> Believe me, if I could have taken that way out I would have done it. I
am
> researching some classes, but they all seem to take just as long to
create
> the spreadsheet.
What about
I'm just starting to use PEAR, and have seen several ways of
instantiating the PEAR objects:
$form = new HTML_QuickForm();
$form =& new HTML_QuickForm();
$dbh = DB:connect("dsn");
$dbh = new DB();
$mail_object =& Mail::factory('sendmail', $params);
Can anyone explain (or point to dome docs that e
Jens,
I would suggest that you try writing a script that keeps track of how
many tags have been opened (look for "<"), versus how many tags have
been closed ("[^>]*/>") on a line-by-line basis. Using that number, you
should be able to indent the code properly.
Let us know what you've got so far.
All,
When I submit a form from MSIE, under certain circumstances some of the
fields don't make it into the $_POST array. I am building a CMS that
accepts images and text entered into an HTML form. If I submit a form
from MSIE, and if the text contains special characters (like T [TM] for
example),
I described a situation where MSIE for Windows would not post all of a
form's fields under fairly unique circumstances. This problem occurs in
MSIE 5, 5.5, and 6 (with the most recent hotfixes applied). No other
browsers seem to be affected. When:
1. A form is submitted with the enctype attribute
Marc:
This could be related to the problem I described in detail a few days
ago. Here was my solution:
http://marc.theaimsgroup.com/?l=php-general&m=107751892631059&w=2
Please let us know if this helps!
Beau
> We're having a weird problem with some of our PHP forms,
> where, when a client use
hi all,
i have a script that calls a popup like this:
Choices
the & is there to make sure the page validates. the problem is that
some browsers seem to be incorrectly translating this to:
[REQUEST_URI] => /popup.php?name=Choices&product_id=15
instead of:
[REQUEST_URI] => /popup.php?name=Choic
15 matches
Mail list logo