-
Posts
4,362 -
Joined
-
Last visited
-
Days Won
11
Everything posted by Zane
-
well for one, you don't put semicolons next to IF statements' conditions
-
Here is an excerpt from the PHP Manual on the date function
-
you wouldn't be wasting your time with it, although when you wanted to add more permissions it could become a hassle... it would just be a continuous script of IFs or just a really long switch statement of all the possible permissions. it's just the same as the MySQL permissions almost...you can't give someone the GRANT permission without them also having the SELECT, INSERT, DELETE yada yada.....so you're switch would have to check for the "GRANT" permission....if it's checked then you've eliminated a lot of checking, but what if they don't have the GRANT permission.......some permission have more precedence than others, like DELETE and UPDATE. you can't give someone those without giving them SELECT and INSERT as well. If you have only 6 permissions then you only need 3 bits. No it's not a 50% rule either. 64,32,16,8,4,2,1 0 ,0 ,0 ,0 ,0 ,0 ,0 6 is less than 8, so you'll only need the first three to make 6 permissions....because 111 is 7 permissions (you'll never use it if you only have 6) but you will use 101....that's you're highest permission in a 6 permission world. First you may need to order your checkboxes/permissions in order of precedence so that if you happen to have a permission in your table 101 then you can assume they have all the other permissions as well. you can also set up CONSTANTS to make things easier...... EDIT: if you're not a deadline, it's a fun project to play with. But if you're in a hurry I'd say to go with what works easiest
-
It all depends on your development.....what way is best for YOU. Me in particular though, if I have like umpteen billion checkbxes......I seem to have something against making upmteen billion columns in my database for each one.. So what I do is.. First of all, if the checkboxes are somewhat related...like you said, are permissions. Then just create a column called permissions and I'd set the type to INT. When you're reading back your checkboxes you need to have them set for a 1 or 0. Now say you had 16 checkboxes...you would then have a 16-bit number to put into your permissions column 1111111111111111 -> meaning all of them where checked Then when you're reading this info out of the database, you can use bitwise operators to read information about these permissions.
-
well first of all....what are you doing? obviously either PHP or Java have received a different variable at some point or different input of some kind. to get different values like that Excluding that fact that you want it to have the same values as Java or vice versa, what are you wanting it to do....where's the code that's an odd looking smiley
-
Well, I didn't see any ROR anywhere....what I did see was really odd though. I found out through a little searching that I had confused ROR with jQuery. I'm not exactly sure what this is but I'm sure there's a lot that can be done with it. I tried out a few ROR tutorials and installed it.... I doubt it's for me, but this jQuery looks really cool. http://jquery.com/
-
you'll have to truncate your table
-
I believe CV summed up every bit of an opinion I can muster up on this. Any kind of development, whether it be AJAX, PHP, VB, etc.....if the developer sucks....then the program sucks there's no reason to judge a ..... language by it's....speaker. For lack of a better expression. It's all about making something work for You, get your imagination out there and if you're imagination doesn't SUCK it may draw a crowd and hopefully some money. Of course you're not going to be enthused by AJAX after reading an article about how much it sucks. That's why they wrote it. I myself like AJAX, I still haven't found a way to use it to it's full potential though.
-
I've heard so much about it but I've kinda just blown it off as a new fad. I've been monkeying around with AJAX a lot lately and I'm trying my damndest to get a simple autosuggest like thing going on for my database...and more and then I stumble upon a place called scriptaculous http://script.aculo.us/ I see some really awesome stuff on here. Then I take a look at the source code and see what I think is javascript and CSS mixed together somehow. Anyway, it's not. It's ruby on rails. Now for statement and question. I want to learn this! It's unlike anything I've seen before. I always wondered how Facebook controlled so many AJAX requests at one time and now I know....it just has to be this. So for all you ruby on rails gurus, if I wanted to begin learning this right away. What would you recommend is the best route. PHP is pretty much my primary so if there is any way possible to compare this language to PHP, lead me in that direction. I've got ideas that I can't do Thanks.....whoever
-
from abc.com you'll need to run this command on your MySQL service GRANT ALL PRIVILEGES ON *.* TO username@xyz.com IDENTIFIED BY PASSWORD("theActualPassword");
-
[SOLVED] PhpMyadmin not working
Zane replied to coder500's topic in PHP Installation and Configuration
go back a directory......there should be a folder called apps it's pretty straight forward after that and the conf file for phpmyadmin is callled config.inc.php I think -
hopefully by then they at least have the decency to keep the open source part of it all......lol
-
I wonder if there going to make it Google App compliant. in other words..I wonder if they'll make it work with things liike Gmail and Google Documents and such, that would be sweet. If they keep going they could very well make an OS....an internet OS
-
[SOLVED] PhpMyadmin not working
Zane replied to coder500's topic in PHP Installation and Configuration
can you connect to mysql through the command prompt? -
[SOLVED] PhpMyadmin not working
Zane replied to coder500's topic in PHP Installation and Configuration
shot in the dark..... are you sure your server is on port 8080 don't have much to go on really.. -
well, I gotta say..I like it I haven't turned it off since I installed it and it has yet to crash on me. Everything seems to run smoothly on my end. The pages have actually loaded faster! I never thought the browser had THAT much to do with the speed but I guess I was wrong. I can sense the subtle differences in how Firefox loads things and how Chrome loads them.
-
if you want the number results on top just put the li's in a variable instead echo ""; $i = 0; foreach(glob("*.php") as $val){ $file = basename($val, '.php'); $list .= "$file\n"; $i++; //At the end of each loop, this counter is incremented. } //then echo it afterwards as well echo "By god, there are $i results!...and here they are\n"; echo $list; echo ""; There's no need for javascript.
-
here's you some crontab literature http://www.adminschoice.com/docs/crontab.htm
-
with the PHP count function http://php.net/count
-
this is the coolest thing I've read all day. I always wondered when Google would make a browser...now I have my answer.... Tomorrow...lol
-
your best bet is to populate an array of all the stuff you want and return that because a multiple return is unheard of
-
Probably isn't meant to be understood on our end of understanding things....in the MySpace world. but if I had to make a guess on it. I'm sure that the MySpace administrators have their own custom built administration panel/portal that reads and decrypts these "tokens" as was already mentioned. Most likely it makes it much easier for them to pinpoint who is doing what and why. And if it's good or bad. They probably have a good banning system in place and yada yada. Most likely the session id is part of the token as well. MySpace is probably the most sensitive of all big sites I've seen, with the COPPA and what not.
-
name it CaptainPlanet
-
you know PHP has a built in function that does all that already http://php.net/parse_url you might have to explode the args key when it runs and then use foreach like the above code does....but it would be WAY less lines