PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgrammingPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #31  
Old June 9th, 2003, 09:45 PM
Kiwi Kiwi is offline
Guru-in-training
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2002
Location: Not where I want to be...yet!
Posts: 38 Kiwi User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 16
Re: Learning PHP

Quote:
Originally posted by picker999
The only way I began to understand php was studying C\C++. Of course basic html is necessary but also forms and knowing what variables do helps a lot. I am somewhat behind though in my keeping current on what is happening. For instance I am not sure what the differences are for Register Globals being off and on. I just took over a site's management and although it seems to be working okay the latest php environment recommends Register Globals be off. The site does not work when I have register globals off. What do I have to do to site programming to have it work with register globals off. Is there a definitave article on this concept somewhere?


You could try the http://www.php.net for a definitive guide, to understand the changes required for your site's code, and change all instances of code where your variables are passed from forms, cookies, sessions, etc, or you could write a simple script to loop through the superglobals and assign them to variable names using variable variables.

I use the second approach where I'm too lazy to actually go and recode hundreds of pages. Instead, what I do is include code snippets in a file I include in most (or all) other pages. Something like :



Code:
<?php
if (!empty($_POST)) {
    foreach ($_POST as $varVarname=>$varVarValue) {
        $$varVarName = $varValue;
    }  
};
?>


This allows me to use the name of the variable passed by the form in the same way as I would if register_globals is on.

HTH.

Reply With Quote
  #32  
Old July 11th, 2003, 06:14 AM
lucasefe lucasefe is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 3 lucasefe User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
I learn a lot with Professional PHP4 from Wrox. It's full of OOP theory and with lots of explanations and case studies. Very helpfull. I recommend it.

Cheers

Reply With Quote
  #33  
Old July 17th, 2003, 06:34 AM
worchyld worchyld is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 13 worchyld User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
I bought the

I bought the following book:
PHP and MySQL Web Development, Second Edition
by Luke Welling, Laura Thomson (I got 1st edition)

http://www.amazon.com/exec/obidos/t...=glance&s=books

and it really awoke my imagination - I did have a Wrox boox (Begining PHP) but it was pretty woeful

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingPHP Development > Terrible PHP Books out there!


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap