Did you look at the function list to see if gethostbyname() or something
similar exists?
On Mon, 2002-01-21 at 01:20, Police Trainee wrote:
> Hello. Can anyone tell me how to resolve an IP into a
> hostname? I've tried $REMOTE_HOST but all i get back
> from it is the ip or blank. Is there another
Hello. Can anyone tell me how to resolve an IP into a
hostname? I've tried $REMOTE_HOST but all i get back
from it is the ip or blank. Is there another
environmental variable i need to use or do i have to
do something more complicated?
thanks so much!
-mark
__
http://www.isi.edu/in-notes/iana/assignments/media-types/media-types has
been a great help for me and will probobally be a great help to a bunch of
other people designing web applications. It's a fairly long list of content
types with their RFC codes and whatnot.
Just thought I'd contribute somet
Try this code. It assumes you are already connected to the database.
Usually, I put that script in something like database.inc and just do an
include.
pid is the picture id. I'll assume you'll have an index or something in your
database setup.
Now, type is based on the extension of the file rea
Just FYI. I posted the forwarded question earlier, but did some more testing.
I was doing some testing tonight when server traffic was low (ie: stop /
restart Apache) and I found out that when register_globals is On, the below
code doesn't work. Is this something to do with the EGPCS and how v
aloo, sorry if this question was already asked before.. :-(
i'm going to insert an image from html form to the mysql
when i'm going to insert it's run good, but when i'm going to select it from mysql,
i've got nothing..
could someone have an advice??
thank you...
Rio Uniwaly
www.prio.mysite.de
e
*light hearted reply* blasphemy! sacrilege!! how can you ask a php mail list
about converting code to another language?? (paraphase coming...) "php is
the one true language and you shall not code any other language before it"
:)
Martin
-Original Message-
From: Andrew V. Romero [mailto:[E
the only way php is going to know about a variable is if the server the
script is on is sent the variable, the normal way of doing that is through
posting/getting a page/script
Martin
-Original Message-
From: Andrew V. Romero [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 21, 2002 2:11
[posted and mailed]
[EMAIL PROTECTED] (Jtjohnston) wrote in
[EMAIL PROTECTED]:">news:[EMAIL PROTECTED]:
> This is the input of a . I don't suppose there is an easier
> way of doing this?
>
> $mydata->KW = str_replace("\r", "", $mydata->KW);
> $mydata->KW = str_replace("\n", "", $mydata->KW);
>
If someone can help with this please examine the following problem...
-
$lefta = array();
$leftid = array();
$top = count($connarray); //connarray is an array of lines from a file with
repeating sections that have value
[EMAIL PROTECTED] (Mehmet Kamil Erisen) wrote in
[EMAIL PROTECTED]:">news:[EMAIL PROTECTED]:
>
> Dear List member,
>
> Plesae forgive me for asking and OT question. Can you please recommend
> an edit program, (Freely downloadable).
>
> Thanks,
Search your local PHP mirror for 'editor'; the
I tried that and strangely it didn't work and using eval() was really my
only solution :(
People told me to od $foo[$bar], $foo['$bar'], $foo["$bar"], $foo[($bar)],
and the manual doesn't seem to mind $foo[$bar], but I dunno. It just wasn't
working, and I was angry and depressed that I wasn't gett
> while (list($opid, $ppid, $amount, $pname) = mysql_fetch_row($res)) {
> $eval = '$temp["'.$pname.'"] = $temp["'.$pname.'"] + '.$amount.';';
> eval($eval);
> $i++;
Whoa... Why not simply:
$temp[$pname] += $amount;
??
-Rasmus
--
PHP General M
After getting very frustrated with arrays, I ended up using eval() in the
following way:
function top10() {
$i = 0;
$res = mysql_query("SELECT orders.pid, products.pid, orders.amount,
products.pname FROM orders, products WHERE orders.uid!='' AND
orders.pid=products.pid") or die(my
Hi list...
I'm new here and was reading all these posts on RTFM.
Heres how I figure it, there are always going to be lazy people asking
advanced (or who they think may be advanced) users of PHP to write out their
code. I know, I used to be one of these people when I was trying to figure
out *gig
I don't know if it's possible because as far as I know
headers are sent immediately upon execution when PHP is
installed as CGI binary. But my question is, if
possible, how can I get cookies to work when PHP has been
installed as CGI binary.
This does NOT work for me:
// start of code
#!/
On 20 Jan 2002, at 20:15, Andrew V. Romero wrote:
> I was wondering if there are any tools to convert PHP to another
> scripting language?
> scripting langauge? I designed this 2000 script and then learned that
> our information systems people would feel a lot more comfortable using
> a langu
I've installed php 4.0.6 and sendmail in two different
servers. I want to use mail() function to send mails,
but as the server with php dosen't have a smtp server
it can't be done. Is there a way to point to my other
server which has sendmail; through php.ini
kancha
_
try this...
I changed
1. the double quotes in "$pattern = ..." to single quotes
2. escaped the "?"
3. used ereg_replace to do everything, dropping the while loop
$content = "http://www.globalhealth.org/text.php3?id=151
adjfladjfajdfkladfjl;kadjf
jlkadjflkajdflkj jad
I was wondering if there are any tools to convert PHP to another
scripting language? I have a script that only uses pretty basic
functions in PHP (arrays, plain variables, nothing exciting- no dB
things or anything like that) and am hoping there are some tools where
you can get the majority of th
Would it be possible to have javascript insert a hidden input tag in the html
and then php could pick it up?
Just an idea,
Andy
Mëòv îçîÎ òsyïn wrote:
> Is it posible to get values from javascript to PHP? Without having to post
> the variables..
>
> Thanks //Mårten
>
> _
check @ www.hotscripts.com
php / scripts and programs / mailing list managers
duh :-)
"Nu Webmaster" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hello,
>
> i need a mailing list manager in php, with which i can send html email and
> store my subscribers
Not sure, the tables are in different databases with different users and
passwords. I will look into it but the answer I got this afternoon
satisfied me :)
Jeff
- Original Message -
From: "Miles Thompson" <[EMAIL PROTECTED]>
To: "Jeff Lewis" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent:
"A script to go to an anchor" - I don't know about that... If you need a
_link_ to go to an anchor then you just need to echo the proper link
(i.e. echo "blah.htm#anchor";). If you want a script to _redirect_ to an
anchor then Emile is right: this is a client-side thing and you either
have to go w
You should probably take a look at each() for that... The functionality is not
the same but it's the only answer I can think of for your question (i.e.
mysql_fetch_row() _returns_ a key-value array while each() _walks_ a key-value
array).
Bogdan
Daniel Alsén wrote:
> Hi,
>
> i am fiddling with
Jeff,
Can you let MySQL do the work for you, with INSERT ... SELECT? Here's the URL"
http://www.mysql.com/doc/I/N/INSERT_SELECT.html
HTH - Miles Thompson
At 06:20 PM 1/20/2002 -0500, Jeff Lewis wrote:
>I am trying to basically copy data from one database to another and am
>wondering if it is p
eh..
if i am not mistaken, that's clientside, and
that's more of an javascript thing than a php thing
"Phil Schwarzmann" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I want a script to go to an anchor in an html page
>
> This doesn't seem to work
>
> in
I want a script to go to an anchor in an html page
This doesn't seem to work
include "blah.htm#anchor";
how is this possible
Thanks!
Phil in baltimore
P.S. Pittsburgh sucks Bill Gates' balls.
Why does it seem that when spoken about XML, PHP is almost always left out?
And why does it seem that every XML based CMS is build in a non-php
language? Are there any XMLCMS OpenSource Classes/Projects available?
Warm regards,
Emile Bosch
--
PHP General Mailing List (http://www.php.net/)
T
you'll need to make them global then...
that's one thing that kept getting me when I started using php, global vars
are only global if you tell them to be sorta like "local to the global
scope" or something like that :)
-Original Message-
From: Tj Corley [mailto:[EMAIL PROTECTED]]
Sen
${$vNames[1]} = "new value"; // look at variable-variables in the manual
for more info
-Original Message-
From: Gaylen Fraley [mailto:[EMAIL PROTECTED]]
Sent: Sunday, January 20, 2002 3:44 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Variable referencing/substitution
How can this be done?
Hi,
A little trick I did to get the text from a textbox in a form
( for user comments ) without the user having to submit it was to
use javascript to append the textbox contents to a url ( GET METHOD )
when the user clicked on a link, which pointed to a redirect script
which extracted the textb
Never worked with mysql but I would assume there's something like 'NOW' or
now() or something similar, don't know how you'd put a different date in
though :(
timestamps are handy within php, you can then convert it to whatever format
you want with date()
or, if you wanted to go even further, cre
Or go to download.com, search for 'PHP'
Sort list by 'number of downloads'.
bvr.
>>> Plesae forgive me for asking and OT question. Can you please recommend an
>>> edit program, (Freely downloadable).
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTE
Wait.. I thought that was a Frequently Asked Question? *grin*
Check out http://marc.theaimsgroup.com/?l=php-general and do a search for
editors and you'll find several strings regarding that topic.
Cheers!
Rick
It is very nearly impossible . . . to become an educated person in a country
so dis
Hi all,
I'm looking to normalise the way in which I work with dates and times,
hopefully saving myself some time and effort along the way.
Currently, for, say, a news post, i'm using a MySQL DATE column
(-MM-DD), but since this isn't all that good (visually) for use on a
site, I find myself
>
>Plesae forgive me for asking and OT question. Can you please recommend an
>edit program, (Freely downloadable).
Search the archive.. this really is a FAQ.
Bye,
B.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-ma
php-general Digest 20 Jan 2002 23:34:28 - Issue 1123
Topics (messages 81261 through 81295):
Re: Upload & View Image
81261 by: Malte Fucks
81277 by: Jason Wong
eval()
81262 by: Kunal Jhunjhunwala
81263 by: Michael Waples
81264 by: Kunal Jhunjhunwala
Hi,
If Call-time pass-by-reference has deprecated
so long ago, why are the instructions on how
to do it still in the manual?
http://www.php.net/manual/en/html/functions.arguments.html#functions.arguments.by-reference
At least it should point out that it has been
deprecated.
Bruce
___
Dear List member,
Plesae forgive me for asking and OT question. Can you please recommend an edit
program, (Freely downloadable).
Thanks,
Erisen
Mehmet Erisen
http://www.erisen.com
-
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail.
In a word... No.
Well...
No.
Mårten Andersson wrote:
> Is it posible to get values from javascript to PHP? Without having to
> post the variables..
>
> Thanks //Mårten
>
> _
> Chatta med vänner online, prova MSN Messenger: htt
It;'s entirely possible. Most database-related functions can take an
optional link identifier parameter. You didn't use it, and in that case,
database operations default to the last opened database connection. You
can however do something like:
$dblink1=mysql_connect($server1,$user1,$password1
Just as DL Neil implied, your variables are outside the scope of the
function. set them global within your function.
See: http://www.php.net/manual/en/language.variables.scope.php
- Original Message -
From: "Tj Corley" <[EMAIL PROTECTED]>
To: "DL Neil" <[EMAIL PROTECTED]>
Cc: <[EMAIL PR
I am trying to basically copy data from one database to another and am
wondering if it is possible to have more than one database open at a time.
So for example, I want to do something like this but am wondering if there
is a better way:
$dbcon = mysql_connect($db_server, $db_user, $db_passwd);
they are in the same script outside the function.
all the admin functions reside in a admin_func.php
with the $db_host, etc, etc variables assigned before it.
- Original Message -
From: "DL Neil" <[EMAIL PROTECTED]>
To: "Tj Corley" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Sunday
Tj,
> I am really baffled by this problem. I have tried so many things to get
> this working but to no avail. Here is the
> actual code:
>
> function verify_user($username, $password){
> $conn = mysql_connect($db_host, $db_user, $db_pass) or
...
> Anyways the problem is I cannot get it to ev
I am really baffled by this problem. I have tried so many things to get
this working but to no avail. Here is the
actual code:
function verify_user($username, $password){
$conn = mysql_connect($db_host, $db_user, $db_pass) or
die("Error while connecting to Database System.");
$select_db
Is it posible to get values from javascript to PHP? Without having to post
the variables..
Thanks //Mårten
_
Chatta med vänner online, prova MSN Messenger: http://messenger.msn.se
--
PHP General Mailing List (http://www.php.net/
Hey List-
Banging my head again the wall with this one. One of our developers was
trying to get some session stuff to work and he couldn't and asked me to look
into it.
I have a script that contains the following (the sessions.php href reference
is the same script accept it calls this one):
try out first before u post...
what does work is..
mail(implode(false,file("blah.txt")));
"Kyle Smith" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Is it possible to use include inside the mail function?
eg
mail(include("blah.txt")) ???
-lk6-
http://www.S
Hi,
i am fiddling with a script and need to change a while-loop from running on
mysql_fetch_array to a "normal" array?
ie - i have:
while($myrow=mysql_fetch_array($result)) { etc...
But i want the loop to run with an array i created earlier ($anotherarray =
[key1] => value1, [key2] => value2).
Hi!
You can find the PHP !manual! at http://www.php.net/manual
Try searching for open , opendir, readdir .. or whatever other function
you're looking for.
If that doesn't give you an answer straight away, you could go back to the
manual index and find the appropriate category, like Filesystem
Hi,
i know i have this answered before. But i can´t find that mail in the
archive.
How do i print an array to see both the structure and the data within?
("test" => "value", "test2" => "value2")...
# Daniel Alsén| www.mindbash.com #
# [EMAIL PROTECTED] | +46 704 86 14 92 #
# ICQ: 63006462
Thanks. I knew that - really. Meltdown upstairs :)
- D
> -Ursprungligt meddelande-
> Från: Jason Wong [mailto:[EMAIL PROTECTED]]
> Skickat: den 20 januari 2002 18:53
> Till: Daniel Alsén; PHP List
> Ämne: Re: [PHP] Number of rows reurned?
>
>
> On Monday 21 January 2002 01:45, Daniel Als
ooh... i dont know if i understood you correctly..but if i did, you simply
have to insert the location of the file in the users tupel like..
UserIDNameBlaBlapicture
001 John ... ... ./images/john.jpg
preferably i would only store the location when the user
On Monday 21 January 2002 01:45, Daniel Alsén wrote:
> Hi,
>
> how can i get the number of rows reuturned by this query?
>
> $sql = "select date from statistik where shooter='$shooter_login' group by
> date";
>
> I want to add a page function and limit the returned rows on each page -
> but i can´
On Saturday 20 January 2001 19:39, Malte Fucks wrote:
> To control the size of an image is a matter of your HTML... do something
> like
> . Its even possible to
> insert height and width-values in percent...
This only sets the display size of the image *after* the whole image
(whatever size it
Hi,
how can i get the number of rows reuturned by this query?
$sql = "select date from statistik where shooter='$shooter_login' group by
date";
I want to add a page function and limit the returned rows on each page - but
i can´t get the total number of rows.
Regards
# Daniel Alsén| www.min
On Monday 21 January 2002 01:26, Thomas Edison Jr. wrote:
> Malte,
>
> Thanks a lot. I was going through the File Upload
> Functions in the manual and i think that's what they
> were talking about too.
>
> Now there's just one thing. I can run the upload
> scripts and get the image for display too
I'm trying to get gnupg (OpenPGP) working on my system, which is Solaris 2.6
on Sparc, with PHP 4.0.6 and Apache/Stronghold.
I have the program compiled, as it works at the command line. Here's what
works at the command line:
/usr/local/bin/gpg --encrypt -ao /usr/local/www/htdocs/777/crypted -r
Malte,
Thanks a lot. I was going through the File Upload
Functions in the manual and i think that's what they
were talking about too.
Now there's just one thing. I can run the upload
scripts and get the image for display too. But like i
mentioned, this is for a PenPal system, a database
based Pe
hi. im new. i installed a login script on my site and after a few days, it
stopped working. i reinstalled it and it still refused to work after a dew
days. can anyone send me a good login script preferably with no MySql? im
very busy atm with all my school stuff.
Thanks
aron
_
Hi to the list, i´m new...
well.. i do a Flash SendMail with variables and HTML format.
it works.. but i insert variables in the HTML Message code.. and it don´t
works...
i don´t know why
the code is..
Birthday Reminders for August
Sugerencias
y Comentarios mandado desde la página de
T
Good morning everyone,
I'm trying to adapt existing php code that uses a while loop to scan content
for a url pattern, take the matches and add link tags () around them so
the url with be made into "hot links. Simple enough right? Nevertheless, I
seem to be having trouble with urls that have ques
I would like to checkout some xml and xsl files from cvs and transform them
using php script. The second part seems easy, but how can I checkout cvs
module from php script. I tried system("cvs -d /home/cvs checkout myModule")
but there was no result. There was no error either. I am shure it is qui
Hi everybody,
I've finally been able to read the e-mails sent by the little script I was
using.
The problem was the address where the script was trying to send the e-mail.
Instead of a *normal* e-mail (i.e. [EMAIL PROTECTED]) like was written in
the book I wrote my *local* address (mitch@localhos
> I don't see how you can avoid putting php code in templates because you
> need to put $var in there some way so you can print out the variable. So
> if it's in a database it needs some eval() done on it.
You could html comment lines?? I tried this.. but it would only consider the
first and the
Kunal Jhunjhunwala wrote:
>
> Hey,
> I tend to agree with you. But what is the most effiecent way of using php
> code in template files then? I am not going to move my templates to a
> dbase.. thats for sure.
> Regards,
> Kunal Jhunjhunwala
well for looping through the results of a sql query whe
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
* On 20-01-02 at 13:26
* Kunal Jhunjhunwala said
> Hey,
> I tend to agree with you. But what is the most effiecent way of using php
> code in template files then? I am not going to move my templates to a
> dbase.. thats for sure.
The point of
Hey,
I tend to agree with you. But what is the most effiecent way of using php
code in template files then? I am not going to move my templates to a
dbase.. thats for sure.
Regards,
Kunal Jhunjhunwala
- Original Message -
From: "Michael Waples" <[EMAIL PROTECTED]>
To: "Kunal Jhunjhunwala"
Kunal Jhunjhunwala wrote:
>
> Hey
> Does anybody know if its wise to use eval() ? I know Vbulletin uses it.. but
> there is something about it I just cant digest.. it seems to be a very
> powerfull function which can be very easily exploited... anyone else have
> any thoughts?
> Regards,
> Kunal
Hey
Does anybody know if its wise to use eval() ? I know Vbulletin uses it.. but
there is something about it I just cant digest.. it seems to be a very
powerfull function which can be very easily exploited... anyone else have
any thoughts?
Regards,
Kunal
--
PHP General Mailing List (http://www.
oops... should be if($yourfile) instead of if($file)... sorry
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]
php-general Digest 20 Jan 2002 11:34:06 - Issue 1122
Topics (messages 81252 through 81260):
Re: RTFM
81252 by: B. van Ouwerkerk
81254 by: Miles Thompson
Re: application variable
81253 by: Joe Van Meer
Variable referencing/substitution
81255 by: Gaylen Frale
I think the PHP image functions aren't what this guy needs...
First thing : File Uploads
You have to make a form, including an
tag, which refers to a php script like...
$yourfile_size includes the size of the file in bytes, use an if-statement
to check if the picture-size fits your needs...
$
On Sunday 20 January 2002 14:42, Thomas Edison Jr. wrote:
> Hi,
>
> I have a penpal system running on a site. I want to
> add a feature wherein the person can upload his image
> and when somebody views the PenPal list, the uploaded
> image is shown next to his ad.
>
> Can we also control the Imag
76 matches
Mail list logo