Login and Pass don't work

A place for users and developers of the Xataface to discuss and receive support.

Login and Pass don't work

Postby mauro » Sun Oct 30, 2011 9:59 am

I have installed in my web server Xataface.
The info is OK.
But, when I go in ...installer.php page, it asks to me LOGIN and PASS.
I put in the infos, but nothing.
It continues asking to me the same infos. Forever.
So I cannot use Xataface.
Someone can help me?
Thanx from Italy.

[Ave]
mauro
 
Posts: 1
Joined: Sun Oct 30, 2011 9:52 am

Re: Login and Pass don't work

Postby schoolisoutfan » Mon Oct 31, 2011 10:44 am

I got th same problem, my user and password don't works.

I have copy the files on my webspace, then I create a Database called 7_LoU with the user 7_samsung.
I Make the dataface/Dataface/templates_c directory writable by the web server.

This is my conf.inf from the site_skeleton direktory


; File: conf.ini
; Description:
; ------------
; This file contains configuration information for the dataface framework.
; Configuration options include such things as database connection information
; tables to be displayed in the menu, and behavioral and display characteristics
; of the dataface application (like whether to display the menu).
;
[_database]
host = "localhost"
user = "7_samsung"
password = "password"
name = "7_LoU"

[_tables]
Course = "Course"
Program = "Program"

I created the tables manually like the tutorial:

CREATE TABLE `Course` (
`CourseID` int(11) NOT NULL auto_increment,
`ProgramID` int(11),
`CourseTitle` varchar(64) NOT NULL default '',
`CourseDescription` text NOT NULL,
`HTMLOutline` text NOT NULL,
`PDFOutline` longblob NOT NULL,
`PDFOutline_mimetype` varchar(64),
`Subject` varchar(128) NOT NULL default '',
`CourseNumber` varchar(10) NOT NULL default '',
`Credits` int(5) NOT NULL default '0',
`LastModified` timestamp NOT NULL default CURRENT_TIMESTAMP,
PRIMARY KEY (`CourseID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='Store courses' AUTO_INCREMENT=1 ;
In a similar fashion, create the Program table. The resulting SQL for this table is:

CREATE TABLE `Program` (
`ProgramID` int(11) NOT NULL auto_increment,
`ProgramName` varchar(64) NOT NULL default '',
`ProgramDescription` text NOT NULL,
`HTMLOutline` text NOT NULL,
`PDFOutline` longblob NOT NULL,
`PDFOutline_mimetype` varchar(32),
`AdmissionDeadline` date NOT NULL default '0000-00-00',
`LastModified` timestamp NOT NULL default CURRENT_TIMESTAMP,
PRIMARY KEY (`ProgramID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='Academic Program' AUTO_INCREMENT=1 ;



This are the first rows of my install.php in the main directory:

<?php
require_once('PEAR.php');
if ( !defined('FILE_APPEND') ){
define('FILE_APPEND', 1);
}
if ( !function_exists('file_put_contents') ) {

function file_put_contents($n, $d, $flag = false) {
$mode = ($flag == FILE_APPEND || strtoupper($flag) == 'FILE_APPEND') ? 'a' : 'w';
$f = @fopen($n, $mode);
if ($f === false) {
return 0;
} else {
if (is_array($d)) $d = implode($d);
$bytes_written = fwrite($f, $d);
fclose($f);
return $bytes_written;
}
}
}

define('DB_HOST', '$installer.php'); // This is the host of your mysql dbms
ini_set('include_path','.'.PATH_SEPARATOR.'lib');
set_time_limit(1500);
class Dataface_Installer



Is there anything wrong? Please help me
schoolisoutfan
 
Posts: 4
Joined: Mon Oct 31, 2011 8:04 am

Re: Login and Pass don't work

Postby shannah » Mon Oct 31, 2011 10:47 am

The most likely cause of this is that your mysql server is not localhost. You'll need to modify the installer.php file. Modify the line:
Code: Select all
define('DB_HOST', 'localhost');  // This is the host of your mysql dbms


Changing localhost to your mysql server host.

Alternatively, just do a manual install.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Login and Pass don't work

Postby schoolisoutfan » Mon Oct 31, 2011 11:38 am

The same problem:

<?php
require_once('PEAR.php');
if ( !defined('FILE_APPEND') ){
define('FILE_APPEND', 1);
}
if ( !function_exists('file_put_contents') ) {

function file_put_contents($n, $d, $flag = false) {
$mode = ($flag == FILE_APPEND || strtoupper($flag) == 'FILE_APPEND') ? 'a' : 'w';
$f = @fopen($n, $mode);
if ($f === false) {
return 0;
} else {
if (is_array($d)) $d = implode($d);
$bytes_written = fwrite($f, $d);
fclose($f);
return $bytes_written;
}
}
}

define('DB_HOST', '19 3.34.68.126'); // This is the host of your mysql dbms
ini_set('include_path','.'.PATH_SEPARATOR.'lib');
set_time_limit(1500);
class Dataface_Installer {

I sent you a pm cause of your spam defender
schoolisoutfan
 
Posts: 4
Joined: Mon Oct 31, 2011 8:04 am

Re: Login and Pass don't work

Postby shannah » Mon Oct 31, 2011 11:46 am

define('DB_HOST', '19 3.34.68.126');
This doesn't look like a valid address. (unless you intentionally put the extra space it to get around the spamblocker).

In any case the problem is likely related to mysql permissions. MySQL's permissions model is such that if you provide access to the user foo@localhost this is not the same as the foo@127.0.0.1 (i.e. the user couldn't connect to 127.0.0.1 even if that was the ip address for localhost.

Your problem is almost certainly a mysql user permissions problem.

I wouldn't spend too much time on this. Manual installs are so easy to do and if you want to start doing any customizations at all, being comfortable with the file structure will be helpful. The auto installer looks nice but really its just copying a few lines of code for you to get started.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Login and Pass don't work

Postby schoolisoutfan » Mon Oct 31, 2011 12:20 pm

You are right, I learn it ;)
ht tp://kneipengänger.de/LoU/index1. php - to make the manual install
Code: Select all
<?php
require_once 'dataface-public-api.php';
df_init(__FILE__, 'ht tp:// xn--kneipengnger-ncb. de/LoU')->display();


I've try it but I have a path error:
As of Xataface 1.3 all applications are now required to have its own templates_c directory to house its compiled templates. Please create the directory "/var/www/virtual/xn--kneipengnger-ncb. de/htdocs/LoU/templates_c" and ensure that it is writable by the web server.

I don't know why the scrip search for this path: xn--kneipengnger-ncb. de/htdocs/LoU/templates_c
The correct path is of course xn--kneipengnger-ncb. de/htdocs/LoU/ Dataface/templates_c

Is there a error in the dataface-public-api.php?
schoolisoutfan
 
Posts: 4
Joined: Mon Oct 31, 2011 8:04 am

Re: Login and Pass don't work

Postby shannah » Mon Oct 31, 2011 1:28 pm

You need to have a templates_c directory in your application directory.
e.g.
index.php
conf.ini
templates_c

And make sure it's writable by the webserver.

The templates_c directory in the dataface directory is separate.

-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Login and Pass don't work

Postby schoolisoutfan » Mon Oct 31, 2011 1:31 pm

Ah Ok, I try it But why is there no information about that? I think this is a realy important change.

Yeah it works thanks a lot, and sorry for my english ;)
schoolisoutfan
 
Posts: 4
Joined: Mon Oct 31, 2011 8:04 am


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 25 guests

cron
Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved