Projects

Lately we’ve been involved in several very exciting projects that have taken a lot of our time.

  • ZeTwig: A Zend Framework 2 module that allows the use of Twig within your ZF2 projects. It also adds a few extensions for rendering actions or triggering events. Everyone is encouraged to fork it and contribute to it if they want to. Update: The functionality of this module was integrated in ZfcTwig and further development will be done there. ZeTwig is now deprecated and will not work with the new versions of ZF2.
  • ZeTheme: A ZF2 module that allows developers switch between various themes for their websites.
  • ZeSecurity: A ZF2 module that adds an out of the box security layer for your applications based on PHPIDS.
  • ZeDb: A ZF2 module that allows developers to focus on the entities they work with instead of how to retrieve or store data in the database. It contains a large variety of functions that simplify the communication between your application and the database.
  • DotsCMS: A ZF2 based CMS solution that allows developers to create websites with extreme speed, while also having all the customization power they need. Current status: v0.1.
  • Ze_Payments: A very elegant solution to working with PayPal Website Payments Pro as well as Website Payment Standard and Express Checkout. Written in PHP and based on Zend Framework and cURL this small class allows the user to create and manage PayPal recurring profiles with ease.
  • Ze_Google_Checkout: Allows you to integrate Google Checkout on any Zend Framework website easily by creating a set of methods that allow you to export your shopping cart items and any other settings into Google Checkout and receive payment.
  • ProjectQuery: This a very useful tool to keep track of your projects, tasks, files, contacts and much much more. The project includes and advanced user permissions system, a share center where you can video chat with your team and hold presentations online and a time tracking system.

Links to all these projects will be posted as soon as they pass the development phase.

Share

17 comments

  1. Fred says:

    HI Guys/Girls,
    do you still support ZeTheme and I f so is there a tutorial anywhere?
    Great work

    Thanks

  2. Cosmin says:

    Hi Fred,

    Yes, we still support it.
    A small documentation for it is located on github at: https://github.com/ZendExperts/ZeTheme .

    Please let me know if you need any other details and I would be happy to write a more detailed article on how to use it.

  3. Pascal says:

    Hi there,

    If got a little problem with ZeTheme.
    I have setup 2 modules, “Frontend” and “Backend”.
    In application.config.php i have the following:

    ‘modules’ => array(
    ‘Frontend’,
    ‘Backend’,
    ‘ZeTheme’,
    ‘DluTwBootstrap’,
    ),

    now in the Frontend module.config.php i have:
    ‘ze_theme’ => array(
    ‘default_theme’ => ‘bukit-grey_orange’,
    ‘theme_paths’ => array(
    __DIR__ . ‘/../../../public/themes/’
    ),
    ‘adapters’ => array(
    ‘ZeTheme\Adapter\Configuration’,
    ),
    ),

    and in the backend module.config.php i have:
    // Setup ZeTheme
    ‘ze_theme’ => array(
    ‘default_theme’ => ‘sopa_admin’,
    ‘theme_paths’ => array(
    __DIR__ . ‘/../../../public/themes/’
    ),
    ‘adapters’ => array(
    ‘ZeTheme\Adapter\Configuration’,
    ),
    ),

    But the problem is that it is always loading the Backend theme while my routing is of the frontend module.

    Can you help further with it because i cant find any more info about the usage of ZeTheme then readme.md

    anyway props for your projects!

    Kindly regards,

    Pascal

  4. Cosmin says:

    Hi Pascal,

    I think the problem here is related to the way ZeTheme is meant to work.
    You shouldn’t set different default themes for each module, but rather only one theme for your project. This is because when the configuration array is combined from all the configs only the last value set will be used.

    ZeTheme is meant to allow you to switch between various themes based on the configuration adapter provided.
    I’ve updated the module and added a new adapter class that you can use to display a specific theme for particular routes.
    Please update and let me know if that works for you (be sure to read the documentation to see how to use it).

    Regards,
    Cosmin

  5. Pascal says:

    Hi Cosmin,

    Thanks for the fast reply.
    Im going to look at it and will post an update how it works :) .

    Kindly regards,

    Pascal

  6. Hi all

    I set up the zeTheme but i have a problem how can i get current theme or how can i set the theme on my application/controller. Thanks

  7. Cosmin says:

    Hi, You can get the current theme by writing something like this:

    1
    2
    $zeThemeManager = $this->getServiceLocator()->get('ZeThemeManager');
    $theme = $zeThemeManager->getTheme();

    You can set a new theme by using the setTheme method, but please note that this currently only works for the Session adapter and it will take effect only on the next request (since the theme is set onBootstrap).
    For the Configuration or Route adapters you can only change them by editing the configuration files for your application. If you want you could write a database adapter that can persist this in the database.

    Hope this helps.

    Regards,
    Cosmin

  8. Hi Cosmin

    I have a problem about zend , im new on it and thinking about what can i seperate admin and public folders.

    ı made it like that

    root
    -public
    -admin
    -site
    -modules
    -admin
    -site

    its right ? Or can u give me an ide about how can i makeit ?

  9. Pascal says:

    Hi Cosmin,

    You have made a great solution for me :) .
    The approach is a little bit ugly it would be nice if it was possible to setup the default_theme per module but this is also working as a charm.

    Now i found a little bug…
    The default module.config.php of ZeTheme sets “default_theme” to NULL, this value wont change if i set the “default_theme” in the module.config.php now i comment out the line “‘default_theme’ => NULL” and now the default theme will be set.

    Kindly regards,

    Pascal

  10. Cosmin says:

    Hi Pascal,

    Glad to see that the solution is working for you. Setting up a theme for each module would require a more extensive change to the way the module works. The Route adapter presented a simple and powerful way to achieve the same thing, but perhaps with a bit more configuration needed from the developer.

    About your bug, I think the issue is generated by either the way in which module you set the `default_theme` or in which file.
    In ZF2 when the configuration files are merged they use the order specified in the application.config.php file. In your case:
    ‘Frontend’, => ‘Backend’, => ‘ZeTheme’, => ‘DluTwBootstrap’.

    If you added the default_theme in either Frontend or Backend that value will be overwritten by ZeTheme.
    Always set your dependencies first and then your local modules: DluTwBootstrap, ZeTheme, Frontend, Backend.
    That way Frontend and Backend will over overwrite anything in the configuration of ZeTheme or DluTwBootstrap.
    Another way to achieve this is by simply adding your changes in the global.php file from config/autoload (or create your own, but make sure to end it with .global/.local.php). These files will overwrite everything from the module configs.

    Regards,
    Cosmin

  11. Pascal says:

    Hi Cosmin,

    I found that out to that it works that way thanx btw!!

    Thanx for the tip now i setup a default zetheme.global.php in my autoload in that file i setup the default theme paths and adapters and in the module i only use default_theme and routes.

    Thanx for the help :) !

  12. Hi Cosmin , in my themes folder i created _resources folder

    Themes
    -default
    -view
    -_resources
    -style.css
    -layout
    layout.phtml

    How can i find theme path in my layout.phtml to import my _resources/style.css

    Thanks

  13. Cosmin says:

    Hi Muhammet,

    Unfortunately the ZeTheme module doesn’t contain any assets management functionality.
    That being said, there are a few libraries that you should be able to use at http://modules.zendframework.com/ . Please try one of these and let us know how the integration worked out.

    Regards,
    Cosmin

  14. Hi cosmin
    i solved my problem with that.

    In zeTheme modules i create a vieehelpermanager and src/views/ThemeHelper.php so i return currently theme to the layout.phtml and i only call $this->theme()->getTheme(); then it return me “default” or another theme , and i find my _resources folder (themes/’.$this->theme()->getTheme().’/_resources/css/ etc.

    Thanks for all

  15. Fred says:

    Hi Cosmin,
    Unsure if I am doing anything wrong but can’t get the module to work, I have added ZeTheme (https://github.com/ZendExperts/ZeTheme) as per instructions (composer.phar)

    I have created a folder called themes (in root) and copied the default folder form examples to it.
    I created zetheme.module.config.global.php and have the follwing code in it

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    <?php
    return array(
            'ze_theme' => array(
            'default_theme' => 'default',
            'theme_paths' => array(
                __DIR__ . '/../themes/'
            ),
            'adapters' => array(
                'ZeTheme\Adapter\Configuration',
            ),
        ),
    );

    Final step was to enable the module by adding it to the application.config.php.

    And this did not work, also tried to copy the module.config.php to autoload folder and set the default with no luck, as well as set the theme to be default under the module.config.php in the vendor directory with no luck.

    Any suggestions are welcome.

    Thanks

  16. Fred says:

    Hi Cosmin,
    Please disregard my comment, what i did wrong wat to just copy module.congig.php to the autoload directory, I have now updated that to a ZeTheme.config.global.php with the code

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    <?php
    return array(
        'ze_theme' => array(
            'default_theme' => 'default',
            'theme_paths' => array(
                __DIR__ . '/../../themes/'
            ),
            'adapters' => array(
                'ZeTheme\Adapter\Configuration',
            ),
        ),
    );

    This then links to a root folder themes where i have built the themes.

    Thank you for a great module!

  17. Fred says:

    Tried to use the module but the 404 pages do not work. error message is

    Fatal error: Call to a member function getMatchedRouteName() on a non-object in ……..\ZendSkeletonApplication\vendor\ZeTheme\src\ZeTheme\Adapter\Route.php on line 26

    Do anyone else have this as well?

Leave a Reply