Hi,
Apache 1.3.24, PHP 4.2.2
I am running a php script which executes something like
system("scp -r -S ssh host1:/home/dir host2:/home");
The scp command executes as the apache user, in my case 'nobody'. This does
not work, as the ssh authentication is not set up for user 'nobody' nor
should it
My company, as a matter of policy, closes the ftp ports of the servers in the DMZ.
However, I am not convinced that this is necessary, given the advent of very secure
ftp servers. I would appreciate any comments on the security of an open ftp port. To
relate this to php, I am ready to give up t
> > To relate this to php, I am ready to give up
> > trying to make my
> >
> > system("scp ..");
> >
> > code work, because I will have to give the apache user more permissions
> > than I am comfortable with.
>
> What exactly are the problems you're encountering using scp?
>
I created an apach
Hi,
What would be a query to select a single record from a number of records in
a table, depending on which one has the biggest value in an integer field?
e.g something like:
MYTABLE
id ifield
1100
2200
3150
SELECT * FROM MYTABLE WHERE id=$id and MAX(i
Hi,
Given the array $array initialized by:
$query = "SELECT id,name FROM MYTABLE";
$result = mysql_query($query);
$nrows = mysql_num_rows($result);
for ($i=0; $i<$nrows; $i++) {
$arr = mysql_fetch_array($result);
$array[$i]['id'] = $arr['id'];
Hi
Given
string1 = /home/web/
string2 = /home/web/www/index.php
How can I elegantly do an exclusive or of string1 with string2, that is, I want to end
up with
string3 = www/index.php
Thanks!
Is there a way to disable cookies not for all sites but on a per site basis? If I do
an ini_set() on session.use_cookies will all sites be afftected or only the site I am
on?
Thanks,
Rich
I have two questions:
1. I would like to build a php page that contains a Windows explorer-like drill down
mechanism, where clicking the '+' beside an item will expand the sub-items below
(which can also have a '+' or '-' on the left) and clicking the '-' will collapse the
item. Is there any e
Hi,
I am connecting to a mysql server on a remote machine, and opened up port 3306 for
this purpose. But, I am concerned about sending a clear text password, via the
mysql_pconnect() call. My question is, what is the procedure for connecting to a
remote server with an encrypted password? Or,
"Rodolfo Gonzalez" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> On Thu, 26 Sep 2002, Brad Bonkoski wrote:
>
> > also might be better then sending it in the clear.
>
> But I guess that the original poster wanted to know how to avoid the clear
> text session o
> Hi Andrew and Richard,
> The password and connection info is scrambled up. You can look, If
> you want to check it out for your self look in the source code of
> ./mysql-3.23.XX/libmysql search for the following functions.
> especially in 'mysql_real_connect' function. It is not the best
I am using
ini_set("session.use_cookies","0");
to disable cookies but I don't see PHPSESSID showing up like I thought it would, so I
don't think its working. I call it before session_start(). After the ini_set call I do
session_log("CSE_Session_Start");
session_module_name(
Hi,
I am using PHP 4.4.2.. I need a function to copy a file from one server to
another. The src/dst filenames are relative to the Document Root of the website, but
I can build an absolute path name if necessary. I can't use ftp because the
ftp ports are closed on these servers. I would like to use
I am new to PHP but 10 years in C++
One of the cool/powerful things you can do in C++ is the following:
class DrawPlainDialog {
public:
...
virtual Draw(); // implementation draws a vanilla dialog box
};
class DrawStyleDialog : public DrawPlainDialog {
public:
...
virtual Draw(); //
I am new to PHP but 10 years in C++
One of the cool/powerful things you can do in C++ is the following:
class DrawDialog {
public:
...
virtual Draw(); // implementation draws a plain dialog box
};
class DrawStyleDialog : public DrawPlainDialog {
public:
...
virtual Draw(); // impleme
I am new to PHP but 10 years in C++
One of the cool/powerful things you can do in C++ is the following:
class DrawDialog {
public:
...
virtual Draw(); // implementation draws a plain dialog box
};
class DrawStyleDialog : public DrawPlainDialog {
public:
...
virtual Draw(); // impleme
I am new to PHP but 10 years in C++
One of the cool/powerful things you can do in C++ is the following:
class DrawDialog {
public:
...
virtual Draw(); // implementation draws a plain dialog box
};
class DrawStyleDialog : public DrawPlainDialog {
public:
...
virtual Draw(); // implement
That's right, the difference between C++ "pure virtual" and "virtual" is
that a virtual function has an implementation but pure virtual only defines
an interface.
But can we get back to my original PHP question: Can I do something like the
following in php:
class Base {
function Foo() { echo
Ok, I give up.
I want to compare a timestamp(14) field in a MySQL table with the current
time. Currently I use the following pseudo-sql:
select field from table where table.time < date("YmdHis", time())
only, the table timestamp is GMT time and the time function is returning
local time. How do
Sourceforge MySQL JDBC driver
http://mmmysql.sourceforge.net/
maybe this code frag will be helpful...
String connectionURL = "jdbc:mysql://centauri.sbs:3306/dbname";
Connection conn = null;
Statement statement = null;
ResultSet rset = null;
try {
Class.forName("org.gjt.mm.mysql.D
The last post is using the MySQL JDBC from a Java Server Page in a servlet
environment. I never tried to run this from Java imbedded in a PHP script.
You would have to remove the exception handling, at least.
I dispatch a Java Server Page from my php script (write to a socket), do
some java stuff
I am testing user-handling of sessions (mysql database) and just do not understand
this behavior. my SESSION table is created as
CREATE TABLE SESSION (
id varchar(32) NOT NULL default '',
time timestamp(14) NOT NULL,
user_id mediumint(8) NOT NULL default '-1',
data text NOT NULL,
PRIM
I noticed a behavior of my PHP class (4.1.1) which I found very unexpected
and also undocumented. I defined a class constructor, and this constructor
was automatically called *again* on my instantiated object when the script
ended! This runs counter to
1. what one would expect a constructor to
I have a date string, let's call it 'date a' in the format "2020-10-16"
which I want to compare to the UNIX_TIMESTAMP overflow limit ("2038-01-18").
Obviously I can't convert date 'a' to a timestamp because it may be too
large. How can I make this comparision without converting it to a timestamp?
I have Apache 1.3.24, PHP 4.2.0, and Java2SDK installed and working. My
problem is, when I boot up and dispatch my phpTest.php script from my
browser
".$formatter->format(new Java('java.util.Date'));
phpinfo();
?>
I get an error message that the java .so is not found. I start ap
Hi,
I am compiling PHP 4.2.0 on a RedHat 7.1 system with mnogosearch 3.2.3. I am
running into a problem that I have not seen on my other RedHat systems with
the same configuration (except Redhat 7.2 instead of 7.1), and that is that
the link does not work because there are some symbols that are m
I am trying to sort out several technologies and how they fit together. The
basic problem I want to solve is to be able to use BrowserHawk, a JavaBean
by CyScape, from a PHP script. In researching how to do this (and there are
several relevant articles written) I have come across several different
Hi Richard,
I have finally got Java working with PHP. My Java is JSDK 1.4.0, the latest
release of the SDK from Sun. How do I know it's working? I put
$system = new Java("java.lang.System");
print "Java version=".$system->getProperty("java.version")."
\n";
print "Java
>From my experience getting Java to run w/ PHP and Apache on RedHat 7.0, you
can try setting the LD_LIBRARY_PATH environment variable ( without which my
Java would not run) set to the location of libjava.so, libjvm.so, and
php_java.jar, in my case (without line feeds)
LD_LIBRARY_PATH="/usr/java/
Minor point, but you do mean LD_LIBRARY_PATH, not LD_LIBRARYPATH right?
Also, set
[Java]
extension = libphp_java.so
extension_dir = (pathname to libphp_java.so)
Rich
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
This is a behavior I have not found documented, in fact the books I have
read indicated that this would not be the case...
given the script (with session.save_handler = files):
";
}
session_start();
reg();
echo "test=<$test>";
?>
The output is:
in reg(), test=<13>
test=<>
I was quite sur
OK, but then how do you explain:
";
}
global $HTTP_SESSION_VARS;
session_start();
reg();
if (session_is_registered("test")) {
$tt = $HTTP_SESSION_VARS["test"];
echo "session variable test=<$tt>";
}
else
echo "You really don't know what you're doing, do you?";
?>
This still gives me
Then, when
session_register("");
is called (even on a variable which is going out of scope) what actually
happens? Where is the data actually stored? I know it isn't in the file yet
(I have session.save_handler = files) because nothing is written to the file
until the script exits. So the me
I have to build a "bridge page" from my PHP script that does the following:
1. Kick off a Java servlet (in my case running on my Tomcat4 plug-in to
Apache)
2. Receive data back from that servlet and continue my PHP script.
Does anyone have hard won advice, tips on great articles, examples, etc?
When I try to configure PHP 4.1.1 I get the following error:
checking whether to include ming support... no
checking for mnoGoSearch support... yes
checking for mnoGoSearch version... 3.1.19
checking for mSQL support... no
checking for Muscat support... no
checking for MySQL support... yes
config
35 matches
Mail list logo