Not signed in (Sign In)
Welcome Guest!
Want to take part in these discussions? If you have an account, sign in now.
If you don't have an account, apply for one now.
    • CommentAuthorGKSR
    • CommentTimeJul 15th 2008
     
    Hi Bermi,

    I am new to frameworks. I have seen your blog screencasts. It was gr8. Thanks for creating such a wonderful framework. I thought of using akelos in my new project. I started trying to install the framework. But i am unable to. Right now, i am using xampp on windows server 2003. I have seen the manual instructions(booklink tutorial). But it wasn't really helpful. Please change the manual, so that it provides different instructions for different OS like windows, linux.. etc. I have installed xampp in c:/xampp. when i tried to run the cmd (C:/xampp/php/php.exe ./script/generate scaffold) in the ms-dos, its giving an error like : could not open input file: ./script/generate. So, can i know what the problem really is?

    waiting for your reply..
    •  
      CommentAuthorbermi
    • CommentTimeJul 15th 2008
     
    • CommentAuthorGKSR
    • CommentTimeJul 15th 2008
     
    Bermi,

    thanx for your reply.

    Now I am in the process of creating the blog. I have completed till script generate blog controller using the cmd: ./script/generate controller Blog.The files were created automatically. But i didn't get any fatal error which u got in the screencast(when u refreshed the browser). later i have edited the blog_controller.php to output the 'Hello world'. when i refreshed the page (http://localhost/blog/), i didn't output(Hello world) in the browser. It still continuous to show the 'Welcome aboard' message. Can u plz help me where i went wrong?
    • CommentAuthorGKSR
    • CommentTimeJul 15th 2008 edited
     
    Hi Bermi,
    The o/p 'hello world' is not displayed when i refresh the page 'http://localhost/blog/'. But when i add one more blog to the url like: 'http://localhost/blog/blog' , then the output 'Hello world' is being displayed. The file structure is as follows:

    C:/xampp/htdocs/blog/app/views/blog/index.tpl
    The actual place of akelos is: C:/dev/akelos/app
    xampp installation: C:/xampp/htdocs

    I am able to move further only if i add a blog at the end of the url: http://localhost/blog/blog/listing/.
    Its working well if i add double blog in the url.

    Can i know y this is due to?
    • CommentAuthorKaste
    • CommentTimeJul 15th 2008
     

    C:/xampp/htdocs/blog/app/views/blog/index.tpl

    Personally, I don't like this kind of setup.

    What I do:

    1. checkout framework to a say C:/dev/akelos
    2. let akelos generate your app-scaffold (script/setup) to c:/dev/booklink_ f.i.
    3. then edit the apache-conf (C:/xampp/apache/conf/extra/httpd-vhosts.conf)

    either for the tutorial, setup an alias

    Alias /booklink "C:/Dev/booklink/public"
    <Directory "C:/Dev/booklink/public">
        Options Indexes FollowSymLinks
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>
    

    or a vhost.

    then you get your app either at http://localhost/booklink or at http://my_vhost/

    • CommentAuthorGKSR
    • CommentTimeJul 15th 2008
     
    Hi,

    when i tried to compile the cmd: ./script/migrate comment install ,
    I am getting errors:
    Notice: Undefined property: Post::$comment in c:/xampp/htdocs/blog/app/installers/comment_installer.php on line 15
    Fatel error: call to a member function create() on a non-object in c:/xampp/htdocs/blog/app/installers/comment_installer.php on line 15

    This is the code:

    <?php
    class CommentInstaller extends AkInstaller
    {
    function up_1()
    {
    $this->createTable('comments', "
    id,
    body,
    post_id
    ");

    Ak::import('post,comment');

    $Post = new Post(1);
    $Post->comment->create(array('body'=>"I liked Gaudi's buildings")); //This is line 15
    $Post->save();
    }

    function down_1()
    {
    $this->dropTable('comments');
    }
    }

    ?>

    can i know where i went wrong?
    •  
      CommentAuthorbermi
    • CommentTimeJul 16th 2008
     

    Seems you have not declared the associations in the models.

    • CommentAuthorGKSR
    • CommentTimeJul 17th 2008 edited
     
    Yes I have declared the associations in the models. Look at them..

    comment.php

    <?php

    class Comment extends ActiveRecord
    {
    var $belongs_to = 'post';
    }

    ?>


    post.php

    <?php

    class Post extends ActiveRecord
    {
    var $has_many = 'comments';

    function validate()
    {
    $this->validatesPresenceOf('title');
    $this->validatesPresenceOf('body');
    }
    }

    ?>

    Even when i add a new comment, its not showing the added comment. Its just showing the flash msg ( your comment has been added). But the comment was saved in the database.
    ?????
    • CommentAuthorserave
    • CommentTimeAug 8th 2008
     
    I am working on windows vista, i've following your instruction, but i haven't been able to install akelos.
    Create a new application: when i run c:\xampp\php\php.exe script/setup -d c:\xampp\htdocs\booklink it appears Could no open input file: script/setup
    please help me.
    • CommentAuthorKaste
    • CommentTimeAug 8th 2008
     

    You're actually in the framework root dir, are you ?

    • CommentAuthorserave
    • CommentTimeAug 8th 2008
     
    thanks, a lot. That was my mistake.
    Starting to love this framework.
    thanks for your fast answer
Add your comments
    Username Password
  • Format comments as