Updates from March, 2009 Toggle Comment Threads | Keyboard Shortcuts

  • webscriptz 20:35 on 28/03/2009 Permalink | Reply
    Tags: dbal, howto, my, , tutorisql   

    Agile Application with php & mySQL 

    I’m working on a website system an facing this problem where and how to store my configurations in the database.  So you want to store your configuration vars in a configuration table in the database, that’s great and fun to do too.

    Why do it?

    Your application becomes easier to update to a newer version, most of the time, when creating a newer version you will strip – change – add some variables for configurations, with a database it’s easier and you (or the admin) can change things on the fly.

    How?

    One or more tables like this:


    Mysql table:
    +------------------+
    | config |
    +------------------+
    | id |
    | name |
    | value |
    +------------------+

    If you want you can add an selection column to get only the ones needed for that function but this is the best way when being in a development environment I think

     
    • webscriptz 20:39 on 28/03/2009 Permalink | Reply

      note that you can do this also with languages and it’s configurations. so:

      languages with id – lang – status
      status so you can have an active one to select with the WHERE attribute.

      languagevalues: id – name – value – lang_id

      lang_id is a foreign key in fact

  • webscriptz 10:46 on 21/03/2009 Permalink | Reply
    Tags: kernel, , map, transparent   

    Linux kernal map 

    Linux is a facinating OS but not always transparant to everybody, certainly the kernel has that problem. This linux map will help you figure out the linux kernel and has documentation and everything to it.

    Kernel Map

     
    • Hellen CLARK 20:06 on 23/03/2009 Permalink | Reply

      Nice website, I found you while looking for some blog related search and want to give you a compliment while I was here.

  • webscriptz 21:23 on 14/03/2009 Permalink | Reply
    Tags: .htaccess, , , , , , , views   

    CodeIgniter the views and .htaccess 

    I must admit that I not a huge fan of Frameworks and Patterns because:

    A) They make things complicated

    B) Subject you to some nasty code stuff and rules

    C) Because templating and Frameworks can be water and fire.

    Codeigniter on the opposite has some advantage on it side for the templating stuff. This is really a short explanation for a common problem in other framework.

    What to do if you want a nice folder structure or have different template styles, remember this is just a basic thing which happen to work in CI 1.7.


    function index(){
    $this->load->view('Themename/news/index);
    }

    Just add some slashes an it works so normally it should work if you would make an adaptation for themes too with a variable in it.

    The next thing was kind of hard to find on the web so let me share it. It’s for when you develop with CI and your not working in the root directory of your server.


    DirectoryIndex index.php
    RewriteEngine on
    RewriteCond $1 !^(index\.php|images|css|js|robots\.txt|favicon\.ico)
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ ./index.php/$1 [L,QSA]

     
  • webscriptz 22:49 on 09/03/2009 Permalink | Reply
    Tags: , exp, mod_rewrite, , ,   

    MVC again 

    I’ve grew bored of having to deal with some irritating PHP issues so I’ve turned my back to those and began testing codeIgniter. It seems strait forward but templating already has me intrigued with problems and mod_rewrite needs a look too I think :p .

     
    • webscriptz 15:25 on 11/03/2009 Permalink | Reply

      I must admit once you’ve read some tutorials it seems strait forward but well it seems i’ll have to toy with it to really know.

c
compose new post
j
next post/next comment
k
previous post/previous comment
r
reply
e
edit
o
show/hide comments
t
go to top
l
go to login
h
show/hide help
shift + esc
cancel