[PHP-DB] Retricting Access to Menu Items

2006-03-06 Thread Jeff Broomall
Good morning everyone. I'm building a very simple content management site that tracks "tasks." The options available are: 1. Add Task 2. Edit Task 3. View Task 4. Print Task I need to restrict some users to only View and Print and I'm trying to find a way to tell the page not to load the me

Re: [PHP-DB] Retricting Access to Menu Items

2006-03-06 Thread Jeffrey
I've done this kind of thing with a number of web apps. What I usually do is create a user table in MySQL with a user-name, password and access level, which has an integer value. When a user logs in successfully, a session is created (see session_start() in php documentation), the access leve

[PHP-DB] X Tiger 10.4.5 + phpBB2 + MySQL 5 + Can't Connect Issue!

2006-03-06 Thread m i l e s
Hi, Im getting the following: Warning: mysql_connect(): Can't connect to local MySQL server through socket...etc. NOTES: 1.) MySQL 5 is running fine. 2.) Im able to connect to it via Navicat. 3.) I run Lasso on the same host, I know that I can pull and post data to and from MySQL. So its N

Re: [PHP-DB] X Tiger 10.4.5 + phpBB2 + MySQL 5 + Can't Connect Issue!

2006-03-06 Thread Micah Stevens
Is there really a .sock file where you're telling php there is? MySQL can put the socket file anywhere you want depending on it's configuration. /etc/my.cnf should specify this. -Micah On Monday 06 March 2006 9:08 am, m i l e s wrote: > Hi, > > Im getting the following: Warning: mysql_conne

[PHP-DB] X Tiger 10.4.5 + phpBB2 + MySQL 5 + Can't Connect Issue! - SOLVED!

2006-03-06 Thread m i l e s
Hi, Figured it out: Apple wiped out the location of the socket. they wanted '/var/mysql/mysql.sock' it should be: '/tmp/mysql.sock' Problem solved. M i l e s. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-DB] Problems with PDO mysql

2006-03-06 Thread Escuder Nicolas
Hello, I have made this little example for explain my problem : query("Update Test set data ='" . $data . "';"); ?> If i execute this scripts from php cli the result will be : /enabled=boolean:true;/description=string:"évènements" If i execute this scripts from apache server the re

[PHP-DB] PHP4 with MYSQL5

2006-03-06 Thread João Cândido de Souza Neto
Hello everyone. I'm trying to use my php4 conecting to a mysql5 server, and then executing some command lines to create a stored procedure but it's not working. When a tried to execute "delimiter |", my php gets de follow error: You have an error in your SQL syntax; check the manual that corresp

[PHP-DB] Problem with a login page.

2006-03-06 Thread Alex Major
Hi there everyone, just wondered if you could help me with this login scipt. I've tried to customise a script that I found on a website, but it dosn't seem to be working. Here is the scipt that isn't working. Login Logged in Welcome back , you are logged in. Login Username: Password:

Re: [PHP-DB] Problem with a login page.

2006-03-06 Thread dpgirago
... // check passwords match $_POST['password'] = stripslashes($_POST['password']); $info['password'] = stripslashes($info['password']); $_POST['password'] = $_POST['password']; if ($_POST['password'] != $info['password']) { die('Incorrect password, please try again.

[PHP-DB] Re: PHP4 with MYSQL5

2006-03-06 Thread João Cândido de Souza Neto
I receive aa answer by e-mail in order this telling me that i must upgrade my php4 to php5. It means that a php4 server don't works fine with mysql5 server? João Cândido de Souza Neto wrote: > Hello everyone. > > I'm trying to use my php4 conecting to a mysql5 server, and then executing > some

[PHP-DB] RE: [PHP] Re: PHP4 with MYSQL5

2006-03-06 Thread jblanchard
[snip] I receive aa answer by e-mail in order this telling me that i must upgrade my php4 to php5. It means that a php4 server don't works fine with mysql5 server? [/snip] http://www.php.net/mysqli is designed to work with versions of MySQL 4.1.n and above. It requires PHP5 -- PHP Database Mail

RE: [PHP-DB] Re: PHP4 with MYSQL5

2006-03-06 Thread Bastien Koert
it does, you need the updated mysql library that comes with the php 5 files (libmysql.dll for windows) bastien From: João Cândido de Souza Neto <[EMAIL PROTECTED]> To: php-db@lists.php.net,php-general@lists.php.net Subject: [PHP-DB] Re: PHP4 with MYSQL5 Date: Mon, 06 Mar 2006 18:38:56 -0300

RE: [PHP-DB] Retricting Access to Menu Items

2006-03-06 Thread Bastien Koert
if you pull the user data into a session, then its a simple if them check if ($_SESSION['user']['user_access']>1) //1 = basic user { echo 'Edit Task'; echo 'Add Task'; } bastien From: "Jeff Broomall" <[EMAIL PROTECTED]> To: Subject: [PHP-DB] Retricting Access to Menu Items Date: Mon, 6

[PHP-DB] Very Tricky PHP Array.

2006-03-06 Thread Michael Acs
Hi there, I have one arrray: $field_vals There are three values in the array, however two are multi-dimension array. i.e: $field_vals[base] -> Array ( [0] -> 1 [1] -> 2 ) $field_vals[make] -> Array ( [0] -> 5 [1] -> 7 [2] -> 8 ) $field_vals[qty] -> 1 I have a MySQL with a table (part) for the d

Re: [PHP-DB] Retricting Access to Menu Items

2006-03-06 Thread MIGUEL ANTONIO GUIRAO AGUILAR
Now that you mention it!! I tried to use sessions but without success, i did: session_start(); session_register(var); but after log in as a different user, it keeps taking the data of the previous user. If I close the browser window and reload the page and log in, then it takes de current us

[PHP-DB] Help needed creating a social network

2006-03-06 Thread Daevid Vincent
Anyone have some pointers at a HowTo on creating a social network? Basically I need to show people in your immediate network, and also friends of your friends, etc... Like the whole 'six degrees of separation' thing. Ala: myspace, friendster, etc. ad nauseum. I prefer mySQL and PHP, but I could p

Re: [PHP-DB] Help needed creating a social network

2006-03-06 Thread Micah Stevens
CREATE TABLE `users` (userID int(11) not null auto_increment, primary key(userID), name tinytext not null, email tinytext not null); CREATE TABLE `links` (userID int(11), key (userID), friendID int(11), key(friendID)); You have friends!!"; while ($f = mysql_fetch_assoc($friends)) { echo "{$f['