dracoblue.net

DracoBlue.net relaunch

Hello,

it's been a while since I posted on my dev blog, real blog or at this site.

I had little spare time the past months, and so I focused on rewriting this page. Since that new page has a different database format I had to convert lots of data - which isn't done, yet. So if you inquery any problems glitches with the site - please comment or send via email!

Regards, Jan

In by DracoBlue @ 03 Feb 2009 | 74 Words

Creating (internal) links in Agavi Views-Templates

As you set up your routing.xml with some route like that:

<route name="[strong]unnamed_ticket_view[/strong]"
    pattern="[strong]^/ticket/(id:\d+)/$[/strong]" module="Tickets" action="View" />

You can easily create links directly to that with the following code (in your

templates):

echo '<a href="'.$ro->gen("[strong]unnamed_ticket_view[/strong]", array("[strong]id[/strong]" => [strong]12[/strong]))
    .'">'.htmlspecialchars("MyLink").'</a>';

This will create a link MyLink with the target

/ticket/12/, nice, isn't it? :)

In agavi, open source, php by DracoBlue @ 09 Oct 2008 | 65 Words

Agavi database overrides for Propel + MySQL (other databases)

Once you generated your myproject-conf.php and myproject-classmap.php, you'll notice and copy and paste them into your app/config-folder you'll maybe want to set user and password for a specific AgaviPropelDatabase.

<?xml version="1.0" encoding="UTF-8"?>
    &lt;configurations xmlns="http://agavi.org/agavi/1.0/config">
    &lt;configuration environment="development">
        &lt;databases default="[strong]mydb[/strong]">
        &lt;database name="[strong]mydb[/strong]" class="AgaviPropelDatabase">
        &lt;parameter name="config">
            %core.app_dir%/config/[strong]myproject[/strong]-conf.php
        &lt;/parameter>
        &lt;parameter name="overrides">
        &lt;parameter name="connection">
        &lt;dsn>mysql:dbname=[strong]mydb[/strong];host=[strong]localhost[/strong]&lt;/dsn>
        &lt;parameter name="user">root&lt;/parameter>
        &lt;parameter name="password">&lt;/parameter>
        &lt;/parameter>
        &lt;/parameter>
        &lt;/database>
        &lt;/databases>
    &lt;/configuration>
&lt;/configurations>

Here you also can change the dns-entry to match different sql servers!

Your runtime-conf.xml for propel looks like that:

<?xml version="1.0" encoding="UTF-8"?>
&lt;config>
    &lt;propel>
        &lt;datasources default="[strong]mydb[/strong]">
            &lt;datasource id="[strong]mydb[/strong]">


<!-- 
                    this ID must match <database name="">
                    in schema.xml
                -->
                &lt;adapter>mysql&lt;/adapter> 


<!--
                        sqlite, mysql, myssql, oracle, or pgsql
                    -->

                &lt;connection>
                    &lt;dsn>mysql:dbname=[strong]mydb[/strong];host=localhost&lt;/dsn>
                &lt;/connection>
            &lt;/datasource>
        &lt;/datasources>
    &lt;/propel>
&lt;/config>

In agavi, open source, php, propel by DracoBlue @ 09 Oct 2008 | 124 Words

DJson 1.4.1 released

Today I want to announce a new release of DJson. The 1.4.1 features one little bug fix for loading files, with numbers (especially the 0) as element.

Also this update of course includes the changes from the 1.4 release: way faster caching. With 1.4 I managed to use the cache memory based and without journal (which is actually not needed here), which made the api-tests like 100 times faster. DJson is now really lightning fast!

Head over to the

official DJson page or directly to the djson 1.4.1 download.

In djson, open source, pawn by DracoBlue @ 18 Sep 2008 | 92 Words

Dini 1.6 released

Today we have an update for the dini library. It has been a year since the last update, because dini is doing quite well for already 14500 downloaders (awesome!), but in a technical discussion at the sampforums we noticed, that it's possible to tweak the speed of dini - so why not make a new release?

DINI 1.6

Changes:

  • dini_Get uses less memory now
  • All dini_set/get functions use a faster check for the evaluation of the key now
  • dini_BoolSet uses less memory now
  • dependency to dutils has been removed

As you can see dini does not has any new functions, but is faster now. Hope you like it!

Thank you to Magor for the positive and negative remarks on dini and the resulting changes. If you need dini 1.5.1, I mirrored the

old version, too.

In dini, open source, pawn by DracoBlue @ 16 Sep 2008 | 149 Words

Page 30 - Page 31 - Page 32

Give something back

Were my blog posts useful to you? If you want to give back, support one of these charities, too!

Report hate in social media Campact e.V. With our technology and your help, we protect the oceans from plastic waste. Gesellschaft fur Freiheitsrechte e. V. The civil eye in the mediterranean

Recent Dev-Articles

Read recently

Recent Files

About