php-general Digest 27 Jan 2002 15:12:56 -0000 Issue 1136

Topics (messages 82263 through 82287):

Re: Get FILE NAME and EXTENSION??
        82263 by: Jason Wong

Re: Control Panel
        82264 by: Miles Thompson
        82281 by: Chris Kay

Re: PHP and XHTML
        82265 by: Tom Rogers

Re: Any Ideas
        82266 by: Alok K. Dhir

Arrrr The Space is gone.
        82267 by: Philip J. Newman
        82269 by: CC Zona
        82270 by: Philip J. Newman
        82271 by: CC Zona

Re: getting a LAMP job in this economy
        82268 by: michael kimsal
        82275 by: Chris Lott
        82276 by: michael kimsal
        82277 by: John Lewis

what's equivalent of DBI quote
        82272 by: Peter J. Schoenster

On the fly unzipping
        82273 by: sean.interconnect.is.it

PHP in the University and Corporation [was RE: [PHP] Computer Sci ence and PHP]
        82274 by: Chris Lott
        82286 by: Mike Frazer

Re: Correct URL's
        82278 by: David Robley
        82282 by: Dave Brotherstone
        82285 by: Alan McFarlane

Re: date and time triggerring
        82279 by: David Robley

Re: eval()
        82280 by: Jason Wong

CGI vs. ISAPI
        82283 by: Benjamin deRuyter
        82284 by: David

Re: php login scripts
        82287 by: John Cuthbert

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message ---
On Sunday 27 January 2002 11:10, Dani wrote:
> Hi everyone!
>
> I'm trying to put  file names into variables which later I put into my
> DB (MySQL) as text (only the filename and the extension).
>
> I tried to use the upload format form before:
> <form ENCTYPE=\"multipart/form-data\" ...>
>
> ....
>
> <input type = FILE  name =\"file_name\"....>

>
> .....
>
> When I retrived the value of the variables, I did not get the FILE NAME
> and the file extension.
> What I got is all the path of the file and the file name changed into
> .TMP or some sort.
>
> How do I retrived file names and it's extension in this situation?

Please read the manual chapter "Handling file uploads"


-- 
Jason Wong -> Gremlins Associates -> www.gremlins.com.hk

/*
        "Are you sure you're not an encyclopedia salesman?"
        No, Ma'am.  Just a burglar, come to ransack the flat."
                -- Monty Python
*/
--- End Message ---
--- Begin Message ---
Spare us!!!!1

Miles Thompson

On Saturday 26 January 2002 09:39 pm, karthikeyan wrote:
> Hi Guys,
>
>   I want a affordable and the best control panel for my website.  Though i
> can make it myself but it make some time to do that.  Do any of you guys
> and gals know about this do let me know.
>
>   Looking forward for yours earliest reponse.
>
> karthikeyan.
--- End Message ---
--- Begin Message ---
Love the rsponce Miles....

If you could make it then make it....

I mean what use would a control panel be on a website, why on earth
Would you want suck features as "Add / Remove Programes" and "Internet
Options"
On a website :)...

If you want it to be the best then a pre built script(s) is not going to
be good for you,
Because the best would have all features you need and more and something
out there is not made for you alone.

Building it would be your best choice...

Regards
        Chris Kay

-----Original Message-----
From: Miles Thompson [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, 27 January 2002 1:52 PM
To: karthikeyan; [EMAIL PROTECTED]
Subject: Re: [PHP] Control Panel


Spare us!!!!1

Miles Thompson

On Saturday 26 January 2002 09:39 pm, karthikeyan wrote:
> Hi Guys,
>
>   I want a affordable and the best control panel for my website.  
> Though i can make it myself but it make some time to do that.  Do any 
> of you guys and gals know about this do let me know.
>
>   Looking forward for yours earliest reponse.
>
> karthikeyan.

-- 
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]



--- End Message ---
--- Begin Message ---
Hi
use single quotes and it is simpler

echo '<?xml version="1.0"?>';

Tom
At 09:40  27/01/02, Frans Englich wrote:

>This works just perfectly:
>
>  <?echo("<?xml version=\"1.0\"?>"); ?>
>
>
>  regards,
>  Cyth
>
>  ---------------------------
>
>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>
>* and then Jeff Sheltren blurted....
>
> > Hi.  Have you tried something like:
> >
> > <? echo("<? xml version=\"1.0\" ?>\n"); ?>
>
>*Good* idea, tell us if it works!
>
>- --
>
>Nick Wilson
>
>Tel:    +45 3325 0688
>Fax:    +45 3325 0677
>Web:    www.explodingnet.com
>
>
>
>-----BEGIN PGP SIGNATURE-----
>Version: GnuPG v1.0.6 (GNU/Linux)
>
>iD8DBQE8UzhFHpvrrTa6L5oRAtEiAJ0b1D5tHcQMSpWCitYvIbmiHpkvpgCgkONa
>lBx9rwVVindWYbIifw4EyVs=
>=WHxj
>-----END PGP SIGNATURE-----
>
>
>--
>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]

--- End Message ---
--- Begin Message ---
Regula

        $string=preg_replace("/\W/","",$string);

\W = "non-word" characters in perl regular expressions.  Word characters
are 0-9, a-z, A-Z, and "_".   To kill _ as well, do:

        $string=preg_replace("/[_\W]/","",$string);

        

> -----Original Message-----
> From: 
> [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED].
net] On Behalf Of qartis
> Sent: Saturday, January 26, 2002 3:22 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Re: Any Ideas
> 
> 
> I'm guessing something along the lines of:
> 
> --
> $string=str_replace("!","",$string);
> $string=str_replace("@","",$string);
> $string=str_replace("#","",$string);
> $string=str_replace("$","",$string);
> $string=str_replace("%","",$string);
> $string=str_replace("^","",$string);
> --
> 
> etc.
> 
> 
> "Philip J. Newman" <[EMAIL PROTECTED]> wrote in 
> message 003d01c1a6a5$fa7d60e0$0401a8c0@philip">news:003d01c1a6a5$fa7d60e0$0401a8c0@philip...
> Any Ideas how I can remove   !@#$%^&*()_+=-';:"/.,<>? 
> charactors from a
> string?
> 
> Philip J. Newman
> Philip's Domain - Internet Project. 
> http://www.philipsdomain.com/ [EMAIL PROTECTED]
> Phone: 
> +64 25 6144012
> 
> 
> 
> 
> -- 
> 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]
> 
> 

--- End Message ---
--- Begin Message ---
$q=preg_replace("/[_\W]/","",$q);

I have this to remove all the bad things, but it takes out the space to ... )o; why?

Philip J. Newman
Philip's Domain - Internet Project.
http://www.philipsdomain.com/
[EMAIL PROTECTED]
Phone: +64 25 6144012
--- End Message ---
--- Begin Message ---
In article <002801c1a6ed$1a9c10a0$0401a8c0@philip>,
 [EMAIL PROTECTED] (Philip J. Newman) wrote:

> $q=preg replace("/[ \W]/","",$q);
> 
> I have this to remove all the bad things, but it takes out the space to ... 
> )o; why?

There's a space in your character class, so of course it will be among the 
characters matched/replaced.  But merely deleting it from the character 
class doesn't solve the problem either, since a space character also meets 
the criteria for "not a word character" (\W).  If the objective is to strip 
all characters that are neither a space nor a "word" (a-zA-Z0-9_), then try:

$q=preg replace("/[^ \w]/","",$q);

-- 
CC
--- End Message ---
--- Begin Message ---
This returns an error

$q=preg replace("/[^ \w]/","",$q);

Parse error: parse error in d:\hosting\http\philipsdomain\config.php on line
41

Suggestions?

----- Original Message -----
From: "CC Zona" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, January 27, 2002 6:15 PM
Subject: [PHP] Re: Arrrr The Space is gone.


> In article <002801c1a6ed$1a9c10a0$0401a8c0@philip>,
>  [EMAIL PROTECTED] (Philip J. Newman) wrote:
>
> > $q=preg replace("/[ \W]/","",$q);
> >
> > I have this to remove all the bad things, but it takes out the space to
...
> > )o; why?
>
> There's a space in your character class, so of course it will be among the
> characters matched/replaced.  But merely deleting it from the character
> class doesn't solve the problem either, since a space character also meets
> the criteria for "not a word character" (\W).  If the objective is to
strip
> all characters that are neither a space nor a "word" (a-zA-Z0-9_), then
try:
>
> $q=preg replace("/[^ \w]/","",$q);
>
> --
> CC
>
> --
> 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]
>
>
>



--- End Message ---
--- Begin Message ---
In article <004d01c1a6f2$cb909070$0401a8c0@philip>,
 [EMAIL PROTECTED] (Philip J. Newman) wrote:

> This returns an error
> 
> $q=preg replace("/[^ \w]/","",$q);
> 
> Parse error: parse error in d:\hosting\http\philipsdomain\config.php on line
> 41
> 
> Suggestions?

I think ezmlm must strip underscores from messages, 'cuz a lot of posts 
(though, oddly, not all...) seem to be missing them from otherwise 
valid/functioning code.  The function is named "preg_replace" (an 
underscore between the words), not "preg replace" (with a space).

-- 
CC
--- End Message ---
--- Begin Message ---
Manuel Lemos wrote:

You seem to be just a bit 'doom and gloom'.  Perhaps you're just in 
'realist' mode, but I don't think it's a 'fait accomplit' just yet.

> 
> Since the massive bankrupcy of many Internet companies, LAMP is no
> longer so much on demand. What happened is that most of those companies
> were technologically aware of the choices and were choosing LAMP
> products because they have proven suitability for Internet development
> and besides that they are inexpensive.
> 
> Many of the technology dependent companies that survived do not depend
> on the Internet. Often Web development is for internal consumption. Many
> of those companies used Microsoft products. People in charge of those
> companies often only know about Microsoft's and other comercial products
> that are well marketed. So, it is very hard to penetrate in those
> companies with LAMP products.
> 
> There are certainly a reasonable number of companies that use LAMP
> products, but they do it mostly for economical reasons. Therefore they
> don't have a great budget to pay good salaries either.


True to some extent, but its not always purely economic.  There are real 
security threats in MS stuff (previous at least).  Even if W2k and XP 
are 100% safe, their reputation preceeds them and it'll be a long time 
before MS overcomes that reputation.


> 
> For bigger companies, one of the main limitations of PHP and other Open
> Source products is that, unlike commercial competitor products, they do
> not add as much business value to somebody selling PHP solutions because
> PHP costs nothing so there is no profit margin to earn by the people
> that want to sell it even as a part of something else.
> 


I somewhat need to take exception to this - I think.  Perhaps this is 
just semantics, but people selling products are doing just that - 
selling products.  Whatever they are based on is somewhat immaterial.  I 
can't 'markup' PHP (a language) NOR can I 'mark up' Java (another 
language).  People are building packages on top of Java and selling the 
packages.  I'm not saying the underlying language is completely 
immaterial - there are pros and cons to Java, PHP, Perl and other 
languages.  But simply because it's 'open source' doesn't mean you can't 
add business value in PHP solutions.

It's hard, I think in part, because of the reputation PHP is getting in 
some circles.  Many of the people evangelizing it don't know anything 
else, and simply extoll all the 'wonderful' virtues of it.  No sarcasm 
meant - it's a great platform.  But it has its limitations.  When people 
with more experience come across PHP proponents, more often than not 
they get bombarded with half-truths and anti-MS stuff.  There's always 
at least a grain of truth, but it's often not enough, or not presented 
properly.

The fact is, most languages have these enthusiasts - it's a good thing 
to have them.  However, other languages usually also have big marketing 
dollars behind them.  Notice I said 'big.  Other competing 'platforms' 
such as ihtml and htmlos are hardly even on anyone's radar because (1) 
they cost money and (2) they don't have enough marketing muscle to go up 
against MS, Allaire, Sun, etc.    PHP AT LEAST has 'free' on its side.



> PHP needs to be better marketed or else it will fade from the well paid
> job world. As I said, Java jobs are much more well paid, not only
> because Java is harder to program and requires better prepared
> developers, but also because Sun marketed Java so well that it was
> created a demand for Java projects that nobody from the PHP world is
> doing anything like that.
> 


It's not that no one is doing anything like Java projects.  We've done 
some immensely large projects in PHP (migrated from ASP no less) 
handling commerce transactions in excess of 7 figures per month. 
Needless to say, the client is happy, and they actually had a similar 
sized project done in Java with a large team of developers which 
completely and utterly flopped (only after the 30+ consultants had been 
paid for months of work which was simply shut down).

People don't KNOW about what projects are going on, large OR small. 
I've asked repeatedly in the past for success stories (large and small) 
to register at phpshowcase.com, but I get barely one reply whenever I 
ask.  Perhaps NO ONE is actually using it?  I know that's not true, even 
though the successes are probably more often than not small ones. 
Someone able to get up a dynamic page in a few hours of poking around 
rather than shelling out for Access and slogging through ASP, for 
example.  Not a big success, but the company gets to continue on with 
its plans - probably oblivious to the fact that PHP is being used.  It 
just gets in and works (similar to the 'stealth' success of Linux in 
many organizations, I'd think).




> Despite PHP can be used for more than just Web applications, many PHP
> developers are not making an effort to advertise it for more than just
> Web development. This needs to be changed, because the world has changed
> and those that don't adapt will not survive.
> 
> Java was also advertised initially for browser applets but Sun had to
> adapt the strategy to the needs of the real world, they advertised and
> made it suitable for mobile computing, server side Web scripting and Web
> services. Mobile computing is a closed market. Server side scripting is
> the only thing that PHP is advertised for but its position is seriously
> threatned. Web services, PHP is not yet quite there nor there is a
> perspective if and when it will ever be.
> 


I think part of the reason that the shift with Java occurred is because, 
frankly, Java applets basically sucked in browsers.  Slow, not very 
useful (sandboxes, so I couldn't access files, etc).  Writing Java 
'applications' is even harder, because you don't know what JVM people 
have (or if they have) and need to tell them to download it, how to 
install the application, set JAVAPATH, etc.  It's a pain.  I've OFTEN 
said if Sun REALLY was serious (and I don't think they really are - I 
think they're still primarily a hardware oriented company) they'd carpet 
bomb the US ala AOL with CDs of the latest JVM, an autorun installer for 
Windows, and some useful Java applications that truly demonstrate to the 
average Joe sixpack WHY Java is useful to them - break the 'windows is 
everything' mentality.  They won't do that, however.



> I don't want to be pessimistic, but in a couple of weeks .NET will be
> officially released as the big thing that Microsoft will make it echo
> everywhere with their raw marketing power. ASP.NET is catching up on the
> huge delay that it used to had compared to PHP and other alternatives.
> Web Services will be even more hyped than today.


In a worst case scenario, PHP will most likely adapt to the SOAP stuff 
and cling to a percentage of the "non-MS" market with Java and others.

> 
> Microsoft will try to make it evident that .NET is the most profitable
> way to make money from Web development but only using .NET. It does not
> matter how much of that will be effectively true. What matters is many
> people that today still fall for LAMP/WAMP will reconsider and move to
> .NET world because they will be convinced that is where they can make
> money unlike with LAMP.
> 


You can make money in either camp - it's probably easier in the 
Windows/ASP world in some cases because you've got the marketing muscle 
of $x billions on your side.  MS is *creating* the demand for web 
services, not because they have the technology, but the marketing.  Many 
of the issues the .net and passport platform is addressing were things I 
and others were thinking of years ago - 97-98 at least.  In the MS shop 
I was in at the time, the reaction was "well, MS will be addressing that 
in the next version of <whatever> so we'll just wait for that".  They 
KNEW we had issues we could AT THAT TIME but chose to wait for MS to 
come and do it for them.

Unfortunately, I see that more and more people may be turning that way 
because for the short term it can be good money.  I don't know too many 
smaller companies which have been successful over the long haul dealing 
with MS in a 'web' sense.  The companies I know overpromise ASP stuff, 
deliver half-assed 'solutions', deal with the client for some months or 
a year 'fixing' things, then the client leaves for something else (often 
another MS shop but not always) and the original shop starts afresh. 
Whether it's simply their own incompetence or a fundamental mindset in 
all MS shops, I can't say.


> So, what do you do? For now, I just advise you to stay where you are if
> you can live from what you are doing because we have to see how much of
> this will become true. Anyway, I am afraid that part of it will become
> true as advertised. If you want to stick with LAMP/WAMP, you'd better
> check it out to see if you can developed what will be in demand. Here
> some buzzwords to pay more attention: Web services, SOAP, WSDL, UDDI.


They've been buzzwords for awhile tho.  So has XML, which still doesn't 
seem to be making a huge impact on its own.  As the foundation for 
SOAP/XMLRPC, etc yes.  But I'm not sure most developers will HAVE to 
know SOAP anymore than they know HTTP - there will be libraries which 
accomplish much of the menial stuff for them.  For the dedicated few who 
learn the ins and outs, there may be stronger demand for 'under the hood 
' work - is that what you meant?


Michael Kimsal
http://www.tapinternet.com/php
PHP Training Courses
734-480-9961


--- End Message ---
--- Begin Message ---
> It's hard, I think in part, because of the reputation PHP is 
> getting in 
> some circles.  Many of the people evangelizing it don't know anything 
> else, and simply extoll all the 'wonderful' virtues of it. 

YES! This "poisoning of the well" has happened and continues to happen. The
problem is that being an evangelist is a wonderful thing-- but you have to
be quite skilled at communication to be a successful one :) Otherwise the
person attempting to spread the gospel simply becomes looked at as an
annoyance or, worse, becomes marginalized.

I have dealt with a lot of folks in companies who have a negative view of
PHP, MySQL, Linux, BSD, etc. simply because they have had their intelligence
insulted, or been irritated, or been completely confused, or been preached
to one too many times by well-meaning proponents of Open Source solutions
who are either unable to communicate or simply victim to their own
enthusiasm.

There is probably nothing that doesn't have an Open Source solution in the
abstract sense-- but in the real world of existing systems, personnel, and
politics, the best solution may not be technically the fastest or even the
most stable. The right tool for the job is my motto, and that might mean SQL
Server, it might mean MySQL. It might mean a Linux server, it might mean
Win2K. There is no single panacea.

c
--
Chris Lott
http://www.chrislott.org/ 
--- End Message ---
--- Begin Message ---
Chris Lott wrote:

>>It's hard, I think in part, because of the reputation PHP is 
>>getting in 
>>some circles.  Many of the people evangelizing it don't know anything 
>>else, and simply extoll all the 'wonderful' virtues of it. 
>>
> 
> YES! This "poisoning of the well" has happened and continues to happen. The
> problem is that being an evangelist is a wonderful thing-- but you have to
> be quite skilled at communication to be a successful one :) Otherwise the
> person attempting to spread the gospel simply becomes looked at as an
> annoyance or, worse, becomes marginalized.
> 
> I have dealt with a lot of folks in companies who have a negative view of
> PHP, MySQL, Linux, BSD, etc. simply because they have had their intelligence
> insulted, or been irritated, or been completely confused, or been preached
> to one too many times by well-meaning proponents of Open Source solutions
> who are either unable to communicate or simply victim to their own
> enthusiasm.


Right on.   It's doing far more damage than all the stuff MS, Sun, 
Allaire and others can conspire to throw at our community, imo.

Perhaps we should get together on a 'PHP advocacy HOWTO' ?  :)

> 
> There is probably nothing that doesn't have an Open Source solution in the
> abstract sense-- but in the real world of existing systems, personnel, and
> politics, the best solution may not be technically the fastest or even the
> most stable. The right tool for the job is my motto, and that might mean SQL
> Server, it might mean MySQL. It might mean a Linux server, it might mean
> Win2K. There is no single panacea.
> 


Amen - except that you need to be able to discern WHY something is 
'right'.  If a consultant tells one of my clients that SQL Server is the 
way to go, I have to explain to my client (1) the benefits/drawbacks of 
SQL Server and (2) whatever other agenda that consultant may have. 
What's the 'best tool' for HIM/HER may not be for us.  I've come across 
this more times than I care to recall.

And yes, our recommendations are loaded towards what's best for us, no 
doubt, but we generally have price on our side to start with (lower or 
no licensing fees) and a satisfied clients who've 'taken the PHP plunge' 
before them, so they don't feel like they're the first ones trying this 
'new fangled PHP stuff'.

Michael Kimsal

http://www.tapinternet.com/php
PHP Training Courses
734-480-9961


--- End Message ---
--- Begin Message ---
I like this view. It's not so much a technology we're all speaking as much
as a language. Computers are computers and while linux is fun and kick's ass
sometimes you just need to get a job done. 

tools are tools and php rules until php rules!


john l

>> It's hard, I think in part, because of the reputation PHP is 
>> getting in 
>> some circles.  Many of the people evangelizing it don't know anything 
>> else, and simply extoll all the 'wonderful' virtues of it. 
> 
> YES! This "poisoning of the well" has happened and continues to happen.
> The problem is that being an evangelist is a wonderful thing-- but you
> have to be quite skilled at communication to be a successful one :)
> Otherwise the person attempting to spread the gospel simply becomes
> looked at as an annoyance or, worse, becomes marginalized.
> 
> I have dealt with a lot of folks in companies who have a negative view
> of PHP, MySQL, Linux, BSD, etc. simply because they have had their
> intelligence insulted, or been irritated, or been completely confused,
> or been preached to one too many times by well-meaning proponents of
> Open Source solutions who are either unable to communicate or simply
> victim to their own enthusiasm.
> 
> There is probably nothing that doesn't have an Open Source solution in
> the abstract sense-- but in the real world of existing systems,
> personnel, and politics, the best solution may not be technically the
> fastest or even the most stable. The right tool for the job is my
> motto, and that might mean SQL Server, it might mean MySQL. It might
> mean a Linux server, it might mean Win2K. There is no single panacea.
> 
> c
> --
> Chris Lott
> http://www.chrislott.org/ 
> 
> -- 
> 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]


/*
J. Lewis
lamp/php developer
livingpages.com
*/

--- End Message ---
--- Begin Message ---
Hi,

Seems mysql_escape_string will just escape, seems like 
addslashes and quotemeta.

quote in DBI will escape and quote if passed value is not an 
integer (don't know about float).

Peter

---------------------------
"Reality is that which, when you stop believing in it, doesn't go
away".
                -- Philip K. Dick
--- End Message ---
--- Begin Message ---
Hello,

I was hopping that one of you would know how to setup a self-extracting php program.  
This is the story:
I'd like to offer a zipped file for download.  Someone unzips it on their PC and there 
find two files, "extractor.php" and some other file that php can unzip.  They upload 
these two files to their server, direct their browser to extractor.php, enter some 
information, and extractor.php unzips the other file into multiple directories/files, 
each adjusted to the specifications set in extractor.php.

I know there is a way for php to unzip files such as .elg, but how to do it, and if 
the server needs to be set up in some special format... I don't know.  I've looked 
around on-line, but so far haven't found anything.


Thanks for any input,

Sean


--- End Message ---
--- Begin Message ---
Computer science is considered an engineering discipline in most
institutions. And I think that's good... we need people out there to develop
OS's, create database servers, etc. PHP can be effectively used in this
curriculum, but C seems a lot more to the point. 

The place where PHP could (and should) make inroads is in the web
development curriculum that is generally split off from the formal computer
science programs. I think that split is a good thing even if it is made for
the wrong reasons... and while one can quibble about "real programmers" and
such, these programs that encompass web design, web mastering, systems admin
and networking are the real ground for advancing PHP.

Many institutions, like the one I teach for, are entrenched in ASP and Java
because that is understood by administrators as "a good thing to do" and
because it is often easier to find instructors with these skills (or at
least the certifications). But there are inroads being made. I have
typically taught web design, internet and networking. Now I finally am
getting a chance to teach a PHP/MySQL class as part of the web development
curriculum (finally as in we finally found good instructors to take the
other courses so that I would have time).

Also, these programs are typically staffed by a cadre of aduncts. If you
have PHP skills and teaching skills and you  can basically donate your time
for the peanuts that are offered (and the fun of it), there is a place for
YOU to help promote PHP.

Someone else remarked that certifications would advance PHP. There is
something to that, particularly in the corporate marketplace to USE it. More
often, in my experience, PHP is slow to be adopted in the corporate
environment because MS is so entrenched, and because MS' firm establishment
on the desktop means hiring MS people, who naturally promote and hire other
MS people, and administrators often equate using other technologies with
abandoning their desktops.

Certification has an equally negative aspect, though, unless stringently and
particularly administered and granted, which would defeat the marketing
ends.

c
--
Chris Lott
http://www.chrislott.org/
--- End Message ---
--- Begin Message ---
In order to make a living as a programmer, unless you can seriously wow your
potential employers with raw ability, it's difficult to make any real money
unless you have a little piece of paper that says "Look what I can do!"
I've been programming in PHP, Perl, ASP, Java, Visual Basic, C and C++ to
some extent for the last seven years, but aside from a 1-year certification
in VB that has since expired I simply haven't been able to afford a
certification course.  The also only offer your standard Computer and
Information Science degree here at the University of Delaware, nothing in
Web.

Here's something to do, though: most of the major universities I've looked
into do *not* offer a Web Development degree.  Lobby to have it added, but
in the meantime look to your local community college or technical college.
They more often than not WILL offer courses and ultimately an associate's or
bachelor's degree in Web Development.  More and more are offering courses in
open source solutions because the world appears to be getting over it's fear
of free products ("if they aren't charging for it, it can't be that good"
mentality).  Certifications/degrees are not only just the difference between
getting and not getting certain jobs, but for the ones you can get it's also
the difference between $25,000/yr and $75,000/yr unless you really *are*
God's gift to programming.

Take care,
Mike Frazer


"Chris Lott" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Computer science is considered an engineering discipline in most
> institutions. And I think that's good... we need people out there to
develop
> OS's, create database servers, etc. PHP can be effectively used in this
> curriculum, but C seems a lot more to the point.
>
> The place where PHP could (and should) make inroads is in the web
> development curriculum that is generally split off from the formal
computer
> science programs. I think that split is a good thing even if it is made
for
> the wrong reasons... and while one can quibble about "real programmers"
and
> such, these programs that encompass web design, web mastering, systems
admin
> and networking are the real ground for advancing PHP.
>
> Many institutions, like the one I teach for, are entrenched in ASP and
Java
> because that is understood by administrators as "a good thing to do" and
> because it is often easier to find instructors with these skills (or at
> least the certifications). But there are inroads being made. I have
> typically taught web design, internet and networking. Now I finally am
> getting a chance to teach a PHP/MySQL class as part of the web development
> curriculum (finally as in we finally found good instructors to take the
> other courses so that I would have time).
>
> Also, these programs are typically staffed by a cadre of aduncts. If you
> have PHP skills and teaching skills and you  can basically donate your
time
> for the peanuts that are offered (and the fun of it), there is a place for
> YOU to help promote PHP.
>
> Someone else remarked that certifications would advance PHP. There is
> something to that, particularly in the corporate marketplace to USE it.
More
> often, in my experience, PHP is slow to be adopted in the corporate
> environment because MS is so entrenched, and because MS' firm
establishment
> on the desktop means hiring MS people, who naturally promote and hire
other
> MS people, and administrators often equate using other technologies with
> abandoning their desktops.
>
> Certification has an equally negative aspect, though, unless stringently
and
> particularly administered and granted, which would defeat the marketing
> ends.
>
> c
> --
> Chris Lott
> http://www.chrislott.org/


--- End Message ---
--- Begin Message ---
In article <007901c1a588$120a6150$3c01a8c0@quasimodo>, 
[EMAIL PROTECTED] says...
> ----- Original Message -----
> From: "Alexander Weber" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, January 25, 2002 10:34 AM
> Subject: Re: [PHP] Correct URL's
> 
> 
> > Stefan Rusterholz wrote
<SNIP>
> > Please do not send HTML messages.
> Sorry, Outlook is crap and I'm just too lazy to buy (on Win you have to buy
> almost everything) another e-mail client for my working machine.

http://www.pegasus.org/

It's free and a bit more virus resistant than a certain M$ product (well, 
any M$ product)

-- 

-- 
David Robley
Temporary Kiwi!
--- End Message ---
--- Begin Message ---
> >
> > > Stefan Rusterholz wrote
> <SNIP>
> > > Please do not send HTML messages.
> > Sorry, Outlook is crap and I'm just too lazy to buy (on Win you
> have to buy
> > almost everything) another e-mail client for my working machine.
>
> http://www.pegasus.org/
>
> It's free and a bit more virus resistant than a certain M$ product (well,
> any M$ product)
>
> --

www.pmail.com ?  pegasus.org is *definately* virus free, (it's a yachting
team!!!)

--- End Message ---
--- Begin Message ---
> > > Please do not send HTML messages.
> > Sorry, Outlook is crap and I'm just too lazy to buy (on Win you have to

??? Outlook does not ~need~ to send HTML messages, it can be configured to
send text-only messages

Sheesh, It's about time you guys started looking properly at your
environments and learning how to use properly instead of just slanging MS

David Robley <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> In article <007901c1a588$120a6150$3c01a8c0@quasimodo>,
> [EMAIL PROTECTED] says...
> > ----- Original Message -----
> > From: "Alexander Weber" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Friday, January 25, 2002 10:34 AM
> > Subject: Re: [PHP] Correct URL's
> >
> >
> > > Stefan Rusterholz wrote
> <SNIP>
> > > Please do not send HTML messages.
> > Sorry, Outlook is crap and I'm just too lazy to buy (on Win you have to
buy
> > almost everything) another e-mail client for my working machine.
>
> http://www.pegasus.org/
>
> It's free and a bit more virus resistant than a certain M$ product (well,
> any M$ product)
>
> --
>
> --
> David Robley
> Temporary Kiwi!


--- End Message ---
--- Begin Message ---
In article <007b01c1a582$f9d67ec0$[EMAIL PROTECTED]>, 
[EMAIL PROTECTED] says...
> Hi there,
> 
> Is there any one who could give me an idea regarding the date and time
> triggering PHP script. This date and time script whould gives an output if
> ever it hit "Jan 1" and print's it's  year.
> 
> Any idea?
> 
> Thanks in advance, and also to all who keeps on helping a newbie like me.

This can be done under *nix using cron, or Windows using Task Scheduler. 
You'll need a cgi version of PHP to run scripts this way.


-- 
David Robley
Temporary Kiwi!
--- End Message ---
--- Begin Message ---
On Monday 21 January 2002 12:17, Alex Dowgailenko wrote:
> 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(mysql_error());
>       while (list($opid, $ppid, $amount, $pname) = mysql_fetch_row($res)) {
>               $eval = '$temp["'.$pname.'"] = $temp["'.$pname.'"] + '.$amount.';';
>               eval($eval);
>               $i++;
>       }
>       arsort($temp);
>       return $temp;
> }

If you're using php4.03+ you could try:

  while ($row = mysql_fetch_assoc($res) {
    $temp[$row['pname']] = $row['pname'] + $row['amount'];
    $i++;
  }



-- 
Jason Wong -> Gremlins Associates -> www.gremlins.com.hk

/*
Life is a sexually transmitted disease with 100% mortality.
*/
--- End Message ---
--- Begin Message ---
I'm fairly new to PHP, having worked with ColdFusion in the past.  Can
somebody shed some light on to the key differences between the CGI
installation and the ISAPI installation.  I working with IIS on Win2k and
using MySQL for a db server.  Thanks.

 - Ben

--- End Message ---
--- Begin Message ---
 use the ISAPI module since you are using with IIS

>'m fairly new to PHP, having worked with ColdFusion in the >past. Can somebody shed 
>some light on to the key >differences between the CGI installation and the ISAPI 
>>installation. I working with IIS on Win2k and using MySQL >for a db server. Thanks. 
--- End Message ---
--- Begin Message ---
$user = $HTTP_GET_VARS["user"];
$pass = $HTTP_GET_VARS["pass"];

$real =  "superduperunlieklytobeguesedpass";
if($user == $validuser && $pass == $real)
{
    echo "thank you for logging in here is the page";
?>
<HTML>
etc
<?php } else {
die("You supid idiot thats not a valid login");
?>
and call the page as
http://superdomain.com/login.php?user=Imasuperduperuser&pass=superduperunlie
klytobeguesedpass

You'd need to alter it obviously. Its good for secureing one page if you
want multi page you ... need to work on Sessions :S Im working on em now :S
scarry stuff :S

"Laserjetter" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Depending on how secure the login information needs to be, you could just
> store it in a text file, maybe using password() to encrypt passwords. You
> could then access it using fopen() and save the contents of the file in an
> array.
>
> I'm not too hot on login and authentication though myself! I did get it
> working, there was a useful example in the PHP manual.
>
> LJ
>
> "XX XX" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > 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
> >
> > _________________________________________________________________
> > Get your FREE download of MSN Explorer at
> http://explorer.msn.com/intl.asp.
> >
>
>


--- End Message ---

Reply via email to