> Use full path for every filename.
I have now changed my code to do this, see below.
> Use ls -als to figure the permissions on each file.
I am running this on a windows box for now, and although I have cygwin and
can run ls and chmod, they don't seem to have any affect on the actual
permissio
How about working out the length of the column (by dividing the number of
rows by the number of cols you want), dump your results into an array and
using the col length as an offset to pick through the resulting table?
// $data is an array of results
$rows = count ($data)
$row_len = round ($rows
Voigt
> [EMAIL PROTECTED]
>
> On Thu, 2002-07-11 at 10:03, Michael Davey wrote:
> > Errr - doesn't that function apply to mySQL databases only?
> >
> > Mikey
> >
> > "Adam Voigt" <[EMAIL PROTECTED]> wrote in message
> > [EMAIL PROTECTED
doh!
"Adam Voigt" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I wouldn't have said it if it did.
> Notice that it's MSSQL_select_db not MYSQL_select_db.
>
> Adam Voigt
> [EMAIL PROTECTED]
>
> On
Errr - doesn't that function apply to mySQL databases only?
Mikey
"Adam Voigt" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Check out the "mssql_select_db" function.
> Call it right after the connection open.
>
> Adam Voigt
> [EMAIL PROTECTED]
>
> On Thu, 2
I don't really know much about freetds so this could all be wrong, but...
when you set-up a DSN on a server, the database is specified there - hope
this helps.
Mikey
"Tim Nields" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I am attempting to connect to a M
> $word=new COM("word.application") or die("Cannot start MS Word");
> print "Loaded word version ($word->Version)\n";
> $word->visible = 1 ;
> $word->Documents->Add();
> $word->Selection->Typetext("This is a test");
> ?>
>
> does anyone recognise this?
Oh yes - this would be Word via COM - i
Remove the semi-c0lon from the following line in php.ini:
;extension=php_ifx.dll
And then restart your web-server if your run PHP as a module...
Mikey
"GastóN" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Thanks for the answer..
>
> But this is the story
I have found that the best way to work with currencies is to avoid using any
type of floating point math.
If you multiply your start amount by 100, then perform your calculations as
integers and then divide by 100 again at the end, it should work out OK...
(Heh, at least it has worked for me whe
at
http://www.phpbuilder.com/columns/ if you need more help...
Mikey
BTW - reply to the list
> -Original Message-
> From: Igor Portnoy [mailto:[EMAIL PROTECTED]]
> Sent: 05 June 2002 19:59
> To: Michael Davey
> Subject: RE: [PHP] Re: Passing variable to new page and pullin
By reading the manual section relevant to your specific database...
"Igor Portnoy" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Hello,
I am passing a variable to the new page, when user clicks on the link.
Something like that:
How can I extract all ot
Iff you asre using the latest version of PHP, use the $_GET/$_POST
superglobals
regards,
Mikey
"Joe Pemberton" <[EMAIL PROTECTED]> wrote in message
000f01c20cc1$1df6f320$9b6ee60c@c1195782a">news:000f01c20cc1$1df6f320$9b6ee60c@c1195782a...
Is there a function call to figure out how a variable wa
Not unless you pass the variable to the next page explicitly. You can do
this by either encoding it into the URL of the next page:
http://your.com/page.php?var=value or by putting the variable into an HTML
form and submitting it.
regards,
Mikey
"Kemu" <[EMAIL PROTECTED]> wrote in message
[EMAI
Ooops, now I feel silly - sent this to the wrong list!
Hangs head in shame! :-)
"Michael Davey" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> OK - couple of things first:
>
> a) The PHP mailing list is for programmers of PH
OK - couple of things first:
a) The PHP mailing list is for programmers of PHP looking for help making
their own scripts - not for people who want support for implementing someone
else's script. There is a link on the site where I found a copy of your
script offering support, this is where you s
print << wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> On Tuesday 04 June 2002 17:34, [EMAIL PROTECTED] wrote:
> > What is the best way to print large blocks of text within a PHP
function?
>
> echo(), print()?
>
> Perhaps you can elaborate on what you want to do and what you want
I originally posted this to the PHP-WIN list but there doesn't seem to be
anyone there... maybe you guys can help?
Does anyone know what has happened to the php4win.com web-site? I have been
trying to get there now for the best part of a month and still get site
errors.
regards,
Mikey
--
P
> Point well-made. I suppose doing it the mixed way might have repercussions
> later on if/when the site grows. Perhaps while the code is still fresh in
my
> mid, it might be worth the effort to separate it.
>
> However, for a good part of the site, I've used CSS for appearance
details,
> and cont
However...
>From the point of view of someone who has worked in a company where diesign
is separated from development, it is much better to have separate files with
HTML templates with special markers (in the library I use, it is HTML
comments ) so that the two processes are adequately
separated.
> Won't that treat all radio buttons on the page as one group, instead of
> being separate groups for each form?
No - the tags "enclose" the data that is being submitted -
nothing outside of the tags will reach the script that handles the request.
Mikey
--
PHP General Mailing List (http://w
Also, if you are really worried about placing too much load on the server,
you could use JavaScript to check the form submission on the client side
using the same technique...
Mikey
"Bogdan Stancescu" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> First, you
Which is so easy to find in the offline manual...
"Stuart Dallas" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> On Saturday, June 1, 2002 at 6:29:59 PM, you wrote:
> > Does anyone know of a function within PHP that will convert a
hexadecimal
> > string (witho
Does anyone know of a function within PHP that will convert a hexadecimal
string (without the leading 0x) into an integer?
regards,
Mikey
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
You could give the button the same name in each form - only the fields in
between the tags is actually submitted, then put a hidden field
in the form that uniquely identifies the data being submitted.
Just a thought... it is what I usually do...
Mikey
"Jason Teagle" <[EMAIL PROTECTED]> wrote i
You should normalise your data - have a field in the second csv that links
to the first csv and then you can have as many rows as you want associated
with the record in the first file.
Mikey
"Scott" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I have a csv
So does anyone have any advice on adding files rather than strings?
On Fri, 31 May 2002, Michael Davey wrote:
> I have been looking through the documentation for using Bzip2 or zlib
> compression and have a couple of questions for the group...
>
> 1. Which is best to use
$_SERVER['HTTP_REFERRER']
"Kris Vose" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Is there a variable/function in php that will display the url location of
the hyper-link that brought them to the current page. Thanks in advance.
>
> Kris Vose
>
--
PHP
Can you send the code that is failing to the list - it will help in working
out the problem...
Mikey
"FréDéRick St-Hilaire" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> It a BASIC question,
>
> With the following:
>
> ENCTYPE="multipart/form-data">
>
I believe so - but why are you passing a the object a reference to itself?
> $bar->db_obj->run_some_code($bar);
> $bar->tpl_obj->do_this_for_me($bar);
If you need to access parts of the object from within, use the $this->
pointer.
> It works but was wondering if its 'legal' to use it like this
I have been looking through the documentation for using Bzip2 or zlib
compression and have a couple of questions for the group...
1.Which is best to use on terms of: resultant file size, availability of
decompression clients & ease of use?
2.Both bzip & zlib documentation makes use of *w
I believe you will need to use sin and cos to do this...
I experimented with drawing circles in javascript (sorry, it's not PHP but
you can see the concept) and ended up with this:
for (j = 0; j <= 360; j += (360 / 10))
{
// x1 & y1 are offset values
var s = x
I am doing that - sorry, should have given you a bit more code...
conn = mysql_connect ($host, $user, $pwd)
or die ("Unable to connect to database");
$sel = mysql_select_db ($db, $this->conn);
if (!$sel) die ("Unable to select database");
return true;
}
It is called php4apache2.dll
Mikey
"Herman Pool" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hi all,
>
> I have downloaded PHP4.2.1 because I want to use it with apache 2.0.36
> But there is no php/experimental/apache2filter.dll file in PHP4.2.1
> Did I m
Can anyone here shed some light on this issue?
I have a class which is responsible for it's own database access and (some
of it) is initalised as below:
conn = mysql_connect ($host, $user, $pwd)
or die ("Unable to connect to database");
$sel = mysql_select_db ($db, $this->con
s
> --
> W: www.londontown.com
> @: [EMAIL PROTECTED]
> --
>
> -Original Message-----
> From: andy [mailto:[EMAIL PROTECTED]]
> Sent: 31 May 2002 15:19
> To: Michael Davey; [EMAIL PROTECTED]
> Subject: [PHP] Re: PHP can not
Check permissions on '/var/lib/mysql/mysql.sock' I seem to remember having
this problem in the past...
Mikey
"Andy" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hi there,
>
> I am runningn suse72 and there was a mysql installation with the rpm
> installed.
Not really, seeing as PHP is executed at the server and not on the client -
you would need JavaScript for this.
Mikey
"Dave Shacket" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I know how to have my php code run a function within itself. But is there
a
> w
> Given $myvar = 5;
>
> If you use session_register('myvar');
>
> Then on another page, do you just access it via $myvar?
That is exactly how it works - I also have session.auto_start turned on as
well.
> And if that's the case, isn't it the same to set
>
> $HTTP_SESSION_VARS['myvar'] = $myvar;
Hmm...
I can't say that I have moved over to the new superglobals yet - I prefer
register_globals cos I am lazy ;)
But it does seem that there are two possible variables that you need to
use - the one in your script ($HTTP_SESSION_VARS), but this is only for
4.0.6 or less, it is $_SESSION otherw
As I said...
>Not quite sure where you got this $login class instance from, but it
>appears to be from thin air. If you have a session class then you would
need >to instantiate it first with:
>
>$login = new XYZSessionClass(); // plus any constructor arguments
And to quote from the manual page
Oops - should have read down a lot further...
"Michael Davey" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Not quite sure where you got this $login class instance from, but it
appears
> to be from thin air. If you have a ses
Not quite sure where you got this $login class instance from, but it appears
to be from thin air. If you have a session class then you would need to
instantiate it first with:
$login = new XYZSessionClass(); // plus any constructor arguments
However, I am a bit confused as you mention using PHP
The best way to do this is to register your form data as session variable
when it is processed on the second page. Then add some scripting in the
first page to check for these variables and pre-populate the form as
necessary...
Mikey
"Phil Schwarzmann" <[EMAIL PROTECTED]> wrote in message
news:
It would be possible to flush the output of your page (i.e. your HTML) and
then put the PHP code after this... however, the page wouldn't appear to be
fully loaded until the script had finished processing...
Mikey
"Phil Schwarzmann" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
Ignore this - I have managed to get them to work in Unix - now onto
Windows... sigh!
"Michael Davey" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I know this is cross-posting, but I have no luck with finding a solution
to
>
> -Original Message-
> > > From: Michael Sweeney [mailto:[EMAIL PROTECTED]]
> > > Sent: 30 May 2002 15:58
> > > To: Michael Davey
> > > Subject: Re: SQL question, getting error and not sure why
> > >
> > >
> > > I thought it gave
> insert into acteursenc (nuacteur,nomacteur)
> (select AA, BB from
> (select max(nuacteur)+1 AA from acteursenc),
> (select 'Michael Sweeney' BB from acteursenc))"
>
> produces an ORA-1: unique constraint error.
>
> The primary key i
I know this is cross-posting, but I have no luck with finding a solution to
this problem on PHP-WIN, and I have since tried running my code on a Linux
server and have had the same problems... so here goes!
-- Original Post --
Sorry if this has been posted a hundred times already - but I am trying
48 matches
Mail list logo