Search Results

Search found 40 results on 2 pages for 'jiewmeng'.

Page 1/2 | 1 2  | Next Page >

  • Zend_Test: No default module defined for this application

    - by jiewmeng
    UPDATE 23 Dec I had the problem where Zend Framework complains about "No default module defined for this application". I didn't use Modules and the main app works fine. I finally solved the problem with the help from weierophinney.net Your bootstrap needs to minimally set the controller directory -- do a call to $this->frontController->addControllerDirectory(...) in your appBootstrap() method. I didn't in my example, as my Initialization plugin does that sort of thing for me. The problem is solved by adding the below to setUp() $this->getFrontController()->setControllerDirectory(APPLICATION_PATH . '/controllers'); But now, I have afew other questions: 1. Why does that value not get initialized by application.ini? In application.ini, I have [production] resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers" [testing : production] // didn't change anything regarding modules nor controllers 2. I tried setting the controllerDirectory in bootstrap.php of my unit test, but it does not work $front = Zend_Controller_Front::getInstance(); $front->setControllerDirectory(APPLICATION_PATH . '/controllers'); The only way that works is using setUp(). Why is that? END UPDATE 23 Dec I am getting the above error when unit testing my controller plugins. I am not using any modules. in my bootstrap.php for unit testing, I even tried adding $front = Zend_Controller_Front::getInstance(); $front->setDefaultModule('default'); But it still does not work. Anyways my bootstrap.php looks like this UPDATE: the error looks something like There were 2 errors: 1) Application_Controller_Plugin_AclTest::testAccessToUnauthorizedPageRedirectsToLogin Zend_Controller_Exception: No default module defined for this application D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Dispatcher\Standard.php:391 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Dispatcher\Standard.php:204 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Dispatcher\Standard.php:244 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Front.php:954 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Test\PHPUnit\ControllerTestCase.php:205 D:\Projects\Tickle\tests\application\controllers\plugins\aclTest.php:6 2) Application_Controller_Plugin_AclTest::testAccessToAllowedPageWorks Zend_Controller_Exception: No default module defined for this application D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Dispatcher\Standard.php:391 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Dispatcher\Standard.php:204 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Dispatcher\Standard.php:244 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Controller\Front.php:954 D:\ResourceLibrary\Frameworks\PHPFrameworks\Zend\Test\PHPUnit\ControllerTestCase.php:205 D:\Projects\Tickle\tests\application\controllers\plugins\aclTest.php:16 UPDATE I tried adding public function setUp() { $front = Zend_Controller_Front::getInstance(); $front->setDefaultModule('default'); } then 1 part works. public function testAccessToUnauthorizedPageRedirectsToLogin() { // this fails with exception "Zend_Controller_Exception: No default module defined for this application" $this->dispatch('/projects'); $this->assertController('auth'); $this->assertAction('login'); } public function testAccessToAllowedPageWorks() { // this passes $auth = Zend_Auth::getInstance(); $authAdapter = new Application_Auth_Adapter('jiewmeng', 'password'); $auth->authenticate($authAdapter); $this->dispatch('/projects'); $this->assertController('projects'); $this->assertAction('index'); }

    Read the article

  • Mathematics for Computer Science

    - by jiewmeng
    I am going into university next year. I think maths would be one of the more important aspects of computer science? I recently saw the MIT Intro to Algorithms video on YouTube and the maths required is quite hardcore. I wonder what parts of maths do i need, probability, calculus, trigo etc. Will the book Concrete Mathematics - it claims to be foundation for computer science - on Amazon cover most of whats required?

    Read the article

  • Problem with WebUpd8 PPA: Hash Sum mismatch

    - by jiewmeng
    I keep getting W: Failed to fetch bzip2:/var/lib/apt/lists/partial/ppa.launchpad.net_webupd8team_gnome3_ubuntu_dists_oneiric_main_binary-i386_Packages Hash Sum mismatch W: Failed to fetch http://ppa.launchpad.net/webupd8team/gnome3/ubuntu/dists/oneiric/main/i18n/Index No Hash entry in Release file /var/lib/apt/lists/partial/ppa.launchpad.net_webupd8team_gnome3_ubuntu_dists_oneiric_main_i18n_Index E: Some index files failed to download. They have been ignored, or old ones used instead. How might I fix this? I tried deleting the files in /var/lib/apt/lists/partial already ... still doesnt work ...

    Read the article

  • Thoughts of Cloud Development/Google App Engine

    - by jiewmeng
    I use mainly PHP for web development, but recently, I started thinking about using Google App Engine. It doesn't use PHP which I am already familiar with, so there will be a steeper learning curve. Probably using Python/Django. But I think it maybe worthwhile. Some advantages I see: Focus on App/Development. No need to setup/maintain server ... no more server configs Scales automatically Pay for what you use. Free for low usage Reliable, it's Google after all Some concerns though: Does database with no joins pose a problem for those who used App Engine before? Do I have to upload to Google just to test? Will it be slow compared to testing locally? What are your thoughts and opinions? Why would you use or not use App Engine?

    Read the article

  • Software development life cycle in the industry

    - by jiewmeng
    I am taking a module called "Requirements Analysis & Design" in a local university. Common module, I'd say (on software development life cycle (SDLC) and UML). But there is a lot of things I wonder if they are actually (strictly) practiced in the industry. For example, will a domain class diagram, an not anything extra (from design class), be strictly the output from Analysis or Discovery phase? I'm sure many times you will think a bit about the technical implementation too? Else you might end up with a design class diagram later that is very different from the original domain class diagram? I also find it hard to remember what diagrams are from Initiation, Discovery, Design etc etc. Plus these phases vary from SDLC to SDLC, I believe? So I usually will create a diagram when I think will be useful. Is it the wrong way?

    Read the article

  • Licenses that i can use for my works, web apps, desktop apps, wordpress themes etc

    - by jiewmeng
    I originally thought of creative commons when while reading a book about wordpress (professional wordpress), I learned that I should also specify that the product is provided ... WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE and they recommend GNU GPL. How do I write a license or select 1? btw, what does 'MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE' mean actually? Isn't without warranty enough?

    Read the article

  • Need help identifing what resources (eg. In MIT OpenCourseWare) can help me prepare for a test [closed]

    - by jiewmeng
    I am entering uni soon. I can sit for a placement test to see if I elegible for exemptions. The details are http://www.comp.nus.edu.sg/undergraduates/TestScope11_12.html Or CS2100 Computer Organisation (please click title) The objective of this module is to familiarise students with the fundamentals of computing devices. Through this module students will understand the basics of data representation, and how the various parts of a computer work, separately and with each other. This allows students to understand the issues in computing devices, and how these issues affect the implementation of solutions. Topics covered include data representation systems, combinational and sequential circuit design techniques, assembly language, processor execution cycles, pipelining, memory hierarchy and input/output systems. Recommended Textbooks Digital Design: Principles and Practices [DDPP] by John F. Wakerly, Prentice-Hall. ISBN 0-13-324500-4. Computer Organizations and Design (The hardware/software interface) by David A. Patterson and John L. Hennessy. CS2105 Introduction to Computer Networks (please click title) This course aims to provide a broad introduction to computer networks and some appreciations of network application programming. It covers a range of topics including basic data communication and computer network concepts, protocols, networked computing concepts and principles, network applications development and network security. The emphasis of teaching is on the working principles and application of computer networks. As an integral part of the course, tutorials and practical assignments enforcing learning will also be given. These assignments provide an early exposure in network application programming and they should be able to complete by using personal computers and school's network facilities. Topics included: An overview of computer networks and the Internet Basic data communications Application layer Transport layer Network layer and routing Link layer and local area networks Recommended Textbook James F. Kurose & Keith W. Ross, Computer networking: A top-down approach featuring internet, Addison Wesley, 2001 I am wondering what resources eg. MIT OpenCourseWare or other universities resources are available to help he perpare for these particular modubles. I am thinking does the Networking one look like CCNA? The computer oragization. Its like electronics, assembly etc? I learnt some electronics in Poly but looking at the sample papers, uni looks very different... I have about 1 month to prepare if I want any chance of exempting from these modules :) any help?

    Read the article

  • SEO: Is there a limit to how long titles/descriptions should be?

    - by jiewmeng
    I am trying to fill up title and meta description for my Tumblr blog. The way I will do that is via the themes. For the title, it isn't too much of an issue, I can just get the title for the post although some post types do not have titles. The main question is about the description. I am thinking of using the start of the body content. For now, there is no way to limit the length of body content. I wonder if its OK to have the whole body in the description? I have contacted Tumblr support to suggest that they have a way of creating limiting text length in their template tags.

    Read the article

  • Keeping files private on the internet (.htaccess password or software/php/wordpress password)

    - by jiewmeng
    I was asked a while ago to setup a server such that only authenticated users can access files. It was like a test server for clients to view WIP sites. More recently, I want to do something similar for some of my files. Tho they are not very confidential, I wish that I am the only one viewing it. I thought of doing the same, Create a robots.txt User-agent: * Disallow: / Setup some password protection, .htpasswd seems like a very ugly way to do it. It will prompt me even when I log into FTP. I wonder if software method like password protected posts in Wordpress will do the trick of locking out the public and hiding content from Search Engines? Or some self made PHP script will do the trick?

    Read the article

  • 11.10 does not restore open apps in hibernate, works like shutdown

    - by jiewmeng
    I noticed that my 11.10 does not hibernate. When I hibernate, and starts PC, it doesn't restore all my open apps etc. Its like a shutdown ... why might that be? UPDATE Output from gsettings http://pastie.org/2926504 Using a vanilla Ubuntu Desktop 11.10 installed yesterday (no more from alternate CD, but problem still persists) I dont see any options in BIOS for S1, S3 or ACPI, are they hidden somewhere? I am using ASUS H67 Evo, I entered the Advanced mode of the BIOS, I still dont see those stuff ps-*.log files: http://pastie.org/2922774 GRUB entry: http://pastie.org/2922781

    Read the article

  • Windows Home Server vs Windows 7

    - by jiewmeng
    i am a home user of windows 7 and really like the new features like jumplists taskbar thumbnails etc i am also exploring benefits of homegroup, federated search and since i am a developer intending to start ASP.NET MVC 2 development from PHP, i am thinking a Windows Home Server maybe useful for me. but what i need, IIS, homegroups etc are offered in Windows 7 too. i am wondering why will i want to have a home server instead? i believe it will offer some benefits i should know of?

    Read the article

  • Need help. HDD Failed

    - by jiewmeng
    i have a seagate 3.5" 500GB SATA2 HDD that i put in a USB case (vantec) that failed recently. symptoms: at first, it started except that attempts made to browse certain folders resulted in "Data Error (Cyclic Redundancy Check)". then when i tried restarting the hdd, then i got a RAW partition, and windows 7 said i need to format it. i also tried using a desktop to connect to the HDD directly using SATA, windows 7 stuck at "starting windows" for abt half hour b4 i gave up on it. in the BIOS, it seems to detect the HDD model correctly, something like STA3500xxx something like that i also tried using TestDisk as suggested by jaclaz on MSFN and it did not find any partitions what could i do now?

    Read the article

  • Suggestions for Backup solution

    - by jiewmeng
    i am considering between windows home server simple nas extra HDD's in desktop btw, i will be the main user i am looking to fulfil the following needs: reliability (i am think RAID 1 or 5) not so prone to virus/malware infections (will using a separate NAS or home server help? say windows home server is still a windows pc except separated by network?) power efficiency (eg. spin down when not in use) download (eg. i may want to dl big files/torrents overnight and i may not want to use a full powered PC for it? does a full pc vs NAS provide significant power usage to justify cost of new system esp. since i am only user?) performance (i guess i like to write/access my files fast, on 2nd thought, maybe for backup i can forgo this? maybe for a WD Green HDD? but how much slower will it be? plus since i am the only user, i think the whole HDD will be mine?)

    Read the article

  • Markdown for .NET/C#?

    - by jiewmeng
    is there a way i can have markdown in .NET/C# application? i wonder shld i store the data in HTML or markdown text? if i store the data in HTML, when the user edits, they will see HTML, but if i store in Markdown, everytime i display, i got to convert to HTML(slow?) or store the HTML in another column, will it waste too much space? i understand markdown.net maybe used for this site. isit true? but heard its not updated since 2004/5?

    Read the article

  • Programming Blogs, Tumblrs, eBooks or Resources

    - by jiewmeng
    i thought it will be good to know what websites, blogs or tumblogs providing good programming resources, latest news/trends etc. i was actually on tumblr when i thought about finding other users to follow, but couldn't. so i thought i asked here, but dont want to be limited to tumblr please enter 1 link per answer to facilitate voting

    Read the article

  • Install APC on Windows

    - by jiewmeng
    how can i install APC on Windows? i am using PHP 5.3, Windows 7 x64 i used pecl install apc i got C:\PHPpecl install apc downloading APC-3.0.19.tgz ... Starting to download APC-3.0.19.tgz (115,735 bytes) ............done: 115,735 bytes 47 source files, building WARNING: php_bin c:\php\php.exe appears to have a suffix \php.exe, but config variable php_suffix does not match running: msdev APC.dsp /MAKE "APC - Release" ERROR: Did not understand the completion status returned from msdev.exe.

    Read the article

  • What is the structure of a (Data Access) Service Class

    - by jiewmeng
    I learnt that I should be using service classes to persist entities into the database instead of putting such logic in models/controllers. I currently made my service class something like class Application_DAO_User { protected $user; public function __construct(User $user) { $this->user = $user } public function edit($name, ...) { $this->user->name = $name; ... $this->em->flush(); } } I wonder if this should be the structure of a service class? where a service object represents a entity/model? Or maybe I should pass a User object everytime I want to do a edit like public static function edit($user, $name) { $user->name = $name; $this->em->flush(); } I am using Doctrine 2 & Zend Framework, but it shouldn't matter

    Read the article

  • How to debug MySQL/Doctrine2 Queries?

    - by jiewmeng
    I am using MySQL with Zend Framework & Doctrine 2. I think even if you don't use Doctrine 2, you will be familiar with errors like SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ASC' at line 1 The problem is that I don't see the full query. Without an ORM framework, I could probably echo the sql easily, but with a framework, how can I find out what SQL its trying to execute? I narrowed the error down to $progress = $task->getProgress(); $progress is declared // Application\Models\Task /** * @OneToMany(targetEntity="TaskProgress", mappedBy="task") * @OrderBy({"seq" = "ASC"}) */ protected $progress; In MySQL, the task class looks like CREATE TABLE `tasks` ( `id` int(11) NOT NULL AUTO_INCREMENT, `owner_id` int(11) DEFAULT NULL, `assigned_id` int(11) DEFAULT NULL, `list_id` int(11) DEFAULT NULL, `name` varchar(60) NOT NULL, `seq` int(11) DEFAULT NULL, PRIMARY KEY (`id`), KEY `tasks_owner_id_idx` (`owner_id`), KEY `tasks_assigned_id_idx` (`assigned_id`), KEY `tasks_list_id_idx` (`list_id`), CONSTRAINT `tasks_ibfk_1` FOREIGN KEY (`owner_id`) REFERENCES `users` (`id`), CONSTRAINT `tasks_ibfk_2` FOREIGN KEY (`assigned_id`) REFERENCES `users` (`id`), CONSTRAINT `tasks_ibfk_3` FOREIGN KEY (`list_id`) REFERENCES `lists` (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1$$

    Read the article

  • Applications on the Web/Cloud the way to go? over Desktop apps?

    - by jiewmeng
    i am currently a mainly web developer, but is quite attracted to the performance and great integration with the OS (eg. Windows 7, Jump Lists, Taskbar Thumbnails, etc) something like WPF/C# can provide to the user, improving workflow and productivity. privacy and performance seems like a major downside of web/cloud apps compared to desktop apps. applications on the cloud/web work on the go, increased popularity of smartphones/netbooks majority of users may not benefit as much from increased performance of desktop apps, eg. internet surfing, word processing, probably benefit more from decreased startup times, lower costs and data on the cloud desktop applications increased performance benefits power users like 3D rendering, HD video/photo editing, gamers (i wonder if such processing maybe offset to cloud processing) integration with OS increases productivity (maybe such features can be adapted to a web version? maybe with a local desktop app to work with Web App API) more control over privacy (maybe fixed by encryption?) local data access (esp. large files) guaranteed and fast (YouTube HD fast enough most of the time) work not affected by intermittent/slow/availability internet connections (i know this is changing tho) what do you think?

    Read the article

  • CSS Margin Issue

    - by jiewmeng
    i have an issue with my css where if i use margin: 0 instead of margin-top: 0, for header p, the header { margin: 0 0 20px; } will be as good as not there. isit supposed to be like that? if i see what happens in firebug, its because the margin-bottom of header collapsed into the next sibling, the section. html <header> <h1>ToDo List</h1> <p>HTML5 Offline Capable Web Application</p> </header> css header { font: 24px/1em Notethis; color: #666; margin: 0 0 20px; } header h1 { font: 60px/1.4em Hetilica; margin: 0; } header p { margin-top: 0; }

    Read the article

  • Oddities when mixing Zend Framework 1.11 & Doctrine 2 Autoloaders

    - by jiewmeng
    I have setup autoloading in my ZF/Doctrine2 app as follows $zendAutoloader = Zend_Loader_Autoloader::getInstance(); $autoloader = array(new ClassLoader('Symfony'), 'loadClass'); $zendAutoloader->pushAutoloader($autoloader, 'Symfony'); $autoloader = array(new ClassLoader('Doctrine'), 'loadClass'); $zendAutoloader->pushAutoloader($autoloader, 'Doctrine'); $autoloader = array(new ClassLoader('Application', realpath(__DIR__ . '/..')), 'loadClass'); $zendAutoloader->pushAutoloader($autoloader, 'Application'); $autoloader = array(new ClassLoader('DoctrineExtensions'), 'loadClass'); $zendAutoloader->pushAutoloader($autoloader, 'DoctrineExtensions'); I find that the DoctrineExtensions autoloading is not working while other classes are ... to verify that the path etc are right, I tried $autoloader = new ClassLoader('DoctrineExtensions'); $autoloader->register(); And it works. So it seems it has something to do with Zend Framework?

    Read the article

  • HTML5 Web Storage Cleared when Browser Clear Cache?

    - by jiewmeng
    i wonder if HTML5 Web Storage will be cleared when browser clears its cache? if it did, many ppl like me may lose data if i accidentally clear cache? or like in this comment ... Since HTML5 local storage is kept separate from js cookies (like Silverlight, Gears, Flash), it opens up a world of 3rd party privacy issues for HTML5 as these objects will likely NOT get deleted with a clear cache or delete temporary data ... where web storage is not cleared, but leads to privacy issues?

    Read the article

  • HTML5 Database Transactions

    - by jiewmeng
    i am wondering abt the example W3C Offline Web Apps the example function renderNotes() { db.transaction(function(tx) { tx.executeSql('CREATE TABLE IF NOT EXISTS Notes(title TEXT, body TEXT)', []); tx.executeSql(‘SELECT * FROM Notes’, [], function(tx, rs) { for(var i = 0; i < rs.rows.length; i++) { renderNote(rs.rows[i]); } }); }); } has the create table before the 'main' executeSql(). will it be better if i do something like $(function() { // create table 1st db.transaction(function(tx) { tx.executeSql('CREATE TABLE IF NOT EXISTS Notes(title TEXT, body TEXT)', []); }); // when i execute say to select/modify data, i just do the actual action db.transaction(function(tx) { tx.executeSql(‘SELECT * FROM Notes’, [], function(tx, rs) { ... } }); db.transaction(function(tx) { tx.executeSql(‘INSERT ...’, [], function(tx, rs) { ... } }); }) i was thinking i don't need to keep repeating the CREATE IF NOT EXISTS right?

    Read the article

1 2  | Next Page >