Previous Thread
Next Thread
Print Thread
Rate Thread
#102856 06/17/2001 6:08 AM
Joined: Mar 2001
Posts: 9
Junior Member
Junior Member
Offline
Joined: Mar 2001
Posts: 9
Hi!
How to undo the changes of this code:
Code
code:
Thanks a lot in advance smile

Sponsored Links
#102857 06/17/2001 9:59 AM
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
P.I.T.A. / Programmer
Offline
Joined: Sep 2000
Posts: 755
Use CGI.pm instead of readparse. Once you have CGI.pm loaded, you have access to the urlencode method.

--mark


"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
#102858 06/17/2001 12:34 PM
Joined: Mar 2001
Posts: 9
Junior Member
Junior Member
Offline
Joined: Mar 2001
Posts: 9
I don't want to use cgi.pm, because i'm not experienced with it.
Isn't it possible to do this without using cgi.pm?
All i want is a script that changes e.g. '# #' to '%23+%23', what must be simple...

#102859 06/17/2001 1:37 PM
Joined: Feb 2000
Posts: 4,625
Member
Member
Offline
Joined: Feb 2000
Posts: 4,625
ReadParse is old.
Its outdated.
Use CGI.pm, its very easy.

#102860 06/17/2001 1:51 PM
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
P.I.T.A. / Programmer
Offline
Joined: Sep 2000
Posts: 755
Yes, you can do it with substitions, and pack etc.

But you really should learn CGI.pm (its not at all difficult). It is the standard for doing any CGI stuff in Perl.

--mark


"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
Sponsored Links
#102861 06/17/2001 2:02 PM
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
P.I.T.A. / Programmer
Offline
Joined: Sep 2000
Posts: 755
Oops, my bad...it's been a while.

You want CGI.pm's esacape function

use CGI;
my $q = CGI->new;

my $string = '# #';
print $q->escape($string);

outputs:
%23%20%23

Or you could substitute the spaces for pluses first.
--mark


"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
#102862 06/17/2001 2:33 PM
Joined: Feb 2000
Posts: 4,625
Member
Member
Offline
Joined: Feb 2000
Posts: 4,625
Quote
quote:
Thats what i said. wink

#102863 06/24/2001 9:47 AM
Joined: Mar 2001
Posts: 9
Junior Member
Junior Member
Offline
Joined: Mar 2001
Posts: 9
Thanks a lot Mark! Works fine...


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
• Shock Hosting
• Stable Host
• bluehost
• InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,156
Joined: July 2001
Forum Statistics
Forums63
Topics37,583
Posts293,957
Members13,826
Most Online151,614
Nov 14th, 2025
Today's Statistics
Currently Online 3075
Topics Created 0
Posts Made 0
Users Online 1
Birthdays 30
Top Posters
AllenAyres 21,080
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,834
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2026 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.1.0
(Snapshot build 20261026)