Jump to content

umbrella_thing

Members
  • Posts

    17
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

umbrella_thing's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hi all, I was interested in looking at some php5 classes and objects that are object orientated to get an idea of what other people are doing. But more "real world" examples, more than "class FruitBowl" if you know what I mean by this. Does anyone have any links handy for something like this? Thanks Dane
  2. Yeah there is an error with your SQL script (darr) Maybe delete each clause to try and figure out which part of the script is giving you the error or something? I think phpmyadmin re-formats the SQL you give it sometimes to make it work... Just a thought...
  3. Thanks guys for your help! "extending" to other classes works really well. Very "OO". Thanks again :)
  4. Hi Dudes and Dudets, I have a questiong relating to PHP5 classes, I want to be able to use the methods and members of a class, inside another class! For instance, a class that access the database. I would want to use this inside a perhaps an article class... I know you can "include" a class and do Name::method(), but I'm not sure this is the best way... is this possbile... [code] private dbConnection = new DataAccess public function getArticlesById($id) { $result = dbConnection->query("select * from article where id = $id"); } [/code] I don't know if this makes sense to anyone?
  5. Yeah I suppose your right, but I will check out your scaffolding jsladek. I had a look at phpCake once... woah that was huge...! Thanks guys!
  6. I suppose I could, but before I explore that avenue I was hoping to see if someone else had already made a nice one.. perhaps someone who could make a nicer one.. :')
  7. Since I've been using php to write alot of web stuff, i'm finding it boring to write all the "admin" stuff for the sites over and over again. Does anyone know of any decent php create read update delete software or classes that I could use for clients instead of writing the same code over again?
  8. I've just installed a php website onto a commercial server, whos PHP (4) has turned off showing errors. While I'm in the testing process I wouldn't mind having them showing, because I think there is some version issues. I think there is some code you can throw in your script to override the php.ini right? Thanks dudes!
  9. yeah it does, at the same time I just found it on php.net ahh thanks for that matey :)
  10. Simply. How do I get the session id ? I want to use it as a primary key in a table.. but .. I dont how to "get" it.. Its gotta be something totally simple right? Thanks dudes!
  11. Ahh thanks man, I realised the question doesn't really make sense, but I know what your saying :) Thanks!
  12. Hi Guys I have a website that has a div layer 600px wide, margin set to auto so it aligns in the center horozontally. What I want to anther div layer inside this "main" layer called "bottom" to sit, well, on the bottom. So no matter how much stuff is on top its always at the bottom of the "main" div layer. Is this possible? Thanks guys! Umbrella ???
  13. You need to put the result resource into another function to get field in a given row... [code] if($session->isAdmin()){       $q2 = "SELECT ip FROM users WHERE username = '$session->username'";       $result2 = mysql_query($q2);      $ip_address = mysql_result($result2, 0, "ip");       echo "<br><b>  <u>Admin</u></b><br>  <a href=\"admin/admin.php\">Admin Center</a>   ";       echo "<br>(test) Your IP: $result2";    } [/code] [code]$ip_address = mysql_result($result2, 0, "ip");[/code] mysql_result(RESULT RESOURCE, ROW, FIELD); that should do the trick
  14. Yes that worked well, I was using $date with PHP's date function. NOW() is much better, but apparently not the problem, and the SQL wasn't the problem!! Thanks heaps anyway! :-)
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.