Fatal error: Call to a member function findByFromApplication() on a non-object

Posted January 8th, 2009 in PHP, Programming by Louie Miranda

Geez! I posted this on cakephp mailing list, hoping to find a solution to my problem. Basically, I do wanted to display a small category of applications using an ID. But, weird error keeps popping out of my result.

http://groups.google.com/group/cake-php/browse_thread/thread/f0cc9ab09241f2a4

Attaching a file on CakePHP!

Posted December 5th, 2008 in PHP, Programming by Louie Miranda

This is how I attached a file on CakePHP!

$this->Email->filePaths = array(‘/www/axishift/app/webroot/files/’);
$this->Email->attachments = array(‘attachment.txt’);

I am now trying Sphinx

Posted December 5th, 2008 in Database, MySQL, PHP, Programming, Projects by Louie Miranda

Sphinx is a free open-source SQL full-text search engine. I am currently trying it on some of my projects. Hopefully, this will speed-up my MySQL full-text search.

http://www.sphinxsearch.com/features.html

Limit feeds on simplepie using cakephp 1.2.x

Posted November 12th, 2008 in PHP, Programming, Projects by Louie Miranda

I am currently working on Simplepie and CakePHP 1.2.x. I have a working code that successfully display xml feeds from different remote sources, a sample can be viewed on my homepage. And, I can’t find how to limit it.

Continue Reading »

Book: Beginning CakePHP

Posted November 7th, 2008 in PHP, Programming by Louie Miranda

Beginning CakePHP

Just got a new book to read. This will surely help me speed up my learning curve with CakePHP.
CakePHP is a leading PHP–based web app development framework.

http://apress.com/book/view/1430209771

MySQL, Insert Select

Posted May 8th, 2005 in MySQL, PHP, Programming by Louie Miranda

I been working with a PHP function on how I can duplicate an entry on sql. My first approach was to use the while() function, but what it does was loop the entire process.

I posted at phpugph.com and ask them what they think, and they suggested the INSERT – SELECT of MySQL.

1
2
3
mysql> INSERT INTO jt_entry (uid,entry_requested_by,entry_status,entry_category,entry_title,entry_description)
select uid, entry_requested_by, entry_status, entry_category, entry_title, entry_description from jt_entry
where entry_id=3limit 1;

Query OK, 1 row affected (0.00 sec)
Records: 1 Duplicates: 0 Warnings: 0

Thanks!

Rounding fractions on PHP

Posted April 7th, 2005 in PHP by Louie Miranda

Part of my study on PHP; I found out that I can easily round fractions up or down, using function ceil() and floor(). Good thing i was able to read the manual first, hehe.

Read here:
http://ph.php.net/manual/en/function.ceil.php
http://ph.php.net/manual/en/function.floor.php

1
2
3
4
5
6
<?php
echo ceil(4.3); // 5
echo ceil(9.999); // 10
echo floor(4.3); // 4
echo floor(9.999); // 9
?>