Welcome Guest, Not a member yet? Register   Sign In
CodeExtinguisher v2.0 Release Candidate 13
#11

[eluser]Donald Hughes[/eluser]
Here's the error I'm getting:

-------------------------------------
A PHP Error was encountered
Severity: Warning
Message: array_slice() expects parameter 2 to be long, string given
Filename: controllers/codexcontroller.php
Line Number: 104
-------------------------------------

Any idea of how I can resolve this? The only thing that I'm doing differently is path related. I don't have the codex folder inside of my public folder. But I updated all the path-related variables, so everything functions properly. I just get a big error at the top of the page.



----------
Also, the css also doesn't seem to work very nicely in Internet Explorer (though it is fine in Firefox). Not sure if you care about that.
#12

[eluser]gusa[/eluser]
well, i'm here 'extending' codexsession class.
the class extends from Native_Session and adapts some methods receive codex calls properly.
but i had a problem. to extend codexsession i needed to require_once-it using require_once(APPPATH.'libraries/Native_Session.php') and i'm getting the following error:

Message: require_once(codex/application/libraries/Native_Session.php) [function.require-once]: failed to open stream: No such file or directory

i echoed APPPATH and i'm getting 'codex/application/', but i need the full path to that directory.

i think the problem is in line 109 of backend.php. it asks if $application_folder is a directory and it is. so the following lines defines APPPATH as a relative directory.

this behavior doesn't happens with the codeigniter's index.php, where is_dir($application_folder) returns false and the else is executed.

the fast answer could be 'ok, just define APPPATH as BASEPATH.$application_folder.'/'. this is wrong, because BASEPATH == $system_folder.'/' and $system_folder == 'system' so APPPATH yields '[full-path-to-my-webapp]/system/codex/application'.

by now i'm going to fix it mannualy.
#13

[eluser]Donald Hughes[/eluser]
Here's the error I'm getting now. I'm not using anything that's not in the Example, which works fine.

------------------------------------------------------
A PHP Error was encountered
Severity: Notice
Message: Undefined index: class
Filename: libraries/codexforms.php
Line Number: 53
------------------------------------------------------


I feel like I'm getting conflicting information from three different sources:

The Screencast (http://codeextinguisher.com/screencasts/...index.html)
The Documentation (http://www.codeextinguisher.com/index.php/documentation)
The Wiki (http://codeextinguisher.pbwiki.com/)

I'mn not sure what instructions/formats I should be following.

------------------------------------------------------
Table:
------------------------------------------------------
CREATE TABLE `daily_devotion` (
`id` int(11) NOT NULL default '0',
`start_publish_date` datetime NOT NULL default '1970-01-01 00:00:00',
`end_publish_date` datetime NOT NULL default '1970-01-01 00:00:00',
`scripture` text NOT NULL,
`verse` varchar(40) NOT NULL default ' ',
PRIMARY KEY (`id`)
)


------------------------------------------------------
Definition (daily_devotion.yml):
------------------------------------------------------
form_setup:
scripture:
class: TextArea
verse:
class: TextBox
start_publish_date:
class: Date
end_publish_date:
class: Date



------------------------------------------------------
Controller (dailydevotion.php):
------------------------------------------------------
<?php if (!defined('BASEPATH')) exit('No direct script access allowed');
include_once("codexcontroller.php");

class DailyDevotion extends codexController
{
function DailyDevotion ()
{
codexController::codexController();

$rules['scripture'] = "trim|required";

$config = array(
'db_table' => 'daily_devotion', //The name of the table associated with this controller
'form_setup' => $this->spyc->YAMLLOAD($this->codexadmin->getDefinitionFileName('daily_devotion')), //The array that holds our elements
'controller_name' => 'DailyDevotion', //The name of the controller, so that it can be used when generating the URLs
'primary_key' => 'id', //The name of the controller, so that it can be used when generating the URLs
'display_fields'=>array('scripture','verse','start_publish_date','end_publish_date'),
'rules'=>$rules
);
$this->setConfig($config);
}
}
?>
#14

[eluser]abmcr[/eluser]
The documentation is not updated.... See the code.... :-)
#15

[eluser]gusa[/eluser]
i'm getting the following error:

Fatal error: Call to undefined method CodexMessages::getAsArray() in C:\Inetpub\wwwroot\sim\codex\application\controllers\login.php on line 45

i search getAsArray in codexmessages and i don't find it.

ideas?
#16

[eluser]gusa[/eluser]
arghhh...

Severity: Warning

Message: mysql_real_escape_string() [function.mysql-real-escape-string]: Access denied for user
Filename: libraries/codexlogin.php
Line Number: 104

mysql?? this puts me out of the game Sad
#17

[eluser]Donald Hughes[/eluser]
I think I found a bug in the date.php plugin. I was getting invalid integer errors, so I looked at the usage of mktime in the prepForDisplay function. The month and day values should be wrapped with intval() to prevent days and months with a leading 0 (as in 05) from being treated as octal values. I added the intval() to my local copy of 'date.php' and the errors went away.
#18

[eluser]Donald Hughes[/eluser]
I'm still getting the following error when I first login (and only when I first login):

--------------------------------------------------------------
A PHP Error was encountered
Severity: Warning
Message: array_slice() expects parameter 2 to be long, string given
Filename: controllers/codexcontroller.php
Line Number: 104
--------------------------------------------------------------
#19

[eluser]Donald Hughes[/eluser]
A little more detail on the above error:

I guess the interface defaults to "Example" (any way to change that?). And if there are no records for that table then $this->first_item is null.
#20

[eluser]Majd Taby[/eluser]
I'm sorry you guys are having problems, but I want to thank you for helping me find them, it's hard to properly test all parts of a system like this especially when I don't have a suit of test to run (which is my fault)

I'll address your issues in a release soon.




Theme © iAndrew 2016 - Forum software by © MyBB