|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
From: php-general-digest-help
lists.php.netDate: Sun Mar 04 2001 - 15:30:04 CST
php-general Digest 4 Mar 2001 21:30:04 -0000 Issue 547
Topics (messages 42494 through 42525):
Re: Stripping HTML selectively?
42494 by: Steve Edberg
NETSCAPE Screws QUERY STRING!!!!!!
42495 by: Thomas Edison Jr.
42498 by: Meir Kriheli - MKsoft
42499 by: Juanma
Help Please: Php configuration
42496 by: archana sharma
42497 by: Michael Hall
42502 by: Phil Driscoll
PHP & PostgreSQL
42500 by: Marcelo Pereira
42508 by: The Hermit Hacker
Re: Problems with IIS4 (Win2k)
42501 by: Phil Driscoll
Re: Static Classes
42503 by: Alexander Wagner
Re: Content-Type: image/gif and send the image in hex
42504 by: Christian Reiniger
Re: PHP web based mailing list administrator
42505 by: Christian Reiniger
Re: any way to count subscribers to PHP lists?
42506 by: Ned Lilly
newbie---cookie help
42507 by: McShen
Re: Hebrew websites transition with php3 ..
42509 by: Manuel Lemos
42510 by: Manuel Lemos
system() and stdout
42511 by: Michael Robbins
42513 by: Clayton Dukes
How much could you charge for a PHP-MySQL Spanish online course?
42512 by: akio
How big is too big?
42514 by: Joe Sheble (Wizaerd)
file() function
42515 by: Felipe Lopes
Re : [PHP] NETSCAPE screws QUERY STRING
42516 by: Thomas Edison Jr.
42517 by: Julian Wood
42518 by: Thomas Edison Jr.
42521 by: Julian Wood
NETSCAPE screws up query string : more problems!
42519 by: Thomas Edison Jr.
date
42520 by: george
42522 by: Stephan Ahonen
Change the Input to st different..
42523 by: Erdinc Guler
Php, Apache, mysql - make error
42524 by: S Jha
Re: IE 5.5,authentication,PHP sessions: IE never stops
42525 by: Don Read
Administrivia:
To subscribe to the digest, e-mail:
php-general-digest-subscribe
lists.php.net
To unsubscribe from the digest, e-mail:
php-general-digest-unsubscribe
lists.php.net
To post to the list, e-mail:
php-general
lists.php.net
----------------------------------------------------------------------
attached mail follows:
At 09:43 PM 3/3/01 , Erick Papadakis wrote:
>Thanks Brian, I have tried the allowable tags, but I need to remove the
>ATTRIBUTES of a tag, not the tag itself. STRIP_TAGS totally removes the tag,
>and ALLOWABLE_TAGS lets the tag be. WHat I wish to do is let the main tag be
>but remove its attributes, as follows:
>
> Original text:
> <font class="something" style="....">Hi!</font>
>
> Parsed text:
> <font>Hi!</font>
>
>Thanks/erick
Well, in this case, you'd have to use regular expressions. One way to do it
would be:
$SanitizedString =
ereg_replace('<[[:space:]]*([[:alnum:]]+)[^>]*>', "<\\1>", $String);
this _should_ work (haven't tested it). If you wanted to remove some tags
entirely, and then remove the attributes of the remaining tags, you could
(1) use strip_tags() with a list of allowable tags, then (2) run the regexp
above. Incidentally, the above regexp also removes leading spaces from the
tag. Eg, < font style="unreadable"> becomes <font>. If you don't want,
that user the regexp
'<([[:space:]]*[[:alnum:]]+)[^>]*>'
instead.
- steve
>---
>Outgoing mail is certified Virus Free.
>Checked by AVG anti-virus system (http://www.grisoft.com).
>Version: 6.0.230 / Virus Database: 111 - Release Date: 25-Jan-01
+------------------------------------------------------------------------+
| Steve Edberg University of California, Davis |
| sbedberg
ucdavis.edu (530)754-9127 |
| http://aesric.ucdavis.edu/ http://pgfsun.ucdavis.edu/ |
+---------------------- Gort, Klaatu barada nikto! ----------------------+
attached mail follows:
I'm passing variables in a query string to my php
pages. The variables whose values contain spaces due
to multiple words are being passed correctly to the
Internet Explorer browser and are working perfectly
there. However, they are not working at al in NETSCAPE
browser. What should i do?
The Internet Explorer converts the spaces in a query
string into it's hexadecimal value of "%20"
automatically, but netscape is not doing so. It's not
reading the space and thus not displaying the page at
all and giving the HTTP error 400.
This the link i make :
<a href="add_pro_over.php3?title=<? echo $title ?>">
if $title contains "Project", it goes.
But if it contains "Project One" ... it doesn't work
in NETSCAPE.
When on to the next page, this $title also has to be
sent into the Database.
what do i do?
regards,
T. Edison jr.
=====
Rahul S. Johari (Director)
******************************************
Abraxas Technologies Inc.
Homepage : http://www.abraxastech.com
Email : abraxastech
yahoo.com
Tel : 91-4546512/4522124
*******************************************
__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail.
http://personal.mail.yahoo.com/
attached mail follows:
You should use the urlencode() function.
See
http://www.php.net/manual/en/function.urlencode.php
-- Meir Kriheli MKsoft computer systems'There's someone in my head but it's not me" - Pink Floyd ----- Original Message ----- From: "Thomas Edison Jr." <thomasedisonjr
yahoo.com> To: <php-general
lists.php.net> Sent: Sunday, March 04, 2001 2:20 PM Subject: [PHP] NETSCAPE Screws QUERY STRING!!!!!!
> I'm passing variables in a query string to my php > pages. The variables whose values contain spaces due > to multiple words are being passed correctly to the > Internet Explorer browser and are working perfectly > there. However, they are not working at al in NETSCAPE > browser. What should i do? > > The Internet Explorer converts the spaces in a query > string into it's hexadecimal value of "%20" > automatically, but netscape is not doing so. It's not > reading the space and thus not displaying the page at > all and giving the HTTP error 400. > > This the link i make : > <a href="add_pro_over.php3?title=<? echo $title ?>"> > > if $title contains "Project", it goes. > But if it contains "Project One" ... it doesn't work > in NETSCAPE. > > When on to the next page, this $title also has to be > sent into the Database. > > what do i do? > > regards, > T. Edison jr.
attached mail follows:
Try urlencode ...
----- Original Message -----
From: "Thomas Edison Jr." <thomasedisonjr
yahoo.com>
To: <php-general
lists.php.net>
Sent: Sunday, March 04, 2001 1:20 PM
Subject: [PHP] NETSCAPE Screws QUERY STRING!!!!!!
> I'm passing variables in a query string to my php
> pages. The variables whose values contain spaces due
> to multiple words are being passed correctly to the
> Internet Explorer browser and are working perfectly
> there. However, they are not working at al in NETSCAPE
> browser. What should i do?
>
> The Internet Explorer converts the spaces in a query
> string into it's hexadecimal value of "%20"
> automatically, but netscape is not doing so. It's not
> reading the space and thus not displaying the page at
> all and giving the HTTP error 400.
>
> This the link i make :
> <a href="add_pro_over.php3?title=<? echo $title ?>">
>
> if $title contains "Project", it goes.
> But if it contains "Project One" ... it doesn't work
> in NETSCAPE.
>
> When on to the next page, this $title also has to be
> sent into the Database.
>
> what do i do?
>
> regards,
> T. Edison jr.
>
>
>
>
> =====
> Rahul S. Johari (Director)
> ******************************************
> Abraxas Technologies Inc.
> Homepage : http://www.abraxastech.com
> Email : abraxastech
yahoo.com
> Tel : 91-4546512/4522124
> *******************************************
>
> __________________________________________________
> Do You Yahoo!?
> Get email at your own domain with Yahoo! Mail.
> http://personal.mail.yahoo.com/
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
> For additional commands, e-mail: php-general-help
lists.php.net
> To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
Hi All, I am new in PHP world. I am trying to configure my php with IIS4. Here is the info what I downloaded and installed:
php version: php4.0.4 for win32 [2000-12-20] (from http://php4win.de site) Web server: IIS4 But as soon as I do the step of "Add/Edit extension mapping " in IIS4, my webserver crashes. I don't know where I am doing wrong. I followed every step written in the book. Please HELP!!!
If you have answered the questions like this, please point me where can I find the solution or clue. Also is there any way where I can archieve the old message of this board.
Your help is highly appreciated.
Thanks. ...Archana
_________________________________________________________________________ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
attached mail follows:
I don't know a thing about IIS ... but the archives can be found at http://www.php.net/support.php
Good Luck
Michael
On Sun, 4 Mar 2001, archana sharma wrote:
> Hi All,
> I am new in PHP world. I am trying to configure my php with IIS4. Here is
> the info what I downloaded and installed:
>
> php version: php4.0.4 for win32 [2000-12-20] (from http://php4win.de site)
> Web server: IIS4
> But as soon as I do the step of "Add/Edit extension mapping " in IIS4, my
> webserver crashes. I don't know where I am doing wrong. I followed every
> step written in the book. Please HELP!!!
>
> If you have answered the questions like this, please point me where can I
> find the solution or clue. Also is there any way where I can archieve the
> old message of this board.
>
> Your help is highly appreciated.
>
> Thanks.
> ...Archana
>
>
>
>
>
> _________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
> For additional commands, e-mail: php-general-help
lists.php.net
> To contact the list administrators, e-mail: php-list-admin
lists.php.net
>
>
attached mail follows:
I'm guessing that you are adding the ISAPI version of php. If so, try installing it as a CGI instead (set the script mappings to php.exe instead of php4isapi.dll and remove php4isapi.dll from the filters list).
Cheers
-- Phil Driscoll Dial Solutions +44 (0)113 294 5112 http://www.dialsolutions.com http://www.dtonline.org
attached mail follows:
Hi, All.
I have to build a web site and I was studying postgreSQL, but, whether I am quite wrong or this database does not support Foreign Key.
Does anyone use postgreSQL and know how handle Foreign Keys ???
Thanks,
Marcelo Pereira Computer Programmer
__________________________________________________________________________ O BOL é Top10 no iBest! Vote já para torná-lo Top3! http://www.bol.com.br/ibest.html
attached mail follows:
On Sun, 4 Mar 2001, Marcelo Pereira wrote:
> Hi, All. > > I have to build a web site and I was > studying postgreSQL, but, whether I am > quite wrong or this database does not > support Foreign Key. > > Does anyone use postgreSQL and know > how handle Foreign Keys ???
Yes, it supports Foreign Keys ... how to use them is another story, as its something I keep meaning to dive into and just never seem to find the time for :(
Check out:
http://postgresql.readysetnet.com/users-lounge/docs/7.0/user/sql-createtable.htm
which talks about using CONSTAINTS on tables, where 'REFERENCES' is discussed ...
attached mail follows:
>Yeah after a net stop and net start I've got the cgi version working, but I >still can't >seem to get the PHP isapi module up.
This could be a permissions issue on any of the php files (php4ts.dll, php4isapi.dll, php.ini or any extension dlls enabled in php.ini). For test purposes, if you give full control for everyone for these files and it starts to work, then it was a permissions problem.
>What functionality is missing from the CGI version besides http-auth? can it >handle >uploads?
I think that all you miss is some performance and the ability to get at the headers before IIS has already acted on them. This affects authentication and probably some other stuff as well.
You will probably also find that the CGI version is much more reliable than the ISAPI module.
Cheers
-- Phil Driscoll Dial Solutions +44 (0)113 294 5112 http://www.dialsolutions.com http://www.dtonline.org
attached mail follows:
ADnoctum wrote: > Hello to everyone. First time here and already I have a question: PHP > has static classes?. [..] > Test.hello(); > > Now I have a variable "Test" wich is a class that canot be > instantiated nor inherited. Can I do that in PHP?.
PHP has static method calls with class::method() Test::hello();
regards Wagner
-- Assumption is the mother of all fuck-ups.
attached mail follows:
On Sunday 04 February 2001 05:53, you wrote: > Hi all, > > I'm trying to make a demonstration script (using PHP) that demonstrates > the use of MIME types in HTTP headers. It should send the Content-Type > header and than sends an image to the browser in hex.
What do you mean with "in hex"? Hex is a number system. It only exists to make handling binary data easier for humans.
> I run the script in my browser and get the bare decimal values > displayed and not the GIF image:
Aha. So you just want to "send the image".
> I also tried to use: > header("Content-type: image/gif"); > But no success. > I don't want to use the header() function cause it doesn't help my > demostration script show the workings.
Well, you *need* the header ("Content-type: image/gif"); to tell the browser that you're sending a gif. It can not determine that by itself.
If you don't send the header the browser will try to interpret you gif image as HTML code, which usually gives, well, fascinating results :)
> // 7x1 pixel GIF image data > $img = array ( > 0x47, 0x49, 0x46, 0x38, 0x37, 0x61, 0x07, 0x00, 0x01, 0x00, 0xF7, > 0x00, 0x00, 0x00, 0x00, 0x00, > 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x80, 0x80, 0x00, 0x00, 0x00, > 0x80, 0x80, 0x00, 0x80, 0x00,
[...]
> ) ;
> // Write content type to browser > echo "Content-Type: image/gif\n\n"; > > // Write GIF image data to browser > foreach ($img as $val){ > echo $val; > }
Try echo pack ('c*', $img);
Or if that doesn't work:
foreach ($img as $val) { echo pack ('c', $val); }
-- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/)...10001000110101011010101101011110111010113...????
attached mail follows:
On Saturday 03 March 2001 13:59, you wrote: > Yes, they are about. Try hotscripts.com.
And if you don't insist that the manager is written in PHP, try GNU Mailman. It comes with its own /very nice) web-based admin software.
> > does there exist a web based mailing list administrator in PHP (Tying > > in with some open source mailing list software)? > > Ideally, something like egroups (now groups.yahoo.com). I just want > > to be able to easily administrate (or have other people administrate) > > mailing lists. I have access to my own server (linux, php4, ...) > > thanks!
-- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/)...10001000110101011010101101011110111010113...????
attached mail follows:
Thanks to all who responded. Sounds like there's no built-in way for list subscribers to access this info on demand, but this info gives me a baseline.
If anyone has any ideas on how to regularly collect this info, I'd welcome any thoughts. My idea is to try and track subscriber and list activity for certain projects on a running basis, to create kind of a "open source activity index."
There is apparently a command for the list owner, listname-listn
whatever.com ... maybe a hack to ezmlm to allow list members to access it, like majordomo has?
Anyway, thanks again.
Ned
> Subject: Re: [PHP] any way to count subscribers to PHP lists?
> Date: Sat, 3 Mar 2001 16:56:24 -0500
> From: Brian Clark <brianj
fusionwerks.com>
> To: "PHP is not a drug." <php-general
lists.php.net>
>
> Hi Ned,
>
>
9:27:57 AM on 3/3/2001, Ned Lilly wrote:
>
> > Hi, I'm wondering if there's an ezmlm equivalent of the "lists-full"
> > command for majordomo. That command returns data like the
> > following (from the PostgreSQL list):
>
> While not exactly what you wanted, this may provide some of those
> statistics:
>
> http://www.zend.com/cgi-bin/m_stats.pl?list=php-general&date=200101
> http://www.zend.com/cgi-bin/m_stats.pl?list=php-general&date=200102
> http://www.zend.com/cgi-bin/m_stats.pl?list=php-general&date=200103
>
> January 2001, February 2001, and March 2001 respectively.
>
> -Brian
> --
> Please do not carbon copy me on list replies.
>
> --------------------------------------------------------------------
>
> Subject: Re: [PHP] any way to count subscribers to PHP lists?
> Date: Sat, 03 Mar 2001 17:20:01 +0800
> From: "Jim Winstead" <jimw
apache.org>
> To: php-general
lists.php.net
>
> In article <3AA0FF6D.F13302B5
greatbridge.com>, ned
greatbridge.com
> wrote:
> > Hi, I'm wondering if there's an ezmlm equivalent of the "lists-full"
> > command for majordomo. That command returns data like the following
> > (from the PostgreSQL list):
>
> no ezmlm equivalent that i'm aware of, but here's the subscription
> figures for the php lists:
>
> php-announce 3031
> php-beta 333
> php-cvs 134
> php-cvs-digest 1
> php-cvs-daily 525
> php-cvs-daily-digest 3
> php-cvsroot 4
> php-db 1167
> php-db-digest 577
> php-dev 659
> php-general 1914
> php-general-digest 974
> php-gtk 187
> php-gtk-digest 1
> php-i18n 168
> php-i18n-digest 82
> php-install 627
> php-install-digest 366
> php-kb 2556
> php-lang 23
> php-lang-digest 0
> php-migration 133
> php-migration-digest 49
> php-mirrors 33
> php-notes 8
> php-notes-digest 0
> php-pear 377
> php-qa 60
> php-qa-digest 0
> php-template 126
> php-template-digest 15
> php-test 3
> php-windows 544
> php-windows-digest 329
> phpdoc 244
>
> jim
>
attached mail follows:
hi
Please help a newbie.
I have 2 links on my website. It wil show "NEW" if my visitors have only visited my site once in 24h. If my visitors visit my site for more than once in 24h, i wanna show "OLD". I know cookie can do it. but i don't know how, Please help. Any script will be greatly appreciately.
Thank You.
attached mail follows:
Hello Aviv,
On 28-Feb-01 20:07:21, you wrote:
>Hey!
>So what do YOU offer me to do?
>Should I use visual Hebrew (write a php3 script which will reverse Hebrew >words), or should I stick only to Logical Hebrew?
In the ideal world you would figure if the browser supports logical Hebrew or not and would serve pages formatted encoded accordingly. In the ideal world you also would have time and budget to implement alternative content formats, but this may not be what is like in your real world.
Regards, Manuel Lemos
Web Programming Components using PHP Classes.
Look at: acm.org">http://phpclasses.UpperDesign.com/?user=mlemos
acm.org
-- E-mail: mlemosacm.org URL: http://www.mlemos.e-na.net/ PGP key: http://www.mlemos.e-na.net/ManuelLemos.pgp --
attached mail follows:
Hello Boaz,
On 01-Mar-01 04:17:25, you wrote:
>The IE / NN war was one that left no chance for NN in Israel. >While MS spent millions in making all of their products in Hebrew, >including the free IE, NN refused to support Hebrew.
I don't think this is a matter of browser wars. Ideally, portals should target their target audience not the other way arround. If your portal pages can't display in users browsers, they simply go away and won't bother telling you why.
>While the 3% is correct for Israel, it's far from being true on an >international basis.
If you got me right, if your portal only displays right in logical Hebrew, there is no reason for those 3% be just 0% because nobody returns to a portal that does not display in their browser, right?
>With all due respect to people that like other browsers, developing >for all browsers costs lots of $$$ and as long as portals are free >and loosing lots of $$$ it's not profitable to develop for all.
>Bottom line, as the CTO of one of those portals I say go >with Logical Hebrew and dump Netscape (In Israel Only).
Personally I don't care about Netscape. My point was just to bring to the attention that when you think your are just dumping Netscape or whatever browser, what you are actually dumping is share of users that you believe that it is 3% but might be actually much more. I know that over here people assumed that was 10% but was in reality 30%.
In a market like the Internet portals where the winner takes almost all, it may be worthy for you to rethink your options before you realize that your portal is not the winner because your not really evaluating the real user audience figures, but rather those that are technically more convinient.
Just my 0.02 EUR. :-)
Regards, Manuel Lemos
Web Programming Components using PHP Classes.
Look at: acm.org">http://phpclasses.UpperDesign.com/?user=mlemos
acm.org
-- E-mail: mlemosacm.org URL: http://www.mlemos.e-na.net/ PGP key: http://www.mlemos.e-na.net/ManuelLemos.pgp --
attached mail follows:
I am trying to use system() to run an external command and have the output placed into a variable using:
$output = system("/usr/local/bin/somecommand");
the output is placed into $output, and it also places it instream with the HTML. Anyone know why this is happening? or how to properly put data from STDOUT into a variable?
Any help is appreciated.
Mike Robbins
attached mail follows:
You have to have the output as part of the system or exec command, Here's a ping function, maybe this will help:
exec("/bin/ping -c3 $ipaddr", $output, $error); echo "<BR>\n"; while (list(,$line) = each($output)){ echo $line, "<BR>\n"; } if ($error){ die("OS Error: $error. Try using man ping, this also usually boils down to path/permissions."); }
----- Original Message -----
From: "Michael Robbins" <mdrobbins
home.com>
To: <php-general
lists.php.net>
Sent: Sunday, March 04, 2001 11:53 AM
Subject: [PHP] system() and stdout
> I am trying to use system() to run an external command and have the output
> placed into a variable using:
>
> $output = system("/usr/local/bin/somecommand");
>
> the output is placed into $output, and it also places it instream with the
> HTML. Anyone know why this is happening? or how to properly put data from
> STDOUT into a variable?
>
> Any help is appreciated.
>
> Mike Robbins
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe
lists.php.net
> For additional commands, e-mail: php-general-help
lists.php.net
> To contact the list administrators, e-mail: php-list-admin
lists.php.net
attached mail follows:
Hello everyone!
How do you charge these things, per words? The amount of time spent? I've never done this and I'm quite clueless. Any ideas would be really appreciated.
TIA
Regards
attached mail follows:
Is there a practical limit one should make on a php file to be included? I'm putting all my global variable declarations and function defintitions into one file to be included across the site. I had thought about splitting them different files based on functionality, but then I thought it would be easier to maintain one singular file broken down into sections. But I don't want to overtax anything... so what would be a good size limit on included files?
On the same note, is there a practical limit to how much code should be used within an eval() call?
Joseph E. Sheble a.k.a. Wizaerd Wizaerd's Realm Canvas, 3D, Graphics, ColdFusion, PHP, and mySQL http://www.wizaerd.com =================================
attached mail follows:
I found this script on the internet...It's a script of a message
board...My problem is that I just want to display the 30 newer messages
stead of all messages...What do I have to change???
I tried to use the file() function...I know it's possible to do what I
want to with that function, but I don't know how.
Please, help me!!!!!
...............................................................
script:
<?
if ($message)
{
$message = strip_tags($message);
$message = ereg_replace("\r\n\r\n", "\n<P>", $message);
if (get_magic_quotes_gpc())
{
$message = stripslashes($message);
}
$date = date("d/m/Y - h:i a");
$message = "<B>$user </B> -- $date<P> $message <BR><HR>\r\n";
// first read the file into a buffer, if it exists
$textfile = basename($PHP_SELF) . ".comment";
if ($fp =
fopen ($textfile, "r")) // open without complaining
{
$oldmessages =
fread($fp,filesize($textfile));
fclose(fp);
}
// now reopen the file in write mode, with the
// pointer at the head of the file
$fp = fopen ($textfile, "w");
fwrite ($fp, $message);
fwrite ($fp, $oldmessages); // adding back the old messages
fclose ($fp);
}
readfile(basename(($PHP_SELF . ".comment")));
?>
...................................................................
Thank you
Felipe Lopes
MailBR - O e-mail do Brasil -- http://www.mailbr.com.br
Faça já o seu. É gratuito!!!
attached mail follows:
The urlencode() is working fine with an echo statement & normal query string.
But it's NOT working with complex query string in printf() including $myrow[something] being picked up by mySQL db.
this works :
<a href="add_pro_over.php3?title=<? echo urlencode($title) ?>">
this doesn't work :
printf("<a href=\"pro_page1.php3?title='urlencode($myrow[title])'\">")
OR such combinations as given in the manual. I tried out almost all!!!
HELP!!!!
T. Edison jr.
=====
Rahul S. Johari (Director)
******************************************
Abraxas Technologies Inc.
Homepage : http://www.abraxastech.com
Email : abraxastech
yahoo.com
Tel : 91-4546512/4522124
*******************************************
__________________________________________________ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/
attached mail follows:
Try printf("<a href=\"pro_page1.php3?title='".urlencode($myrow[title])."'\">")
J
on 3/4/01 11:55 AM, Thomas Edison Jr. at thomasedisonjr
yahoo.com wrote:
> > The urlencode() is working fine with an echo statement > & normal query string. > > But it's NOT working with complex query string in > printf() including $myrow[something] being picked up > by mySQL db. > > this works : > > <a href="add_pro_over.php3?title=<? echo > urlencode($title) ?>"> > > this doesn't work : > > printf("<a > href=\"pro_page1.php3?title='urlencode($myrow[title])'\">") > > OR such combinations as given in the manual. I tried > out almost all!!! > > HELP!!!! > > T. Edison jr. >
-- Julian Wood Learning Technologies and Digital Media University of Calgary
attached mail follows:
Julian,
i tried this out .... it's giving the single quotes in the value... 'value+value2'
and on the next page where i'm printing the value...the backslashes are also being added in front of single quotes :
\'value value2\'
where can i go from here? this has made the urlencode function to work...only part left now...
T. Edison jr.
--- Julian Wood <woodj
ucalgary.ca> wrote:
>
> Try printf("<a
>
href=\"pro_page1.php3?title='".urlencode($myrow[title])."'\">")
>
> J
>
> on 3/4/01 11:55 AM, Thomas Edison Jr. at
> thomasedisonjr
yahoo.com wrote:
>
> >
> > The urlencode() is working fine with an echo
> statement
> > & normal query string.
> >
> > But it's NOT working with complex query string in
> > printf() including $myrow[something] being picked
> up
> > by mySQL db.
> >
> > this works :
> >
> > <a href="add_pro_over.php3?title=<? echo
> > urlencode($title) ?>">
> >
> > this doesn't work :
> >
> > printf("<a
> >
>
href=\"pro_page1.php3?title='urlencode($myrow[title])'\">")
> >
> > OR such combinations as given in the manual. I
> tried
> > out almost all!!!
> >
> > HELP!!!!
> >
> > T. Edison jr.
> >
>
>
> --
> Julian Wood
> Learning Technologies and Digital Media
> University of Calgary
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail:
> php-general-unsubscribe
lists.php.net
> For additional commands, e-mail:
> php-general-help
lists.php.net
> To contact the list administrators, e-mail:
> php-list-admin
lists.php.net
>
=====
Rahul S. Johari (Director)
******************************************
Abraxas Technologies Inc.
Homepage : http://www.abraxastech.com
Email : abraxastech
yahoo.com
Tel : 91-4546512/4522124
*******************************************
__________________________________________________ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/
attached mail follows:
Where is the string 'value+value2' coming from? $myrow[title]? If it is coming from the db (I'm guessing - it seems a little strange to me that this would be your title, but in this code we're discussing there is no other possible source), and it has slashes in it, you may need to use stripslashes to get rid of the slashes. Also, why are you using printf, but not formatting your string at all? Why don't you just use echo? I assume we're still dealing with this line of code:
printf("<a href=\"pro_page1.php3?title='".urlencode($myrow[title])."'\">")
J
on 3/4/01 12:20 PM, Thomas Edison Jr. at thomasedisonjr
yahoo.com wrote:
>
> Julian,
>
> i tried this out .... it's giving the single quotes in
> the value... 'value+value2'
>
> and on the next page where i'm printing the
> value...the backslashes are also being added in front
> of single quotes :
>
> \'value value2\'
>
> where can i go from here? this has made the urlencode
> function to work...only part left now...
>
> T. Edison jr.
>
> --- Julian Wood <woodj
ucalgary.ca> wrote:
>>
>> Try printf("<a
>>
> href=\"pro_page1.php3?title='".urlencode($myrow[title])."'\">")
>>
>> J
>>
>> on 3/4/01 11:55 AM, Thomas Edison Jr. at
>> thomasedisonjr
yahoo.com wrote:
>>
>>>
>>> The urlencode() is working fine with an echo
>> statement
>>> & normal query string.
>>>
>>> But it's NOT working with complex query string in
>>> printf() including $myrow[something] being picked
>> up
>>> by mySQL db.
>>>
>>> this works :
>>>
>>> <a href="add_pro_over.php3?title=<? echo
>>> urlencode($title) ?>">
>>>
>>> this doesn't work :
>>>
>>> printf("<a
>>>
>>
> href=\"pro_page1.php3?title='urlencode($myrow[title])'\">")
>>>
>>> OR such combinations as given in the manual. I
>> tried
>>> out almost all!!!
>>>
>>> HELP!!!!
>>>
>>> T. Edison jr.
>>>
>>
>>
>> --
>> Julian Wood
>> Learning Technologies and Digital Media
>> University of Calgary
>>
>>
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, e-mail:
>> php-general-unsubscribe
lists.php.net
>> For additional commands, e-mail:
>> php-general-help
lists.php.net
>> To contact the list administrators, e-mail:
>> php-list-admin
lists.php.net
>>
>
>
> =====
> Rahul S. Johari (Director)
> ******************************************
> Abraxas Technologies Inc.
> Homepage : http://www.abraxastech.com
> Email : abraxastech
yahoo.com
> Tel : 91-4546512/4522124
> *******************************************
>
> __________________________________________________
> Do You Yahoo!?
> Get email at your own domain with Yahoo! Mail.
> http://personal.mail.yahoo.com/
-- Julian Wood Learning Technologies and Digital Media University of Calgary
attached mail follows:
Julian, i tried :
<a href=\"pro_page1.php3?title=".urlencode($myrow[title])."\">
instead
<a href=\"pro_page1.php3?title='".urlencode($myrow[title])."'\">
notice the single quote ' missing. And that WORKED!!! It displayed the right value in the next PHP page. Unfortunately there's another problem. it only DISPLAYED the right value...but when it adds the value in the database...it adds with the plus + sign. i.e., it adds : Project+One instead of Project One.
=====
Rahul S. Johari (Director)
******************************************
Abraxas Technologies Inc.
Homepage : http://www.abraxastech.com
Email : abraxastech
yahoo.com
Tel : 91-4546512/4522124
*******************************************
__________________________________________________ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/
attached mail follows:
Can you mark the date when an entry is placed in the db and then get that date to display when the info is pulled out
TIA
george
attached mail follows:
> Can you mark the date when an entry is placed in the db and then get that > date to display when the info is pulled out
I'd put the UNIX timestamp of the entry date into a sort of parallel entry. I don't know how DBs work, (never had a mySQL server to play with =( ) but under a big blanket folder for each entry, you put variables (?) for the timestamp, the general contents of the entry, etc.
Sig for a Day Stephan Ahonen, ICQ 491101 "That's very funny Scotty, now beam down my clothes!" Come back tomorrow for a different sig! Backspace a single "s" to reply by email
attached mail follows:
hi.. my problem is to change some characters from input data coming from a form to something..i mean like : input output ----- ------ i --> y fire --> fyre
Is it possible??
erdinc..
attached mail follows:
HI Gurus,
I am getting this error. I saw few posting for this error and found someone suggesting "-lz" option in Makefile in LIBS option. However, I didn't found this line in apache Makefile. Also I tried other methods including reloading zlib, reconf mysql ..but in vain. Please help. I did - #SSL_BASE=../openssl-0.9.6 RSA_BASE=../rsaref-2.0/local ./configure --enable-module=ssl --activate-module=src/modules/php4/libphp4.a --enable-module=php4 --prefix=/usr/local/apache --enable-shared=ssl
#make
The error message was -
/usr/local/mysql/lib/libmysqlclient.a(my_compress.o): In function `my_uncompress': my_compress.o(.text+0x9a): undefined reference to `uncompress' /usr/local/mysql/lib/libmysqlclient.a(my_compress.o): In function `my_compress_alloc': my_compress.o(.text+0x12a): undefined reference to `compress' collect2: ld returned 1 exit status make[2]: *** [target_static] Error 1 make[2]: Leaving directory `/home/sjha/apache_1.3.17/src' make[1]: *** [build-std] Error 2 make[1]: Leaving directory `/home/sjha/apache_1.3.17' make: *** [build] Error 2
Thanks,
SJ
===== Sanjeev Jha, Unix System Administrator
__________________________________________________ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/
attached mail follows:
On 04-Mar-01 Ken wrote: > Thanks for the idea, John. > > I know about the auth logout. Unfortunately, that means that when a user > clicks "logout", he gets a "log in" prompt! And, in IE, he has to > deliberately blank out the password field, THEN hit enter, THEN the prompt > will come again, and he has to hit escape.
<snip>
> Any suggestions? >
I'm still playing with this but ...
My script handles the authentication against a MySQL table; and this might (probably) have to get tweaked to play well with .htaccess
The logout script creates a "mark" (tmpfile, db entry, whatever) then redirects to a non-protected page.
On entry to a protected script:
function authuser($realm) { global $PHP_AUTH_USER, $PHP_AUTH_PW;
if (isset($PHP_AUTH_USER)) { if (markset($PHP_AUTH_USER)) { markunset($PHP_AUTH_USER); // send a 401 to force re-authenticate Header('WWW-authenticate: basic realm="'.$realm .'"'); Header('HTTP/1.0 401 Unauthorized'); echo "\n\n"; echo '<META HTTP-EQUIV="Refresh" CONTENT="1; URL='.SITEHOME.'/">'; exit; } if (! (validlogin($PHP_AUTH_USER,$PHP_AUTH_PW, $realm))) { Header('WWW-authenticate: basic realm="'.$realm .'"'); Header('HTTP/1.0 401 Unauthorized'); echo '<META HTTP-EQUIV="Refresh" CONTENT="1; URL='.SITEHOME.'/">'; echo '<CENTER>Failed Login<P>Invalid name or password'; exit; } } return(true); }
Regards,
-- Don Read dreadtexas.net -- If you are going to sin, sin against God, not the bureaucracy. God will forgive you but the bureaucrats won't.
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]